Graphics Reference
In-Depth Information
Appendix A
Numbers, Variables, Operators
and Functions Used in Graphics
Programming
A.1 Variables
Variables and functions have an important role in graphical programming. Especially the vector and matrix variables.
MATLAB does not require any command to declare variables. Simply create the variable by direct allocation of its
value. For example:
>> v = 3
v =
3
The variable v will be worth 3 unless its value is changed by using a new mapping. Once the variable is declared
we can use it in calculations.
>> v ^ 3
Ans =
27
>nmr4eb]\tb5r'> v+5
Ans =
8
The value assigned to a variable is permanent, until changed explicitly it is defined outside the current
MATLAB session.
 
Search WWH ::




Custom Search