Introduction to programming in MATLAB - MIT OpenCourseWare | Free Online Course Materials
Numerical Differentiation • MATLAB can 'differentiate' numerically » x=0:0.01:2*pi; » y=sin(x); » dydx=diff(y)./diff(x); ¾diff computes the first difference • Can also operate on matrices » mat=[1 3 5;4 8 6]; » dm=diff(mat,1,2) ¾first difference of mat al...