Solving Equations of motion with ode15s

2 visualizaciones (últimos 30 días)
Brendan Görres
Brendan Görres el 3 de Mayo de 2019
Comentada: Torsten el 6 de Mayo de 2019
Recently I am trying to solve a system of equations with ode15s. The goal is to calculate the Ascent trajectory of a Rocket with a control variable alpha, which is the angle between the velocity vector v and the thrust vector, so that by changing alpha manually I should change the flight direction.
%Thrust vector control variable
alpha=(-2*pi/180)
%alpha=(-2*pi/180)*t+10
%alpha=0.5*(-2*pi/180)*t^2+10*t+0.01...assumed to be konstant/linear/quadratic[rad]
%functions
gh=g0*((re/h)^2);%Gravi*tationsbeschleunigung abh. von h
rhoh=rho0*exp(-h/sh);%Luftdichte abh. von h
%EoM
dydt=(thrust*sin(alpha)/m*v)-(v*cos(y)/h)-gh*cos(y);
dvdt=(thrust*cos(alpha)/m)-gh*sin(y)-(rhoh*Adrag*(v^2)/2*m);
dhdt=v*sin(y);
dxddt=(re/h)*v*cos(y);
dmdt=-propflow;
dwdt=(1/Ix)*thrust*sin(alpha)*rs;
in a first run I assume alpha to be konstant and I experimented a little bit with the value (so for example alpha=-2*... and in the next run alpha= +10*...). In a next step I assumed alpha to be linear so for example
alpha=(-2*pi/180)*t+10
and in a last step I assumed it to be quadratic:
alpha=0.5*(-2*pi/180)*t^2+10*t+0.01
I am using ode15s to solve the equations, because my code needs to include the algebraic variable t.
I plotted the results over t and I receive the exact same plots for every single run, regardless of alpha being konstant linear or quadratic.
How is that possible?
  11 comentarios
Brendan Görres
Brendan Görres el 3 de Mayo de 2019
ok I see I forgot the brackets, but again can you help me with my question?
Torsten
Torsten el 6 de Mayo de 2019
And the values you get for the variables look realistic to you ? E.g. a velocity of 12000 m/s ?
I suggest you reinspect your equations first before going into details about the setting of "alpha".

Iniciar sesión para comentar.

Respuestas (0)

Categorías

Más información sobre Ordinary Differential Equations en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by