22 use,
intrinsic :: iso_fortran_env
54 integer,
public,
parameter :: MAX_PATH_LEN=512
55 integer,
public,
parameter :: MAX_OUTPUT_TYPES=44
59 logical :: devel_version
60 logical :: report_memory
61 character(len=256) :: share = share_dir
62 character(len=256) :: git_commit = git_commit
63 character(len=50) :: config_time = build_time
64 character(len=20) :: version = package_version
65 character(len=256) :: cc = cc
66 character(len=256) :: cxx = cxx
67 character(len=256) :: fc = fc
69 character(len=256) :: cflags = &
72 character(len=256) :: cxxflags = &
75 character(len=256) :: fcflags = &
78 integer :: target_states_block_size = -1
84 type(conf_t),
public :: conf
86 real(real64),
public,
parameter :: R_SMALL = 1e-8_real64
89 real(real64),
public,
parameter :: R_MIN_ATOM_DIST = 1e-3_real64
92 real(real64),
public,
parameter :: M_Pi = 3.1415926535897932384626433832795029_real64
93 real(real64),
public,
parameter :: M_E = 2.7182818284590452353602874713526625_real64
94 real(real64),
public,
parameter :: M_ZERO = 0.0_real64
95 real(real64),
public,
parameter :: M_ONE = 1.0_real64
96 real(real64),
public,
parameter :: M_TWO = 2.0_real64
97 real(real64),
public,
parameter :: M_THREE = 3.0_real64
98 real(real64),
public,
parameter :: M_FOUR = 4.0_real64
99 real(real64),
public,
parameter :: M_FIVE = 5.0_real64
100 real(real64),
public,
parameter :: M_HALF = 0.5_real64
101 real(real64),
public,
parameter :: M_THIRD = m_one/m_three
102 real(real64),
public,
parameter :: M_TWOTHIRD = m_two/m_three
103 real(real64),
public,
parameter :: M_FOURTH = m_one/m_four
104 complex(real64),
public,
parameter :: M_z0 = (0.0_real64, 0.0_real64)
105 complex(real64),
public,
parameter :: M_z1 = (1.0_real64, 0.0_real64)
106 complex(real64),
public,
parameter :: M_z2 = (2.0_real64, 0.0_real64)
107 complex(real64),
public,
parameter :: M_z2I = (0.0_real64, 2.0_real64)
108 complex(real64),
public,
parameter :: M_zI = (0.0_real64, 1.0_real64)
110 real(real64),
public,
parameter :: M_EPSILON = epsilon(m_one)
111 real(real64),
public,
parameter :: M_TINY = tiny(m_one)
112 real(real64),
public,
parameter :: M_HUGE = huge(m_one)
113 real(real64),
public,
parameter :: M_MIN_EXP_ARG = -650_real64
114 real(real64),
public,
parameter :: M_MAX_EXP_ARG = 700_real64
117 real(real64),
public,
parameter :: M_MIN_OCC = 1.0e-10_real64
119 real(real64),
public,
parameter :: M_MIN_DENSITY = 1.0e-20_real64
122 real(real64),
public,
parameter :: LMM_R_SINGLE_ATOM = 100.0_real64
125 real(real64),
public,
parameter :: P_a_B = 0.52917720859_real64
126 real(real64),
public,
parameter :: P_Ang = m_one / p_a_b
127 real(real64),
public,
parameter :: P_Ry = 13.60569193_real64
128 real(real64),
public,
parameter :: P_eV = m_one / p_ry
129 real(real64),
public,
parameter :: P_Kb = 8.617343e-5_real64/(m_two*p_ry)
130 real(real64),
public,
parameter :: P_c = 137.035999679_real64
132 real(real64),
public,
parameter :: P_g = 2.00231930436118_real64
133 real(real64),
public,
parameter :: P_PROTON_CHARGE = -1.0_real64
134 real(real64),
public,
parameter :: P_ep = m_one/(m_four*m_pi)
135 real(real64),
public,
parameter :: P_mu = m_four*m_pi/(p_c**2)
138 integer,
public :: stderr, stdin, stdout
141 integer,
public :: s_epoch_sec, s_epoch_usec
144 character(len=80),
public :: sub_stack(50)
145 real(real64),
public :: time_stack(50)
146 integer,
public :: no_sub_stack = 0
151 integer,
public :: global_alloc_err
156 character(len=*),
public,
parameter ::
gs_dir =
"gs/"
157 character(len=*),
public,
parameter ::
td_dir =
"td/"
158 character(len=*),
public,
parameter ::
static_dir =
"static/"
161 character(len=*),
public,
parameter ::
kdotp_dir =
"kdotp/"
163 character(len=*),
public,
parameter ::
vdw_dir =
"vdw/"
164 character(len=*),
public,
parameter ::
casida_dir =
"casida/"
165 character(len=*),
public,
parameter ::
oct_dir =
"opt-control/"
166 character(len=*),
public,
parameter ::
pcm_dir =
"pcm/"
167 character(len=*),
public,
parameter ::
partition_dir =
"partition/"
186 character(len=*),
intent(in) :: s, f
187 integer,
intent(in) :: l
191 interface operator (+)
193 end interface operator (+)
214 class(
conf_t),
intent(inout) :: this
216 character(len=256) :: share
220 if (share /=
"") this%share = trim(share)
231 type(mpi_comm),
intent(in),
optional :: communicator
233 type(mpi_comm) :: comm
235 if (
present(communicator))
then
260 type(mpi_comm),
intent(in) :: comm
295 real(real64)
pure function doptional_default(opt, def) result(val)
296 real(real64),
optional,
intent(in) :: opt
297 real(real64),
intent(in) :: def
300 if (
present(opt)) val = opt
305 complex(real64) pure function zoptional_default(opt, def) result(val)
306 complex(real64),
optional,
intent(in) :: opt
307 complex(real64),
intent(in) :: def
310 if (
present(opt)) val = opt
315 integer pure function ioptional_default(opt, def) result(val)
316 integer,
optional,
intent(in) :: opt
317 integer,
intent(in) :: def
320 if (
present(opt)) val = opt
326 integer(int64),
optional,
intent(in) :: opt
327 integer(int64),
intent(in) :: def
330 if (
present(opt)) val = opt
336 logical,
optional,
intent(in) :: opt
337 logical,
intent(in) :: def
340 if (
present(opt)) val = opt
346 character(len=*),
optional,
intent(in) :: opt
347 character(len=*),
intent(in) :: def
350 if (
present(opt)) val = opt
371 function cat(str1, str2)
372 character(len=*),
intent(in) :: str1
373 character(len=*),
intent(in) :: str2
375 character(len=len(str1) + len(str2)) ::
cat
382 integer(int64) pure function
bitand48(val1, val2)
383 integer(int32),
intent(in) :: val1
384 integer(int64),
intent(in) :: val2
386 bitand48 = iand(int(val1, int64), val2)
392 integer(int64) pure function
bitand84(val1, val2)
393 integer(int64),
intent(in) :: val1
394 integer(int32),
intent(in) :: val2
396 bitand84 = iand(val1, int(val2, int64))
402 integer(int64) pure function
bitand88(val1, val2)
403 integer(int64),
intent(in) :: val1
404 integer(int64),
intent(in) :: val2
412 integer(int32) pure function
bitand44(val1, val2)
413 integer(int32),
intent(in) :: val1
414 integer(int32),
intent(in) :: val2
423 integer(int32),
intent(in) :: ii
431 integer(int64),
intent(in) :: ii
439 integer(int32),
intent(in) :: ii(:)
440 integer(int64) ::
i4_to_i8_1(lbound(ii, 1, kind=int64):ubound(ii, 1, kind=int64))
448 integer(int64),
intent(in) :: ii(:)
449 integer(int32) ::
i8_to_i4_1(lbound(ii, 1, kind=int64):ubound(ii, 1, kind=int64))
This function is defined in messages.F90.
character(len= *), parameter, public em_resp_fd_dir
integer(int32) pure function bitand44(val1, val2)
subroutine, public global_end()
Finalise parser varinfo file, and MPI.
pure integer(int32) function, dimension(lbound(ii, 1, kind=int64):ubound(ii, 1, kind=int64)) i8_to_i4_1(ii)
character(len= *), parameter, public gs_dir
integer(int64) pure function bitand88(val1, val2)
integer(int64) pure function i4_to_i8_0(ii)
integer pure function ioptional_default(opt, def)
character(len= *), parameter, public casida_dir
integer(int64), public global_sizeof
character(len= *), parameter, public pcm_dir
integer(int64) pure function bitand84(val1, val2)
character(len= *), parameter, public vib_modes_dir
character(len= *), parameter, public partition_dir
integer(int64) pure function loptional_default(opt, def)
character(len= *), parameter, public kdotp_dir
character(len=len(str1)+len(str2)) function cat(str1, str2)
type(mpi_comm), parameter, public serial_dummy_comm
Alias MPI_COMM_UNDEFINED for the specific use case of initialising Octopus utilities with no MPI supp...
subroutine, public init_octopus_globals(comm)
Initialise Octopus-specific global constants and files. This routine performs no initialisation calls...
logical pure function, public not_in_openmp()
real(real64) pure function doptional_default(opt, def)
logical pure function looptional_default(opt, def)
integer(int32) pure function i8_to_i4_0(ii)
character(len= *), parameter, public em_resp_dir
character(len=100), public global_alloc_errmsg
logical, public in_profiling_mode
Same for profiling mode.
character(len=80) pure function soptional_default(opt, def)
character(len= *), parameter, public td_dir
pure integer(int64) function, dimension(lbound(ii, 1, kind=int64):ubound(ii, 1, kind=int64)) i4_to_i8_1(ii)
character(len= *), parameter, public static_dir
subroutine, public global_init(communicator)
Initialise Octopus.
complex(real64) pure function zoptional_default(opt, def)
subroutine conf_init(this)
Initialiser for conf_t.
character(len= *), parameter, public vdw_dir
character(len= *), parameter, public oct_dir
integer(int64) pure function bitand48(val1, val2)
type(hardware_t), public cpu_hardware
Global instance of CPU hardware specification.
type(cache_t), public default_l2
type(cache_t), public default_l1
Defaults covers common chip specification for (l1, l2) cache.
subroutine blacs_init()
Initialize BLACS to enable use of SCALAPACK.
type(mpi_comm), parameter, public mpi_comm_undefined
used to indicate a communicator has not been initialized
type(mpi_grp_t), public mpi_world
subroutine mpi_mod_end()
Finalize MPI, and optionally BLACS.
subroutine mpi_grp_init(grp, comm)
Initialize MPI group instance.
subroutine mpi_init_comm(comm)
Wrapper for MPI_COMM_WORLD initialisation.
Build configuration type.