Return to the home page.

The Ultimate Windows Math Toolbox

 


bullet Ver 3.1.805
8 September 2008
bullet Free support
bullet Only $44.85 (US)
(Professional)
Click to buy UltimaCalc Professional
bullet Only $34.85 (US)
(Standard)
Click to buy UltimaCalc Standard.

bullet Free download

<<< Prev  Next >>>
Algebra - Introduction   

 

Equations

UltimaCalc's Algebra module can performs some operations with equations. An equation is specified by writing two expressions separated by an equals sign. The equals function is used as a structure to hold the two sides of an equation.

Examples:
2 + x = 3 * y
a = b + c


Assignment statements

Be sure not to confuse equations with assignment statements. The following expression uses a colon before the equals sign:
a := b + c
This is an assignment statement that gives the symbol a the value b+c by storing this value inside structure of the symbol. On the other hand, an equation is a statement of a relationship of equality between two expressions.


lhs(eqn)   and   rhs(eqn)

These two functions return the left hand side or the right hand side respectively of an equation. They are useful when an equation has been assigned to a symbol.

Examples:
Give symbol a1 an equation as its value: a1 := 2+x = 3*y. Then:
lhs(a1) returns 2 + x
rhs(a1) returns 3 * y


Operations on equations

You can add, subtract, multiply or divide an equation by another expression. When two equations are added, subtracted, or multiplied, the left hand sides and the right hand sides will be dealt with separately. At present, division of two equations does nothing useful.

Examples:
Giving the symbol a1 an equation as its value: a1 := 2+x = 3*y confirms with a1 := equals(2+x, 3*y).
Giving symbol a2 an equation as its value: a2 := 3+x=y confirms with a2 := equals(3 + x, y).
You can now perform operations using the values of these two symbols:
3*a2-a1 gives equals(7 + 2*x, 0)
a1*a2/3 gives equals(2 + 5/3*x + 1/3*x^2, y^2)