implicit real*8(a-h,o-z) F(X)=EXP(-X)-X FD(X)=-EXP(-X)-1 OPEN(5,FILE='nraphson.dat') OPEN(6,FILE='nraphson.out') READ(5,*) XR,ES,IM 1 FORMAT(2F10.0,I5) DO 180 NI=1,IM XN=XR-F(XR)/FD(XR) IF(XN.EQ.0.0)GOTO 170 EA=ABS((XN-XR)/XN)*100 IF (EA.LE.ES) GOTO 210 170 XR=XN 180 CONTINUE WRITE(6,2) 2 FORMAT(' ','NO SE ENCONTRO LA RAIZ') NI=NI-1 210 WRITE(6,3) XN,EA,NI 3 FORMAT(' ',2F12.5,I5) STOP END