Graveyard/GFK
From Sodawiki
(Difference between revisions)
(→K) |
(→K) |
||
| Line 17: | Line 17: | ||
For mass 1: | For mass 1: | ||
| + | |||
xv<sub>2</sub> = xv<sub>1</sub> + n * (x<sub>1</sub> − x<sub>2</sub>) | xv<sub>2</sub> = xv<sub>1</sub> + n * (x<sub>1</sub> − x<sub>2</sub>) | ||
yv<sub>2</sub> = yv<sub>1</sub> + n * (y<sub>1</sub> − y<sub>2</sub>) | yv<sub>2</sub> = yv<sub>1</sub> + n * (y<sub>1</sub> − y<sub>2</sub>) | ||
| + | |||
For mass 2: | For mass 2: | ||
| + | |||
xv<sub>2</sub> = xv<sub>1</sub> − n * (x<sub>1</sub> − x<sub>2</sub>) | xv<sub>2</sub> = xv<sub>1</sub> − n * (x<sub>1</sub> − x<sub>2</sub>) | ||
yv<sub>2</sub> = yv<sub>1</sub> − n * (y<sub>1</sub> − y<sub>2</sub>) | yv<sub>2</sub> = yv<sub>1</sub> − n * (y<sub>1</sub> − y<sub>2</sub>) | ||
Revision as of 19:28, 4 June 2007
G
Gravity in the sodaplay applet. Every step, vertical velocity is incremented by the gravity, or decremented if reverse gravity is on.
It is between 0 and 4 in the xml file.
F
The friction coefficient. Each step, all mass speeds are multiplied by (1-f).
Its value is between 0 and 1.
K
Hooke's constant in the applet. It determines the "springiness" of springs. The formula for springs, as approximated by Gizmo is:
For mass 1:
xv2 = xv1 + n * (x1 − x2)
yv2 = yv1 + n * (y1 − y2)
For mass 2:
xv2 = xv1 − n * (x1 − x2)
yv2 = yv1 − n * (y1 − y2)
