How can i get analytical solution

I can't use ode45 or dsolve
this is the Question we are given
my code (sorry for not adding any comments)
clear
%PARAMETERS
m = 8000; %kg
v = 80; %m/s
r = 250; %m
gravity = 9.81; % m/s^2
%rate_of_turn = ((2*pi)/time);
%t_360 = 2*(((pi)*turn_radius)/speed);
t_180=(pi*r)/v;
dt=0.001;
t=0:dt:t_180;
x=zeros(1,length(t));
y=zeros(1,length(t));
dVx = zeros(1,length(t));
dVy= zeros(1,length(t));
x(1) = 0;
y(1)=0;
Velcoity_x(1) =0;
Velocit_y(1)=0;
F= (m*(v^2))/r;
for i=2:length(t)
angle(i)=angle(i-1) +t_180*dt;
Velcoity_x(i)=v*cos(angle(i));
Velocit_y(i)=v*sin(angle(i));
dx(i)=Velcoity_x(i)*dt;
dy(i)=Velocit_y(i)*dt;
x(i)=x(i-1)+dx(i);
y(i)=y(i-1)+dy(i);
dVx(i)=(Velcoity_x(i)-Velcoity_x(i-1))/dt;
dVy(i)=(Velocit_y(i)-Velocit_y(i-1))/dt;
Force_x=dVx(i)*m;
Force_y=dVy(i)*m;
F(i)=((Force_x^2)+(Force_y^2))^0.5;
end
plot(x,y)
grid on
please help

 Respuesta aceptada

Walter Roberson
Walter Roberson el 29 de Abr. de 2020

0 votos

You get an analytic solution by working through the calculas on paper.
By definition a numeric solution is never an analytic solution, so no numeric approach can ever find the analytic answer.
That leaves you with the choice of working it out by hand on paper (or equivalent), or else of using symbolic software such as dsolve(). But your other question says you are not permitted to use dsolve(), so that leaves you using paper (or equivalent)

Más respuestas (0)

Categorías

Más información sobre Programming en Centro de ayuda y File Exchange.

Preguntada:

el 29 de Abr. de 2020

Respondida:

el 29 de Abr. de 2020

Community Treasure Hunt

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

Start Hunting!

Translated by