printf('prva naloga\n');
k=0:10;
s= (-1).^k./(2*k+1)./gamma(k+1); 
tintegral=sum(s);
integral=gammainc(1,1/2)/2*gamma(1/2);
delta=abs((integral-tintegral)/integral);
printf('tintegral=%0.10f integral=%0.10f delta=%0.10f\n\n',...
tintegral,integral,delta);
%
printf('druga naloga:\n');
x=0.01;
i1=(sqrt(1+x)-1)/x;
i2=1/(sqrt(1+x)+1);
printf('prvi=%0.16f drugi=%0.16f\n\n',i1,i2);
%
printf('tretja naloga:\n');
format long;
i=log(11/10); I1=i;
for k=1:17,
i=1/k-10*i; I1=[I1,i];
end;
i=0; I2=i;
for k=40:-1:1
i=(1-k*i)/10/k; I2=[i,I2];
end;
I2=I2(1:18);
printf('prvi=%0.16f drugi=%0.16f\n',I1(15),I2(15));
