Solve Curveball Modeling Using Runge-Kutta4

  • Thread starter ryankunzzz
  • Start date
  • Tags
    Modeling
In summary, the ball is spinning about the axis coming out of the paper if you were to be looking down on to it. Under this assumption, your equations for velocity are correct.
  • #1
ryankunzzz
21
0
Hi there, so for my Differential equations class we are trying to model the vertical displacement of a curveball that is only in 2 dimensions, the X-Y plane, with Y being the vertical displacement, and X being the horizontal displacement.

To do this we were told that the 2 forces acting on the ball would be the force of gravity, and the magnus force due to the rotation of the ball. the problem is, the ball is thrown at an upward angle with a forward spin, and because the magnus force always acts perpendicular to the velocity of the ball it will always have 2 components, also x and y.

So far I have gotten my equations for the acceleration in both directions, and I think the equations for velocity in both directions, but I am having trouble solving the differential equations themselves. He hinted that using Runge-Kutta4 would be our best bet, but the equations are confusing me.

These are the 2nd derivative of displacement in each direction:
If Ay= -g - kVxω Where kVxω is the Y component of the magnus force.

Then Ax= +KVyω which is the X compenent of the magnus force,

Then our velocity equaions, which are the firs derivative of displacement, of should be:

Vy=Ay*t + Vy0 and
Vx=Ax*t + Vx0

But I'm totally stuck on how to apply Runge-Kutta4 to this.
 
Physics news on Phys.org
  • #2
Your velocity equations don't seem correct to me. Ay and Ax are not necessarily constant in time.

i think the proper velocity equations can come out like this:

By taking the time derivative of both sides of the equation for Ay we will have [itex]\frac{dA_y}{dt}=-kA_x\omega[/itex] and replacing [itex]A_x=kV_y\omega[/itex] we get
[itex]\frac{dA_y}{dt}=-k^2V_y\omega^2[/itex] or [itex]\frac{d^2V_y}{dt^2}=-k^2\omega^2V_y[/itex]. With similar way you can get an equation for V_x. I hope this form is suitable for the Runge-Kutta method.

But then again such ODE have analytic solution, maybe your system of equations for the accelerations Ax and Ay is not correct at first place.
 
Last edited:
  • #3
Yes sorry, the accelerations are not constant in time, but are depending on the opposite velocity from the step before hand.
 
  • #4
Upon more research it seems we should be trying to solve these as 2 coupled 2nd order ODE's, which we can bring down into 4 first order ODE's and use Runge-Kutta on, but that is where I'm stumped.
 
  • #5
Hmmmm, maybe you forgot the drag force from air [itex]\vec{F_d}=-b\vec{v}[/itex] in the modeling of the equations for A_x and A_y?

Also the ball is spining around which axis?
 
  • #6
We were told to only take two forces into account, Magnus, and the force of gravity.

The ball is spinning about the axis coming out of the paper if you were to be looking down on to it.
 
  • #7
Well all i can assume is that your professor wants you to test RK4 method though the equations seem to have exact analytic solution.

To the problem now I suppose we can further assume that the accelerations A_x and A_y do not vary much in time so as to consider them almost constant. Under this assumption your equations for velocity are correct. So it will be [itex]V_x=A_xt+V_{x_0}=kV_y\omega t+V_{x_0}[/itex] and replacing that expression in the equation for A_y we get [itex]\frac{dV_y}{dt}=-g-k^2\omega^2tV_y-k\omega V_{x_0}[/itex]. This last equation is obviously in RK4 form [itex]v'=f(t,v)[/itex].

You ll get another equation for V_x working in similar way. Together with the trivial equations of the definition of velocities [itex]V_x=dx/dt , V_y=dy/dt[/itex] you ll have a total of 4 first order ODEs.
 
Last edited:
  • #8
The assumption that the accelerations are constant is what gets me. Wouldn't the accelerations at each point be dependent on the velocity of the opposite component at that point? So the Acceleration of x depends on the velocity of Y, and vice versa, and then those accelerations give the next velocities we would be using?
 
  • #9
How does this look?
o4FUQql.jpg
 

FAQ: Solve Curveball Modeling Using Runge-Kutta4

1. What is curveball modeling?

Curveball modeling is a mathematical approach used to simulate the trajectory of a thrown ball. It takes into account various factors such as gravity, air resistance, and spin to accurately predict the path of the ball.

2. What is Runge-Kutta4?

Runge-Kutta4 is a numerical method used to solve differential equations, such as the ones used in curveball modeling. It is a fourth-order algorithm that is known for its high accuracy and efficiency.

3. How does Runge-Kutta4 work in curveball modeling?

In curveball modeling, Runge-Kutta4 is used to solve the differential equations that describe the motion of the ball. It takes multiple small steps to approximate the solution and uses a weighted average of these steps to improve the accuracy of the prediction.

4. Why is Runge-Kutta4 preferred for solving curveball modeling?

Runge-Kutta4 is preferred for solving curveball modeling because of its high accuracy and efficiency. It is also a stable method that can handle complex differential equations, making it well-suited for simulating the complex trajectory of a thrown ball.

5. Can Runge-Kutta4 be used to solve other problems besides curveball modeling?

Yes, Runge-Kutta4 can be used to solve a wide range of problems involving differential equations, such as in physics, engineering, and economics. It is a versatile method that can be applied to various fields of study.

Back
Top