Pendulum Swing Expressions

//PENDELUM SWING:
veloc = 10;  //how fast it swings
amplitude = 50;  //how high
decay = .999;
amplitude*Math.sin(veloc*time)/Math.exp(decay*time);
————————————————————————————

//PENDULUM SWING ON MARKER EVENT(put in rotation):
n = 0;
if (marker.numKeys > 0){
n = marker.nearestKey(time).index;
if (marker.key(n).time > time){
n--;
}
}
if (n == 0){
value;
} else {
veloc = 10;  //how fast it swings
amplitude = 100;  //how high
decay = 4;
t = time - marker.key(n).time;
s= amplitude*Math.sin(veloc*t)/Math.exp(decay*t);
value + s;
}
0 replies

Leave a Reply

Want to join the discussion?
Feel free to contribute!

Leave a Reply

Your email address will not be published.