- #1
bXD01Q99
- 2
- 0
Hi, I wanted to make an equation with Newtonian physics, but failed. Here's the problem:
I've done this so far:
Symptoms: the object starts moving with high acceleration, velocity gain speed gets slower over time, and the velocity converges to (and reaches?) its maximum speed. Then, all the additional performace goes, through friction, into heat energy.
The engine gives [tex]P \times \Delta t[/tex] joules of energy every [tex]\Delta t[/tex] time, and friction takes away [tex]F_f \times \Delta s[/tex]. Energy at a given time can be written as:
[tex]E = P t - F_f s[/tex]
[tex]\frac{m v^2}{2} = P t - \mu m g s[/tex]
[tex]\frac{m v^2}{2} = P t - \mu m g v_{avg} t[/tex] ?
[tex]s[/tex] is dependant on [tex]t[/tex] and [tex]v[/tex], but [tex]v[/tex] depends on the [tex]E[/tex], which depends on [tex]s[/tex], so I don't know how to continue. I need to get [tex]s[/tex] and its derivative, [tex]v[/tex], for any given [tex]t[/tex] time.
So I've tried a temporaty iterational method:
Start with [tex]E = 0[/tex], [tex]v = 0[/tex], then, iterate with very small [tex]\Delta t[/tex] time intervals, and do this:
1. to [tex]E[/tex], add [tex]( P - \mu m g v ) \times \Delta t[/tex]
2. set [tex]v[/tex] to [tex]\sqrt{ 2 E / m }[/tex]
With this algorithm, I've drawn this velocity-time graph:
img182.imageshack.us/my.php?image=47155991qs7.png or [ATTACHMENT]
Iteration count: Blue=5, Green=25, Red=625.
It looks like some sort of logarithmic or root curve.
Well, that's it. If anyone can give me equation instead of an iterating algorithm, and/or also consider slope, drag, and 2D plane vector directions, I'll really appreciate it. Thanks in advance.
Code:
Consider an object with that
^ has [B]m[/B] mass, and a built in
drag & | magic motor that has [B]P[/B]
friction | magic force constant performance. The
<----------[OBJ]-------------> motor is magically propelling
==============|================= the object in a direction,
| gravity parallel with the ground,
v which has [B]u[/B] friction.
Gravity is [B]g[/b].
What is the velocity and the traveled distance after [B]t[/B] time?
I've done this so far:
Symptoms: the object starts moving with high acceleration, velocity gain speed gets slower over time, and the velocity converges to (and reaches?) its maximum speed. Then, all the additional performace goes, through friction, into heat energy.
The engine gives [tex]P \times \Delta t[/tex] joules of energy every [tex]\Delta t[/tex] time, and friction takes away [tex]F_f \times \Delta s[/tex]. Energy at a given time can be written as:
[tex]E = P t - F_f s[/tex]
[tex]\frac{m v^2}{2} = P t - \mu m g s[/tex]
[tex]\frac{m v^2}{2} = P t - \mu m g v_{avg} t[/tex] ?
[tex]s[/tex] is dependant on [tex]t[/tex] and [tex]v[/tex], but [tex]v[/tex] depends on the [tex]E[/tex], which depends on [tex]s[/tex], so I don't know how to continue. I need to get [tex]s[/tex] and its derivative, [tex]v[/tex], for any given [tex]t[/tex] time.
So I've tried a temporaty iterational method:
Start with [tex]E = 0[/tex], [tex]v = 0[/tex], then, iterate with very small [tex]\Delta t[/tex] time intervals, and do this:
1. to [tex]E[/tex], add [tex]( P - \mu m g v ) \times \Delta t[/tex]
2. set [tex]v[/tex] to [tex]\sqrt{ 2 E / m }[/tex]
With this algorithm, I've drawn this velocity-time graph:
img182.imageshack.us/my.php?image=47155991qs7.png or [ATTACHMENT]
Iteration count: Blue=5, Green=25, Red=625.
It looks like some sort of logarithmic or root curve.
Well, that's it. If anyone can give me equation instead of an iterating algorithm, and/or also consider slope, drag, and 2D plane vector directions, I'll really appreciate it. Thanks in advance.
Attachments
Last edited: