********************************************************************************
*                                                                              *
*  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 ### norm94 ###
c
      subroutine norm94 (iorb,psi,f4,wgt2,wk0,xnorm)
      implicit integer*4 (i-n)
      implicit real*8 (a-h,o-z)
      real*8 f4
      include 'commons8.inc'
      dimension psi(*),f4(*),wgt2(*),wk0(*)

      ibeg = i1b (iorb)
      ngrid= i1si(iorb)
      do i=1,ngrid
         wk0(i)=psi(ibeg-1+i)*psi(ibeg-1+i)
      enddo

      call prod  (ngrid,f4,wk0)

      xnorm=ddot (ngrid,wgt2,1,wk0,1)
      area(iorb)=xnorm

      return
      end
