I am working on a program that shoots a projectile straight up into the air. I need to be able to calculate the initial velocity required to reach a height at a given amount of seconds after firing.
I know the initial velocity ignoring setting the travel time is:
$v_0 = \sqrt{2gh}$
where
$g$ - gravity - could be other than $9.81m/s^2$
$h$ - maximum height to reach
$t$ - time to reach height, already known
But how do I calculate the continious downward force needed, so that after $t$ amount of seconds the object reached $h$, therefore has velocity of 0, then falling down and reach the ground again after $t$ seconds ?
The smaller I set $t$, more initial velocity is required and downward force gets also greater, am I right ?
Thanks in advance.
You do not need to consider downward force explicitly. It is enough to know that the deceleration due to gravity is always -g. Thus, the time taken to reach zero velocity is simply obtained from the deceleration equation below,
$$0-v_0=-gt$$
which leads to
$$t=\frac{v_0}{g}$$
So, the larger the initial velocity is, the longer it takes to reach zero velocity.
If you were able to change the gravity (downward force), the new gravity $G$ required for the projectile to reach $h$ in $t$ would be
$$G=\frac{2h}{t^2}$$