a) 

a = 10-(77+88)
a =
	-155


b) 

b = 29/13
b =
    2.2308


c)

c = (29/13)^2
c =
	4.9763


d) 

c = cos(pi/2)/2
c =
   3.0616e-17


I)

h = 0
h = h + c;
h = h + c;
h = h + c;
h = h + c;
h = h + c
	24.8817


II)

e = a^2/3+5
e =
   8.0133e+03


III)

f = log(b)
f =
    0.8023


IV)

g = c^(1/3)
g =
    1.7073


V)

i = d/3
i =
   1.0205e-17

cos(pi/2) = 0, men datamaskinen kan bare bruke endelig mange desimaler i sine utregninger, dermed oppstår det en avrundings feil.

 

 

  • No labels