Example of symbolic expression, MATLAB in Mathematics

Example of Symbolic Expression

When there is more than one variable, the MATLAB selects which to solve for. In the illustration below, the equation ax2 + bx = 0 is solved. There are three variables. Since it can be seen from the result, that is given in terms of a and b, the equation was solved for x. The MATLAB has rules built in that to identify how to select which variable to solve for. For illustration, x will always be the first preference if it is in the expression or equation.

>> solve('a*x^2 +  b*x')

ans =

        0

 -b/a

Though, it is possible to identify which variable to solve for:

>> solve('a*x^2 +  b*x','b')

ans =

-a*x

Posted Date: 10/22/2012 6:47:27 AM | Location : United States







Related Discussions:- Example of symbolic expression, Assignment Help, Ask Question on Example of symbolic expression, Get Answer, Expert's Help, Example of symbolic expression Discussions

Write discussion on Example of symbolic expression
Your posts are moderated
Related Questions
The variance is generally defined in terms of the arithmetic mean as: At times, though, the denominator is defined as n instead of n - 1. The default definition used by t

Logical Vectors: The relational operators can also be used with the vectors and matrices. For illustration, let's say that there is a vector, and we want to compare each eleme

Illustration of Writing to files: Here is the other illustration in which a matrix is written to a file. At First, an arbitrary 2 × 4 matrix is generated, and then it is writt

Script a MATLAB program which meets the following speci cations: The program expects an input of a two-variable real-valued continuous function f : R^2--> R The program is to cal

Minimum and Maximum Value The MATLAB has built-in functions for numerous statistics. For illustration, min and max to find the minimum or maximum value in a data set. >> x

Nested IF-ELSE statements: The if-else statement is used to select between the two statements. In order to select from more than two statements, the if-else statements can als

Function fopen - file function: The permission string in the call to the fopen function identifies that the file is opened for writing to it. Just as when reading from a file,

Print an imaginary number: To print an imaginary number, the function disp will show both parts automatically: >> disp(z1)    4.0000 + 2.0000i The function fprint

Writing to Files: There are many lower level functions which can write to files. We will focus on the fprintf function that can be used to write a file and also to append to a

Dimensions - matrix: The size and length functions in the MATLAB are used to find array dimensions. Length function returns the number of elements in the vector. The size func