next up previous contents
Next: I/O Files Up: BP_MAT Previous: Introduction   Contents

bp_mat Program Structure

Figure 8.27: bp_mat program structure.
\begin{figure}\begin{center}
\centerline{\psfig{figure=tex/fig/bp_mat_main.epsi}}\end{center}\end{figure}

brevalf() reads the files generated from bp_ang and uses the information to allocate memory and to initialize the parameters which have been already determined by bp_ang and saved in cint.lst. readw() reads the radial data readw(). Next, genintbr() generates the list of possible integrals, ( ${\tt F_k, G_k, R_k, L, Z, N_k, V_k, S_k}$).

Figure 8.28: Subroutine brevalf().
\begin{figure}\begin{center}
\centerline{\psfig{figure=tex/fig/bp_mat_brevalr.epsi}}\end{center}\end{figure}

The contributions to the Hamiltonian are computed in genslt(). The next code segment shows data processing by columns, the contribution are saved in a set of three files hnr.lst, hzeta.lst, hspin.lst. This program currently does not include the orbit-orbit contribution. When IORBORB=1, which is a signal to bp_mat to include orbit-orbit, then inptr > intptr(0,4) and lcase = 1, while the correct handling should provide for this case lcase = 2. In most calculations this interaction shows very little effect on the accuracy, while the computational time may double  . On the other hand bpci correctly includes the orbit-orbit interaction and can be used for this purpose.

 JB = 1,ncfg
         if(mod(jb,100).eq.0) write(0,'(A,I5)') '   jb = ',jb
         if(jb == ncfg) write(0,'(A,I5)') '   jb = ',jb
*        initialize arrays for a column
         nrow(1:3) = 0
         jan(1:ncfg,1:3) = 0
         h(1:ncfg,1:3) = 0.d0
         ico(1:ncfg) = 0
         iflag(1:3)=0
         lij =  1
*       read info on matrix elements for the column
         read (51) nih, (janc(i),i=1,nih)
         read (52) nih, (ico(i),i=1,nih)
         Do
           n = n+1;
           if (n .gt. new) then
*           .. more data is needed
             read (50) new,(cn(j),j=1,new),(inptr(j),j=1,new)
             n = 1
           end if
*         .. determine case
           if (inptr(n) < 0) then
             lcase = 3
           else if (inptr(n) == 0) then
             print*,'inptr(',n,') can''t be 0'; lcase = 2
           else if (inptr(n).le.intptr(1,4))  then
             lcase = 1
           else
             lcase = 2
           end if
*         .. determine matrix element
           if ((nij > ico(lij))) then
*           .. we have new matrix element; set iflags to zero
             lij = lij + 1
             iflag(1:3) = 0
           end if
           if (iflag(lcase) .eq. 0) then
             nrow(lcase) = nrow(lcase) + 1
             jan(nrow(lcase),lcase) = janc(lij)
             iflag(lcase) = 1
           end if
*         .. add contribution to right matrix element
           v = value(abs(inptr(n)))
           h(nrow(lcase),lcase) = h(nrow(lcase),lcase) + cn(n)*v
           hh = h(nrow(lcase),lcase)
           nij = nij + 1
           if (nij .eq. jptr(jb_count) + 1) exit
*          if (lij .eq. nih) exit
         END DO
         write(iouhn) jb,nrow(1),(h(i,1),i=1,nrow(1)),
     :                (jan(i,1),i=1,nrow(1))
         write(iouhz) jb,nrow(2),(h(i,2),i=1,nrow(2)),
     :                (jan(i,2),i=1,nrow(2))
         write(iouhs) jb,nrow(3),(h(i,3),i=1,nrow(3)),
     :                (jan(i,3),i=1,nrow(3))
       END DO


next up previous contents
Next: I/O Files Up: BP_MAT Previous: Introduction   Contents
2001-10-11