28#include "../base/base_uses.f90"
36 CHARACTER(len=*),
PARAMETER,
PRIVATE :: moduleN =
'md_util'
52 SUBROUTINE md_output(md_env, md_section, root_section, forced_io)
55 LOGICAL,
INTENT(IN) :: forced_io
57 CHARACTER(LEN=*),
PARAMETER :: routinen =
'md_output'
63 CALL timeset(routinen, handle)
102 INTEGER,
INTENT(OUT) :: dof
103 REAL(kind=
dp),
DIMENSION(:),
INTENT(OUT) :: eigenvalues
104 REAL(kind=
dp),
DIMENSION(:, :),
INTENT(OUT) :: eigenvectors
106 CHARACTER(LEN=default_path_length) :: filename
107 INTEGER :: jj, n_rep_val, unit_nr
115 eigenvectors = 0.0_dp
119 IF (n_rep_val > 0)
THEN
127 IF (para_env%is_source())
THEN
128 INQUIRE (file=filename, exist=exist)
129 IF (.NOT. exist)
THEN
130 cpabort(
"File "//filename//
" is not found.")
133 file_action=
"READ", &
134 file_form=
"UNFORMATTED", &
139 IF (dof .GT.
SIZE(eigenvalues))
THEN
140 cpabort(
"Too many DoFs found in "//filename)
143 READ (unit_nr) eigenvalues(1:dof)
146 READ (unit_nr) eigenvectors(1:dof, jj)
151 CALL para_env%bcast(dof)
152 CALL para_env%bcast(eigenvalues)
153 CALL para_env%bcast(eigenvectors)
155 IF (para_env%is_source())
THEN
Utility routines to open and close files. Tracking of preconnections.
subroutine, public open_file(file_name, file_status, file_form, file_action, file_position, file_pad, unit_number, debug, skip_get_unit_number, file_access)
Opens the requested file using a free unit number.
subroutine, public close_file(unit_number, file_status, keep_preconnection)
Close an open file given by its logical unit number. Optionally, keep the file and unit preconnected.
various routines to log and control the output. The idea is that decisions about where to log should ...
type(cp_logger_type) function, pointer, public cp_get_default_logger()
returns the default logger
routines to handle the output, The idea is to remove the decision of wheter to output and what to out...
character(len=default_path_length) function, public cp_print_key_generate_filename(logger, print_key, middle_name, extension, my_local)
Utility function that returns a unit number to write the print key. Might open a file with a unique f...
Defines the basic variable types.
integer, parameter, public dp
integer, parameter, public default_path_length
prints all energy info per timestep to the screen or to user defined output files
subroutine, public md_write_output(md_env)
This routine computes the conserved quantity, temperature and things like that and prints them out.
Utilities for Molecular Dynamics.
subroutine, public md_output(md_env, md_section, root_section, forced_io)
collects the part of the MD that, basically, does the output
subroutine, public read_vib_eigs_unformatted(md_section, vib_section, para_env, dof, eigenvalues, eigenvectors)
read eigenvalues and eigenvectors of Hessian from vibrational analysis results, for use of initialisi...
Interface to the message passing library MPI.
type of a logger, at the moment it contains just a print level starting at which level it should be l...
stores all the informations relevant to an mpi environment