LCOV - code coverage report
Current view: top level - global - od_cylbes.f (source / functions) Hit Total Coverage
Test: combined.info Lines: 0 25 0.0 %
Date: 2019-09-08 04:53:50 Functions: 0 1 0.0 %

          Line data    Source code
       1             : !--------------------------------------------------------------------------------
       2             : ! Copyright (c) 2016 Peter Grünberg Institut, Forschungszentrum Jülich, Germany
       3             : ! This file is part of FLEUR and available as free software under the conditions
       4             : ! of the MIT license as expressed in the LICENSE file in more detail.
       5             : !--------------------------------------------------------------------------------
       6             : 
       7             :       MODULE m_od_cylbes
       8             :       use m_juDFT
       9             :       CONTAINS
      10           0 :       SUBROUTINE od_cylbes(
      11             :      >     m1,x,
      12             :      <     fJ) 
      13             : 
      14             :       IMPLICIT NONE
      15             : !     ..
      16             : !     ..Arguments ..
      17             :       INTEGER, INTENT  (IN) :: m1
      18             :       REAL,    INTENT  (IN) :: x
      19             :       REAL,    INTENT (OUT) :: fJ
      20             : !
      21             : !     .. Parameters ..
      22             :       REAL,    PARAMETER :: zero = 0.0
      23             : !     ..Locals ..
      24             :       INTEGER :: m,i,mass
      25             :       REAL :: quot
      26           0 :       REAL, ALLOCATABLE :: aux(:)
      27             : !     ..
      28             : 
      29           0 :       IF (x.LT.zero)  CALL juDFT_error("cylbes2",calledby="od_cylbes")
      30             : 
      31           0 :       IF (x.EQ.zero .AND. m1.EQ.0) THEN
      32           0 :          fJ = 1.
      33           0 :          RETURN
      34             :       END IF
      35           0 :       IF (x.EQ.zero .AND. m1.NE.0) THEN
      36           0 :          fJ = 0.
      37           0 :          RETURN
      38             :       END IF
      39             : 
      40           0 :       if (m1.lt.0) then
      41           0 :          m = -m1
      42             :       else
      43             :          m = m1
      44             :       end if
      45             :         
      46           0 :       mass = INT( m + 50 + x )
      47           0 :       ALLOCATE ( aux(0:mass) )       
      48           0 :       aux(mass) = 0.0
      49           0 :       aux(mass-1) = 1.0e-22   
      50             :      
      51           0 :       DO i=mass-2,0,-1
      52           0 :         aux(i) = 2*(i+1)*aux(i+1)/x - aux(i+2)
      53             :       END DO
      54             : 
      55           0 :       quot = aux(0)
      56             : 
      57           0 :       DO i=1,INT( mass/2. )
      58           0 :         quot = quot + 2*aux(2*i)
      59             :       END DO  
      60             : 
      61           0 :       IF (m1.LT.0) THEN
      62           0 :          fJ = ((-1)**m)*aux(m)/quot
      63             :       ELSE
      64           0 :          fJ = aux(m)/quot
      65             :       END IF
      66             :      
      67           0 :       DEALLOCATE ( aux )
      68             :       
      69           0 :       RETURN
      70             :       END SUBROUTINE od_cylbes
      71             :       END MODULE m_od_cylbes
      72             :     
      73             :  

Generated by: LCOV version 1.13