MTH643 Final Term Mega File All in 1 2022 by Everblue
- Type
- Final term past paper
- Course
- MTH643 Introduction to MATLAB
- Size
- PDF 16.8 MB
- Updated
- 23 Oct 2026
You get 3 free files a day on the website. Add the Chrome extension for 30 a day.
Preview text
Text from pages 2, 3, 4 of 168. Download the file for all 168 pages.
yy=eval(vectorize(y)); zz=eval(vectorize(z)); plot(t,xx,t,yy,t,zz)
title(' Graph of solution curves of DE') grid
using Euler’s Formula for n=10, function [xvalues,yvalues]=euler(f,x0,y0,xn,n);
x0=0; y0=pi; xn=1; n=10; x(1)=x0; y(1)=y0; xn=1; dx=(xn-x0)/n; for k=1:n
y(k+1)=y(k)+sin(x(k)*y(k))*dx; end xvalues=x' yvalues=y'
[0; 1] using Euler’s method for n = 20.
%using Euler’s method for n = 20. dy/dx=(y-x)/(y+x) ,y(0)=0.5 function [xvalues,yvalues]=euler(f,x0,y0,xn,n);
x0=0; y0=0.5; xn=1; n=20; x(1)=x0; y(1)=y0; xn=1; dx=(xn-x0)/n; for k=1:n
y(k+1)=y(k)+((y(k)-x(k))/(y(k)+x(k)))*dx; end xvalues=x' yvalues=y' [0; 1] using improved Euler’s Formula for n=10,
(P#231-235 – LECT#08)
%using improved Euler’s Formula for n=10, dy/dx=Sin(xy),y(0)=? function [xvalues,yvalues]=impeuler(f,x0,y0,xn,n);
x0=0; y0=pi; xn=1; n=10; x(1)=x0; y(1)=y0; xn=1; dx=(xn-x0)/n; for k=1:n
y(k+1)=y(k)+dx/2*(f(x(k),y(k))+f(x(k),y(k)+dx*y(k))); end xvalues=x' yvalues=y'
[0,1] using Improved Euler’s method for n = 20.
%using Improved Euler’s method for n = 20. dy/dx=(y-x)/(y+x) ,y(0)=0.5 function [xvalues,yvalues]=impeuler(f,x0,y0,xn,n);
x0=0; y0=1; xn=0.5; n=20; x(1)=x0; y(1)=y0; xn=1; dx=(xn-x0)/n; for k=1:n
y(k+1)=y(k)+dx/2*(f(x(k),y(k))+f(x(k),y(k)+dx*y(k))); end xvalues=x' yvalues=y' L08_Q44: Find the numerical solution of the following initial value problem on the interval [0,1] using improved Euler’s method by taking step size ∆𝑡= 0.01, Moreover, plot the graph of the approximated solution curve. Note: The iterative form of the improved Euler’s method is given below;
%Find the numerical solution of the following initial value problem on the interval [0,1] %using improved Euler’s method by taking step size ∆t=0.01, %Moreover, plot the graph of the approximated solution curve. dy/dt=(y-t)/(y+t) ,y(0)=0.5 function [yvalues,tvalues]=impeuler(f,y0,t0,yn,n);
y0=0; t0=1; yn=0.5; n=20; y(1)=y0; t(1)=t0; yn=1; dt=0.01; for k=1:n y(k+1)=y(k)+dt; t(k+1)=t(k)+dt/2*(f(y(k),t(k))+f(y(k),t(k)+dt*t(k))); end yvalues=y' tvalues=t' plot(yvalues,tvalues)
dy dx = Sin xy , y 0 = π
%using Runge–Kutta method of fourth order for n=10, dy/dx=Sin(xy),y(0)=?
x0=0; y0=pi; xn=1; n=10; x(1)=x0; y(1)=y0; dx=(xn-x0)/n; for k=1:n
Related MTH643 files
All MTH643 files →- MTH643 Final Term Current Paper 2022 Final term PDF 353 KB
- MTH643 Final Term MCQs 2023 Final term PDF 815 KB
- MTH643 Final Term Past Paper Feb 2023 by S Khan Academy Final term PDF 982 KB
- MTH643 Final Term Past Paper Sep 2020 Final term PDF 536 KB
- MTH643 Midterm Special Handouts Lectures 1-8 Handout PDF 12.1 MB
- MTH643 Solved Questions Lectures 9-15 Set 2 Quiz PDF 718 KB
Get more out of VUBuddy, for free
- Unlimited downloads
- The explanation behind every MCQ answer
- Study offline on slow data
- 30 downloads a day instead of 3
- Sign in and buy Pro Semester here
One Pro Semester membership works in both the extension and the app.