Functions | |
function | display (p) a |
fprintf ("%s =", inputname(1)) | |
if (a(i)!=0) if(first) first | |
elseif (a(i) > 0) fprintf(" +") | |
endif | if (a(i)< 0) fprintf(" -") |
endif | if (i==1) fprintf(" %g" |
endif | abs (a(i))) |
elseif (abs(a(i))!=1) fprintf(" %g *" | |
endif | if (i > 1) fprintf(" X") |
endif | if (i > 2) fprintf(" ^ %d" |
endif endif endfor | if (first) fprintf(" 0") |
endif | fprintf ("\n") |
Variables | |
first = true | |
for | i = 1 : length (a) |
abs | ( | a(i) | ) |
function display | ( | p | ) |
elseif | ( | abs(a(i))! | = 1 |
) |
elseif | ( | a(i) | , | |
0 | ||||
) |
endif fprintf | ( | "\n" | ) |
fprintf | ( | ) |
endif if | ( | i | , | |
2 | ||||
) |
endif if | ( | i | , | |
1 | ||||
) |
endif if | ( | i | = = 1 |
) |
endif if | ( | ) |
if | ( | a(i)! | = 0 |
) |
first = true |
for i = 1 : length (a) |