********************************************************************************
*                                                                              * 
*  2DHF version 1-2003                                                         *
*  Copyright (C) 1996  Jacek Kobus, Leif Laaksonen, Dage Sundholm              *
*                                                                              *
*  This software may be used and distributed according to the terms            *
*  of the GNU General Public License, see README and COPYING.                  *
*                                                                              *
********************************************************************************
c ### rfdisk ### 
c
c     Controls retrieving orbitals and potentials from a disk file
c
      subroutine rfdisk (cw_orb,cw_coul,cw_exch,cw_sctch)
      implicit integer*4 (i-n)
      implicit real*8 (a-h,o-z)
      include 'commons8.inc'
      dimension cw_orb(*),cw_coul(*),cw_exch(*),cw_sctch(*)

      call rheader(norb_p)
      if (iinterp.eq.0) then	
         call rfun (norb_p,cw_orb,cw_coul,cw_exch)	
      else
	 call grid_old
	 call rfun_int (norb_p,cw_orb,cw_coul,cw_exch,cw_sctch)	
      endif
      
      return
      end

