I have to finish the code given by my diff eq professor to analyze the lorenz...

80.2K

Verified Solution

Question

Advance Math

I have to finish the code given by my diff eq professor toanalyze the lorenz function at different initial conditions anddifferent values for p. I am not sure how to input the lorenzfunction in the way the code is set up.

Here is the code provided for matlab:

function lorenz

s = 10;
b = 8/3;
p = 0.15;

y = @(t,x) [ ; ; ]; % you are responsible for entering thelorenz system here

T = [0 200]; % sets the time interval; no need to edit
x0 = [1 1 1]; % initial conditions; this can and should beeditied

[t,x] = ode45(y,T,x0); % ode solver; do not edit

plot3(x(:,1),x(:,2),x(:,3),'r') % plots 3d solution for enteredconditions

grid on

Answer & Explanation Solved by verified expert
4.0 Ratings (459 Votes)
Matlab code for Lorenz equation solutionclear allclose allvalue for alpha beta and etas10 p015 b83and initial condition of yy101 y201 y301initial value for tt00t end valuestend200y0y10y20y30minimum and maximum time span tspant0 tend Solution of ODEs usingode45 matlab function sol ode45tyodefcn1tyspb tspan y0 t1 linspacetspan1tspanend100001 yy is the correspondingx y v and z yy1 devalsolt1figure1plot3yy11yy12yy13xlabely1ylabely2zlabely3title3d line plot for Lorenz attractor initial cond 1 1 1 andp015value for alpha beta and etas10 p10 b83and initial condition of yy101    See Answer
Get Answers to Unlimited Questions

Join us to gain access to millions of questions and expert answers. Enjoy exclusive benefits tailored just for you!

Membership Benefits:
  • Unlimited Question Access with detailed Answers
  • Zin AI - 3 Million Words
  • 10 Dall-E 3 Images
  • 20 Plot Generations
  • Conversation with Dialogue Memory
  • No Ads, Ever!
  • Access to Our Best AI Platform: Flex AI - Your personal assistant for all your inquiries!
Become a Member

Other questions asked by students