-
hello everybody,
how can i make a vibrating (up and down ) spring , with code only ????
the strength of vibration also responses dynamically to the weight that is hanged in it
HOW CAN I ???
THANKS A LOT
-
-
there is actually a formula for the oscillation of wave. it takes in to account the spring constant, the weight, and stuff like that. as soon as i get ahold of my notebook from last semester ill put it up here...
-
thanks a lot all of u ,
iam waiting minger
-
alright here is all the stuff that I have for oscillations.
f = frequency - number of oscillations in unit time
1 Hertz (Hz) = 1 oscillation/second
T = Period - time for 1 oscillation
T = 1/f
The displacement or more or less the point at which the oscillation is at is:
x(t) = x(m) * cos(wt + o)
where x(m) = amplitude
w = angular frequency = (k/m)^1/2
k = spring constant
t = time
o = phase constant = just something to offset the wave, can just be set to zero
Velocity: dx/dt or:
v(t) = -w*x(m)*sin(wt + o)
where all the variables are same as above
Acceleration: dv/dt or:
a(t) = -w^2 * x(m) * cos(wt + o) or:
a(t) = -w^2 * x(t)
where x(t) is the displacement as defined above
In simple harmonic motion, the acceleration is proportional to the displacement, but opposite signs, and the 2 quantities are related by the square of the angular frequency.
Force:
F = -(mw^2)x
where m = mass and w = angular frequency and x = distance from the equilibrium
T(period) can also be written as:
T = 2pi * (m/k)^1/2
there ya go, there is a crash course in simple harmonic motion. I was just gonna post the one equation, but i figured while i had dug the notebook out, i might as well put the other stuff on there too, maybe it will help someone else out.
p.s. hope this helps
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|