Derivatives and antiderivatives: We consider the function f(x) = x sinx a) Derivatives: The first derivative with respect to x can be found using the commands syms f - x sin(x) dEx (x) diff (f,x) which gives the answer dfx (x) sin(x) + x*cos(x) b) Antiderivatives: An antiderivative' of f(x) can be found using the command int. ans -2 -1 c) MATLAB's Anonymous Functions and plotting: sin(x) To define the function f(x) = as an anonymous function, and plot its graph in the interval (-51,57), we use the following commands syms x f = sin(x)/(x) ezplot (f, 1-5*p1,5*pil) symsti solve (t^2+3*t+2-0) MATLAB executes the commands and retums the roots of the equation, i.e. n- mean (v) b) Solving algebraic equations: We define a symbolic variablet and ask MATLAB to solve the equation t? +31 + 2 = 0. To create a variable m and assign to it the maximum clement in the vector v, we use the command m = max(v): In a similar way, we create a variable n and assign to it the mean value of the elements in v. For instance, the command v = 11 2 3 4 5 6): creates a column vector with six elements. MATLAB vectors are created by enclosing the set of elements in square brackets using space or comma to delimit the elements. Some basic commands a) Create a vector and find the maximum and mean value of its elements: A vector is a one-dimensional array of numbers. Alternatively, one can use the Symbolic package of the free and open source software GNU Octave. In this project, we focus on MATLAB's Symbolic Math Toolbox. Mathematical software with this ability are called Computer Algebra System (CAS).
AREA BETWEEN TWO FUNCTIONS IN MATLAB SYMBOLIC TOOLBOX MANUAL
Introduction Symbolic mathematics is the use of computers to manipulate mathematical equations and expressions in symbolic form, that is, in a way similar to the traditional manual computations.