      subroutine f(n,t,y,dy)
      integer n
      double precision t,y(n),dy(n)
      dy(1) = 0.
      dy(2) = 1.
      dy(3) = t
      dy(4) = y(4)
      end
      
      integer neq,methflag,itol,funout,istate,iopt,lrw,liw
      double precision rtol,atol
      parameter(neq=4,methflag=10,itol=1,rtol=1D-14,atol=1D-30,
     1 funout=1,iopt=0,lrw=20+16*neq,liw=20)
      integer iwork(liw)
      double precision y(4),t,tout,rwork(lrw)
      external f
      y(1) = 0.
      y(2) = 0.
      y(3) = 0.
      y(4) = 1.
      t = 0.
      tout = 1.
      istate = 1
      call lsode(f,neq,y,t,tout,itol,rtol,atol,funout,istate,iopt,
     1 rwork,lrw,iwork,liw,f,methflag)
      print*,'istate ',istate
      print*,y(1)
      print*,y(2)
      print*,y(3)
      print*,y(4)
      stop
      end


