Académique Documents
Professionnel Documents
Culture Documents
name = inputname(argno);
where argno is the number of the argument. If the argument is a
variable, then its name is returned. If the argument is an expression,
then this function will return an empty string. For example, consider
the function
function myfun(x,y,z)
name = inputname(2);
disp(['The second argument is named ' name]);
Both of them are much faster and much more “random” than the
simple function that we have created. If you really need random
numbers in your programs, use one of these functions.
Functions rand and randn have the following calling sequences: