Title: **Solving 3 equations**

Post by:**mogn** on **March 27, 2012, 11:07:50 am**

Post by:

Why do you want to solve 3 equations with 3 unknowns?

Because programming in tg2 is fun.

And because I have the need to use it in a curve (profile) tool.

The equations:

1*a + 2*b + 3*c = 14

2*a + 3*b + 1*c = 11

3*a + 2*b + 1*c = 10

has the solutions a=1 b=2 c=3.

I have tested my solver with the about equations.

Note the way to inspect numerical values, using the displacement input of a surface layer

and viewing the surface layer in a new window.

Because programming in tg2 is fun.

And because I have the need to use it in a curve (profile) tool.

The equations:

1*a + 2*b + 3*c = 14

2*a + 3*b + 1*c = 11

3*a + 2*b + 1*c = 10

has the solutions a=1 b=2 c=3.

I have tested my solver with the about equations.

Note the way to inspect numerical values, using the displacement input of a surface layer

and viewing the surface layer in a new window.

Title: **Re: Solving 3 equations**

Post by:**RichTwo** on **March 28, 2012, 12:34:43 pm**

Post by:

Probably the lack of response here so far is due to our not knowing exactly what this set-up does. ??? Though I somehow have the feeling it is sheer brilliance at work. Perhaps you could show a rendered image and / or show it connected to a node network so we have an idea?

Title: **Re: Solving 3 equations**

Post by:**N810** on **March 28, 2012, 02:41:45 pm**

Post by:

Soooooo...

Waht does it do/what is it used for, exactly ???

Waht does it do/what is it used for, exactly ???

Title: **Re: Solving 3 equations**

Post by:**mogn** on **March 30, 2012, 07:04:01 am**

Post by:

It was meant to force a 6 order Bezier curve through known points [0, 0] [1/6, 0] [1/3, A] [1/2, B] [2/3, C] [5/6, 1] [1, 1] by solving 3 equations

giving the unknowns a, b and c, which are then put as middle points in the Bezier spline equation.

giving the unknowns a, b and c, which are then put as middle points in the Bezier spline equation.

Title: **Re: Solving 3 equations**

Post by:**cyphyr** on **March 30, 2012, 07:49:52 am**

Post by:

This sure is great and at a level well beyond my understanding. You say your using this as a profile tool. Do you mean for carving valleys?

So would this be used as a blend shader ?

More info please for the less well informed please :)

Cheers

Richard

So would this be used as a blend shader ?

More info please for the less well informed please :)

Cheers

Richard

Title: **Re: Solving 3 equations**

Post by:**Hetzen** on **March 30, 2012, 03:37:22 pm**

Post by:

I didn't get this at first, until Mogn's second post. Here's a link I found illustrating what he's created. Scroll to "Constructing Bézier curves" in this link...

http://en.wikipedia.org/wiki/B%C3%A9zier_curve

Mogn, do you know of a program you can visualy design these curves to give you your values for this function set?

Yes I think you could use this for creating specific curves that can be driven through altitude, position, ramps to carve valleys Richard.

http://en.wikipedia.org/wiki/B%C3%A9zier_curve

Mogn, do you know of a program you can visualy design these curves to give you your values for this function set?

Yes I think you could use this for creating specific curves that can be driven through altitude, position, ramps to carve valleys Richard.