2
$\begingroup$

First of all I want to let you know that I'm not a Physicist, I am a Video Game Developer. I can simulate physical and mathematical equations and can also use some built in physics.

For example I can move an object through parametric equation of projectile

$$x = vt\cos\theta$$ $$y = vt\sin{\theta} - \frac{1}{2}gt^2$$

I can get values by increasing time, $t = 0$,$ t = 1$, . . . So these values make a good projectile.

On the other hand if I use built in Physics of Game Engine then I have to only Apply some force with a 2d or 3d vector. For example I can apply force of $\vec f = 24,15,6$ with other things in hand and I can change it like mass, gravity.

So now my question is that how can I calculate $\vec f (second method)$ or $data$ to populate in first method that the body will land on a specific predefined point.

  • I'm repeating the objective is to launch a projectile such that it will land on a specific predefined point?
$\endgroup$
10
  • $\begingroup$ So is your question about using Newton's law ($\mathbf F=m\mathbf a=m\dot{\mathbf v}$) to arrive at the same parametric path as the projectile equations? $\endgroup$
    – Kyle Kanos
    Jan 9, 2016 at 13:53
  • $\begingroup$ Not only force, but with different factors also like mass, gravity. Note, there is no AIR resistance in Game Engine $\endgroup$ Jan 9, 2016 at 14:57
  • $\begingroup$ Well mass is independent of the parametric equations, so you should not expect a change (ideally) between a 2 kg mass and a 20 kg one. $\endgroup$
    – Kyle Kanos
    Jan 9, 2016 at 15:23
  • $\begingroup$ @KyleKanos But if the OP is going to give a force first and then calculate the acceleration, then surely acceleration and also initial velocity would depend on mass $\endgroup$
    – Courage
    Jan 9, 2016 at 15:30
  • $\begingroup$ @TheGhostOfPerdition: I said that the parametric equations are independent of mass, not Newton's law. $\endgroup$
    – Kyle Kanos
    Jan 9, 2016 at 15:34

1 Answer 1

0
$\begingroup$

One of the pieces that you need is called the range equation (assuming that you are firing from the ground): $$ R=\frac{v^2_0\sin(2\alpha)}{g}\tag{1} $$ So if you start with knowing $v_0,\,\alpha$, you can figure out how far it will go. But you are starting with $R$ and trying to see what pairs of $v_0,\,\alpha$ would match this, which would be quite difficult as many pairs could lead to the same $R$.

However, you say that you are applying a force for some duration, so you can use the impulse to determine the (final) velocity: $$ \int\mathbf F\,dt=\Delta\mathbf p=m\mathbf v_{fin}-m\mathbf v_{init} $$ Since the projectile is initially at rest, the launch velocity would be $$ \mathbf v_{launch}=\frac{1}{m}\int\mathbf F\,dt $$ which, if the force is constant throughout, can be simplified to $$ \mathbf v_{launch}=\frac{1}{m}\mathbf F\Delta t\tag{2} $$ where $\Delta t$ is the length of time the force is applied.

So now you know the initial velocity, $v_0=\lVert\mathbf v\rVert$, and how far you want the projectile to go, $R$, so then you can solve Equation (1) to get $\alpha$.

$\endgroup$

Not the answer you're looking for? Browse other questions tagged or ask your own question.