odrpack_kinds.F90 Source File


Files dependent on this one

sourcefile~~odrpack_kinds.f90~~AfferentGraph sourcefile~odrpack_kinds.f90 odrpack_kinds.F90 sourcefile~blas_interfaces.f90 blas_interfaces.f90 sourcefile~blas_interfaces.f90->sourcefile~odrpack_kinds.f90 sourcefile~example1.f90 example1.f90 sourcefile~example1.f90->sourcefile~odrpack_kinds.f90 sourcefile~odrpack.f90 odrpack.f90 sourcefile~example1.f90->sourcefile~odrpack.f90 sourcefile~example2.f90 example2.f90 sourcefile~example2.f90->sourcefile~odrpack_kinds.f90 sourcefile~example2.f90->sourcefile~odrpack.f90 sourcefile~example3.f90 example3.f90 sourcefile~example3.f90->sourcefile~odrpack_kinds.f90 sourcefile~example3.f90->sourcefile~odrpack.f90 sourcefile~example4.f90 example4.f90 sourcefile~example4.f90->sourcefile~odrpack_kinds.f90 sourcefile~example4.f90->sourcefile~odrpack.f90 sourcefile~example5.f90 example5.f90 sourcefile~example5.f90->sourcefile~odrpack_kinds.f90 sourcefile~example5.f90->sourcefile~odrpack.f90 sourcefile~odrpack.f90->sourcefile~odrpack_kinds.f90 sourcefile~odrpack.f90->sourcefile~blas_interfaces.f90 sourcefile~odrpack_core.f90 odrpack_core.f90 sourcefile~odrpack.f90->sourcefile~odrpack_core.f90 sourcefile~odrpack_reports.f90 odrpack_reports.f90 sourcefile~odrpack.f90->sourcefile~odrpack_reports.f90 sourcefile~odrpack_core.f90->sourcefile~odrpack_kinds.f90 sourcefile~odrpack_core.f90->sourcefile~blas_interfaces.f90 sourcefile~odrpack_reports.f90->sourcefile~odrpack_kinds.f90 sourcefile~odrpack_reports.f90->sourcefile~odrpack_core.f90 sourcefile~odrpack_capi.f90 odrpack_capi.f90 sourcefile~odrpack_capi.f90->sourcefile~odrpack.f90 sourcefile~odrpack_capi.f90->sourcefile~odrpack_core.f90

Source Code

module odrpack_kinds
!! Real kinds and common numeric constants.
    use, intrinsic :: iso_fortran_env, only: real32, real64
    implicit none
    private

    public :: sp, dp, wp
    public :: negone, zero, half, one, two, three, eight, ten, fiftn, hundred
    public :: pi
    
    integer, parameter :: sp = real32
    integer, parameter :: dp = real64

#ifdef REAL32
    integer, parameter :: wp = sp
#elif REAL64
    integer, parameter :: wp = dp
#else
    integer, parameter :: wp = dp
#endif

    real(wp), parameter :: negone = -1.0_wp
    real(wp), parameter :: zero = 0.0_wp
    real(wp), parameter :: half = 0.5_wp
    real(wp), parameter :: one = 1.0_wp
    real(wp), parameter :: two = 2.0_wp
    real(wp), parameter :: three = 3.0_wp
    real(wp), parameter :: eight = 8.0_wp
    real(wp), parameter :: ten = 10.0_wp
    real(wp), parameter :: fiftn = 15.0_wp
    real(wp), parameter :: hundred = 100.0_wp
    real(wp), parameter :: pi = 4*atan(one)

end module odrpack_kinds