blob: 8bbbf64482686b9bf20179675da7c7d049d1e233 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
//SCI2C: DEFAULT_PRECISION= DOUBLE
function mainfunction()
disp(abs(7))
disp(abs(-3))
disp(abs(7-%i))
disp(abs(7+%i))
disp(abs(-3-2*%i))
disp(abs(-3+2*%i))
a=[-1 -5 4 -7; -8 3 -74 -5; 141 -3 4 45]
b=[1+%i*7 2 5+%i*4; 4+%i*21 8+%i 6; 3-%i*7 4-%i*2 78 ]
disp(abs(a))
disp(abs(b))
endfunction
|