diff --git a/src/Lambert.f90 b/src/Lambert.f90 index 601cf9984..a528ea8b0 100644 --- a/src/Lambert.f90 +++ b/src/Lambert.f90 @@ -38,6 +38,7 @@ !> Modeling and Simulations in Materials Science and Engineering 22, 075013 (2014). !-------------------------------------------------------------------------- module Lambert + use prec use math implicit none diff --git a/src/math.f90 b/src/math.f90 index f2c0303da..4a32be274 100644 --- a/src/math.f90 +++ b/src/math.f90 @@ -10,12 +10,20 @@ module math use future implicit none - real(pReal), parameter, public :: PI = acos(-1.0_pReal) !< ratio of a circle's circumference to its diameter - real(pReal), parameter, public :: INDEG = 180.0_pReal/PI !< conversion from radian into degree - real(pReal), parameter, public :: INRAD = PI/180.0_pReal !< conversion from degree into radian - complex(pReal), parameter, public :: TWOPIIMG = cmplx(0.0_pReal,2.0_pReal*PI) !< Re(0.0), Im(2xPi) + public +#if __INTEL_COMPILER >= 1900 + ! do not make use associated entities available to other modules + private :: & + prec, & + future +#endif - real(pReal), dimension(3,3), parameter, public :: & + real(pReal), parameter :: PI = acos(-1.0_pReal) !< ratio of a circle's circumference to its diameter + real(pReal), parameter :: INDEG = 180.0_pReal/PI !< conversion from radian into degree + real(pReal), parameter :: INRAD = PI/180.0_pReal !< conversion from degree into radian + complex(pReal), parameter :: TWOPIIMG = cmplx(0.0_pReal,2.0_pReal*PI) !< Re(0.0), Im(2xPi) + + real(pReal), dimension(3,3), parameter :: & MATH_I3 = reshape([& 1.0_pReal,0.0_pReal,0.0_pReal, & 0.0_pReal,1.0_pReal,0.0_pReal, & @@ -75,7 +83,7 @@ module math !--------------------------------------------------------------------------------------------------- private :: & - math_check + unitTest contains @@ -116,14 +124,15 @@ subroutine math_init write(6,'(a,4(/,26x,f17.14),/)') ' start of random sequence: ', randTest call random_seed(put = randInit) - call math_check + call unitTest end subroutine math_init + !-------------------------------------------------------------------------------------------------- !> @brief check correctness of (some) math functions !-------------------------------------------------------------------------------------------------- -subroutine math_check +subroutine unitTest use IO, only: IO_error character(len=64) :: error_msg @@ -145,7 +154,7 @@ subroutine math_check call IO_error(401,ext_msg=error_msg) endif -end subroutine math_check +end subroutine unitTest !--------------------------------------------------------------------------------------------------