# MATLAB - Suranaree University of Technology

MATLA B Week 7 Numerical Integration and Differentiation x h f x1 dy f lim 1 dx h 0

h y=f(x) dy f(x1) h=dx x1 x1+h x

MATLAB diff(x) element x [x(2)-x(1), x(3)-x(2),x(2)-x(1), x(3)-x(2), ,x(n)-x(n-1)] diff(x,n) element x n A

A MATLAB 1 x d cos x + sinsin(x) cos(x) dx x

x y d f x, y MATLAB 2x y 2 dx 2

x y MATLAB polyder(A) A

a Q f x dx b f(x) a

b x (Trapezoidal rule) h Q f x f x 2 f x 2

k1 0 n k k 1 f(x) b

a x0 x1 xi xn b a h n x

(Trapezoidal rule) trapz(x,y) y cumtrapz(x,y) y

(Trapezoidal rule) trapezodalc (Symsons rule) n n 1 n 2 h Q f x0 f xn 4 f xk 2 f xk 3 b a

h n k 1, 3, 5 k 2 , 4 , 6 (Symsons rule) Q=quad(F,a,b) F

a b Symsons rule (Symsons rule) -

Q=quad8(F,a,b) F a b Newton-Cotes error = 10-3 () Q=quadl(F,a,b) F a b Newton-Cotes error = 10-6 -

- int symbolic int(E) E int(E,v) E

v int(E,a,b) E a b int(E,v,a,b) E v a b

A t 3 t 1. 2. A(t) t=1.85 A(t) 1 pi

2 0.8-1.2 2t x 1 x e 0 cos 3t 3

0 1. 2. 2t 2

e cos 3t x 1 x 1. 2. sin xt 3.

## Recently Viewed Presentations

• Ryan Wang, US Economist HSBC Securities (USA) Inc. [email protected] +1 212 525 3181 February 2012 * * Advanced economics: Just over 50% of US exports Source: Netherlands Bureau for Economic Policy Analysis * Eurozone import volumes have stalled Source: Netherlands...
• Why Adopt A Budget. Kansas Budget And Cash Basis Laws. Fund Accountability. Budget Authority. Budget Timeline. Forms To Be Used. ... it is recommended that you review current year expenditures in relation to budget authority - along with receipts -...
• Slide 1 ... china
• Rising temperatures will slowly lower the amount of CO2 that can be dissolved in the oceans, pulling it out and adding to GHG warming coming out of an Ice Age. This mechanism explains why temperature rises preceeded CO2 rises IN...
• -Examples Grasshoppers Rabbits Deer Beavers Moose Cows Sheep Carnivores Organisms that only eat other animals. -Examples Foxes Frogs Snakes Hawks Spiders Lions Omnivores Organisms that eat both plants and animals. -Examples Bears Turtles Monkeys Squirrels Decomposers End of all food...
• Biostratigraphy Type Units Defined? True time units? Litho Member Formation Group Rock lithology No - time transgressive Bio Zone Stage Fossils Sort of Chrono Eon, Era, Period, Epoch, Age Time Yes, but how do you measure?
• Beginning of Class . 1. Get a chrome book and get logged on! 2. Take Russian Revolution Quiz. On Mr. Mathews Website . 3. Complete Analytical Thesis Practice Quiz
• Define Physical Fitness. Physical Fitness is "a dynamic state of energy and vitality that enables one to carry out daily tasks, to engage in active leisure-time pursuits, and to meet unforeseen emergencies without undue fatigue…". Physical Fitness . is "the...