We should create an object motion model. We have such information:

$\overrightarrow{v}$ - object's basic velocity;

$m$ - object's mass;

$\overrightarrow{F}=|v|^2k$ - the law of air resistance force. It directed against $\overrightarrow{v}$;

$x_0,y_0$ - object's basic position;

$\overrightarrow{g}$ - default gravity, directed against $Oy$ axis;

I tried to solve it. My solution without gravity was not full, because I don't know how to discribe it.

Let $\overrightarrow{g}=0$, $x_0=0$, $y_0=0$, $\overrightarrow{v}=\overrightarrow{v_x}$.

Using $v_{n}=v_{n-1}-\frac{F_{n-1}}{m}t$ we can find the relation of velocity of each second (let force affect just every second):




and so on. How can we write out this relation using differentials or integrals?

And how can we define the whole model of the problem?

Finally, we should get functions that can define $x_t,y_t$ - object's position at the given time $t$.

For example: $x(t)=x_0+v_0t-F(t,v_0)$.

  • $\begingroup$ How can we write out this relation using differentials or integrals? Why would you expect to be able to describe motion with changing velocity without using differentials? $\endgroup$ – G. Smith Nov 9 '19 at 17:47
  • $\begingroup$ @G.Smith I actually don't know, just tried to squeeze out of myself everything $\endgroup$ – Egor Randomize Nov 9 '19 at 17:49
  • $\begingroup$ Equations of motion are generally differential equations. You should be able to write one for $m\frac{d\vec v}{dt}$. The right hand side would have two terms for the two forces. $\endgroup$ – G. Smith Nov 9 '19 at 17:50
  • $\begingroup$ @G.Smith I can solve integrals, but I can't build integrals or differentials to solve the problem. It is difficult for me, but I really want to understand it. A good reason to research this branch. $\endgroup$ – Egor Randomize Nov 9 '19 at 17:54
  • $\begingroup$ What you basically need is Newton's laws of motion. The momentum of a point mass changes depending on the forces acting on it according $m \vec a = \sum\limits_i \vec F$ and so does any body around its center of gravity. Additionally consider $\vec a = \frac{d \vec v}{d t}$. You are left with two scalar equations to integrate. $\endgroup$ – 2b-t Nov 10 '19 at 1:23

This is a simple application of Newton's law

$$ m \vec a = m \frac{d \vec u}{d t} = m \frac{d^2 \vec x}{d^2 t} = \sum\limits_i \vec F_i .$$

Systems of equations

The equation system is thus given by

$$ m \frac{d}{d t} \left( \begin{array}{} u_x\\ u_y\\ \end{array} \right) = m \left( \begin{array}{} \phantom{-}0\\ -g\\ \end{array} \right) - k \sqrt{u_x^2 + u_y^2} \left( \begin{array}{} u_x\\ u_y\\ \end{array} \right)$$

where $\left( \begin{array}{} u_x\\ u_y\\ \end{array} \right) = \frac{d}{d t} \left( \begin{array}{} x\\ y\\ \end{array} \right).$

Now in order to solve it you will have to use some numerical integration. You see it is tricky as the damping term depends on the amplitude of the velocity vector. You will have to make assumptions about which terms will be used from which time step and how the differentials should be approximated by finite differences.

You have several options. A simple choice would be the 2nd order accurate three point explicit central difference integration for the second derivative assuming that the velocity (first derivative) in the damping term can be assumed constant

$$ m \frac{d^2}{d^2 t} \left( \begin{array}{} x\\ y\\ \end{array} \right) = m \left( \begin{array}{} \phantom{-}0\\ -g\\ \end{array} \right) - k \sqrt{u_x^2 + u_y^2} \left( \begin{array}{} u_x\\ u_y\\ \end{array} \right),$$

$$ \frac{m}{\Delta t ^2} \left( \begin{array}{} x(t+ \Delta t) - 2 x(t) + x(t-\Delta t) \\ y(t+ \Delta t) - 2 y(t) + y(t- \Delta t) \\ \end{array} \right) \approx m \left( \begin{array}{} \phantom{-}0\\ -g\\ \end{array} \right) - k \sqrt{u_x(t)^2 + u_y(t)^2} \left( \begin{array}{} u_x(t)\\ u_y(t)\\ \end{array} \right).$$

Rearrange the formula for $x(t + \Delta t)$ and $y(t + \Delta t)$ to obtain an approximation for the current position. In this case you will have to store two arrays for two different time steps (e.g. $x(t)$ and $x(t - \Delta t)$) in order to update the third one ($x(t + \Delta t)$, it can be stored in $x(t - \Delta t)$ and you can swap pointers then) as well as arrays for the velocities. So for a 2D case 6 different arrays.

If you are not planning on explicitly storing the velocities you might try a backwards difference for the velocity in the air resistance term

$$ \left( \begin{array}{} u_x(t) \\ u_y(t) \\ \end{array} \right) \approx \frac{1}{\Delta t} \left( \begin{array}{} x(t) - x(t- \Delta t) \\ y(t) - y(t- \Delta t) \\ \end{array} \right). $$

In this case 4 arrays will suffice. But you might also discretise it in terms of $u_x(t+ \Delta t)$ by means of a central difference as well and solve the resulting coupled non-linear equations with a corresponding library or an approximate iterative numerical solver. For further questions I suggest you turn to the Computational Science Stack Exchange instead of here.

While it turned out the following section is not relevant for this particular problem as the question is of numerical nature, I will still leave it in here:

Approximate analytical solution

You put your 2D coordinate system in such a way that you are pointing in the direction of the objects motion and thus in the direction of the air resistance, and the other axis perpendicular to it. If you shoot in an angle with respect to gravity the corresponding gravity term enters the equation of motion as well. Rewrite the velocity in the air resistance term as

$$ \vec F_R (\vec u) = - k | \vec u | \vec u $$

this way it now always points in the opposite direction of $\vec u = (u, v)$ with the wished air resistance.

In the simplest case you can assume that the direction you shoot the object into is dominating $| u | >> | v |$ and as a consequence $F_R (\vec u) \approx F_R (u)$. Thus, we have no coupling between the two as follows. This is also what seems to be the task in your case.

If that would be not the case - the time of flight either long or the contribution of gravity significant - you would have to transform your system in such a way that your local x-direction always points in the direction of maximal magnitude (in a real scenario the direction of the velocity vector changes as gravity is constantly pulling downwards but your momentum in the direction you shot the projectile in will diminish over time due to gravity) and thus handle a transformation that changes in time or solve a coupled system of equations for both directions where each term has a contribution of the air resistance. This is too cumbersome to be solved by hand!

In the simplified case that you have to consider, you determine the equation of motion for a local coordinate system that may also be rotated with respect to the horizontal direction with an angle $\alpha$

$$ m \frac{d u}{d t} = \underbrace{- k | u | u}_{F_R} - sin(\alpha) \underbrace{ m g }_{F_g} $$

$$ m \frac{d v}{d t} = - cos(\alpha) \underbrace{ m g }_{F_g} $$

considering your initial conditions $x(0) = x_0$, $y(0) = y_0$, $u(0) = u_0$, $v(0) = v_0$, $\frac{d u}{d t} (0) = a_0$ and $\frac{d v}{d t}(0) = b_0$. Beware that these equations only hold as long as the velocity in the local x-direction is dominating.

I think that is the way this is intended to be solved by hand and will leave this integration now to you. Split the integration up into two case, for a positive and a negative $u$ and you are done. Use WolframAlpha, special cases and the overall trends of the evolution of position, speed and acceleration to check the correctness of your integration. If you are interested in a case where the system is rotated you will have to transform your rotated system (watch out for the direction of $\alpha$!) back to the reference frame. If you are only interested in an object that is travelling horizontally while the gravity acts vertically use $\alpha = 0$.

Attention: My equations of motions are for a coordinate systems where the axis are different from yours. Find the difference and apply the idea to your system.

  • $\begingroup$ Example for the positive case with WolframAlpha: wolframalpha.com/input/?i=m+x%22+%3D+-+k+x%27%5E2 $\endgroup$ – 2b-t Nov 10 '19 at 13:01
  • $\begingroup$ @2b-2 great thanks! But how can we solve it using gravity? And in case, where velocity has own angle. I suppose the given task was to get the solution for any velocity (any direction), taking into account gravity $\endgroup$ – Egor Randomize Nov 11 '19 at 12:46
  • $\begingroup$ @EgorRandomize My approach considers gravity by solving a separate equation for it but it does not have an impact on air resistance. It is also valid for every angle as well. Basically the gravity leads to the projectile dropping slowly and the air resistance is only considered for the component in the direction of motion. I don't know if that is the solution for your assignment but anything else leads to coupled differential equations that are quite tricky to integrate. I can probably help you more if you provide the full assignment and which course (at which level) this is for. $\endgroup$ – 2b-t Nov 11 '19 at 13:05
  • $\begingroup$ @EgorRandomize Furthermore do you need to fully solve it or only translate what you have done so far to differential notation? $\endgroup$ – 2b-t Nov 11 '19 at 13:10
  • $\begingroup$ @2b-2 I appreciate your assistance! My full task is to make a computer program that can compute the point's position at any given time $t$. I divided the task into a couple stages, and now I have stopped on stage "to make the math model". So, in this stage, integrals and differentials are welcome. By the way, I'm a student of IT faculty, and our basic physics program is too weak to solve the same problems. If you mean the level of approximation to natural behavior, we can use the given formula for computing air resistance. So it is okay when the solution contains integrals or differentials. $\endgroup$ – Egor Randomize Nov 11 '19 at 13:29

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