(git:21ef868)
Loading...
Searching...
No Matches
rt_bse_io Module Reference

Input/output from the propagation via RT-BSE method. More...

Functions/Subroutines

subroutine, public print_rtbse_header_info (rtbse_env)
 Writes the header and basic info to the standard output.
 
subroutine, public print_etrs_info (rtbse_env, step, metric)
 Writes the update after single etrs iteration - only for log level > medium.
 
subroutine, public print_etrs_info_header (rtbse_env)
 Writes the header for the etrs iteration updates - only for log level > medium.
 
subroutine, public print_timestep_info (rtbse_env, step, electron_num_re, convergence, etrs_num, step_walltime)
 Writes the summary line of a completed propagation timestep.
 
subroutine, public output_mos_contravariant (rtbse_env, rho, print_key_section)
 Outputs the matrix in MO basis for matrix coefficients corresponding to contravariant operator, i.e. density matrix.
 
subroutine, public output_mos_covariant (rtbse_env, ham, print_key_section)
 Outputs the matrix in MO basis for matrix components corresponding to covariant representation, i.e. the Hamiltonian matrix.
 
subroutine, public output_field (rtbse_env, append_opt)
 Prints the current field components into a file provided by input.
 
subroutine, public read_field (rtbse_env)
 Reads the field from the files provided by input - useful for the continuation run.
 
subroutine, public output_moments (rtbse_env, rho)
 Outputs the expectation value of moments from a given density matrix.
 
subroutine, public output_restart (rtbse_env, rho, time_index)
 Outputs the restart info (last finished iteration step) + restard density matrix.
 
subroutine, public read_restart (rtbse_env)
 Reads the density matrix from restart files and updates the starting time.
 
subroutine, public output_restart_linearized (rtbse_env, rho)
 Linearized RT-BSE restart writer. Writes the restart set: lab-frame MO-active density matrices, the .info step index (sim_step = steps completed = the resume step), the once-per-run C_active gauge reference, and the appended RESTART.trace record feeding the FT prefix on continuation. All indices derive from sim_step so the .info/.trace bookkeeping cannot drift apart. (Full RTBSE uses the upstream output_restart above.)
 
subroutine, public read_restart_info (rtbse_env)
 Early phase of the restart read: the starting step index from the .info file, the original run's dt peeked from the RESTART.trace header (so ENFORCE_MAX_DT can inherit it), and an SCF_GUESS hygiene check. Runs BEFORE initialize_maximum_timestep; the trace prefix records are loaded separately by read_restart_trace once the trace arrays are sized.
 
subroutine, public read_restart_trace (rtbse_env)
 Reads the RESTART.trace prefix (records 1..sim_start) into the in-memory moment/field/ time traces so the continuation FT covers the full history. Header guards: version, n_spin, dims, dt (abort); kick params (warn); eps_active > 0.1 meV (warn). All ranks read (the traces are replicated). Record layout matches write_restart_trace verbatim.
 
subroutine, public check_restart_eps_consistency (rtbse_env)
 Compares the original run's active eigenvalues (stashed by read_restart_trace) against the recomputed eps_active, once the Hamiltonian is built. Prints the max deviation and warns above 0.1 meV (GW analytic continuation gives run-to-run QP noise above FP, so the threshold is deliberately loose). Frees the stash. No-op if nothing was stashed.
 
subroutine, public read_restart_density (rtbse_env)
 Late phase of the restart read: overwrites rho from the lab-frame restart matrices and sets restart_extracted. MO-active for the linearized path, AO otherwise (cp_fm_read_unformatted aborts on a size mismatch, guarding a changed active window).
 
subroutine, public read_restart_c (rtbse_env, c_old, found)
 Reads the previous run's C_active slabs (gauge reference for the restart basis bridge).
 

Detailed Description

Input/output from the propagation via RT-BSE method.

Author
Stepan Marek (08.24)

Function/Subroutine Documentation

◆ print_rtbse_header_info()

subroutine, public rt_bse_io::print_rtbse_header_info ( type(rtbse_env_type rtbse_env)

Writes the header and basic info to the standard output.

Parameters
rtbse_envEntry point - rtbse environment

Definition at line 90 of file rt_bse_io.F.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ print_etrs_info()

subroutine, public rt_bse_io::print_etrs_info ( type(rtbse_env_type rtbse_env,
integer  step,
real(kind=dp)  metric 
)

Writes the update after single etrs iteration - only for log level > medium.

Parameters
rtbse_envEntry point - rtbse environment

Definition at line 139 of file rt_bse_io.F.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ print_etrs_info_header()

subroutine, public rt_bse_io::print_etrs_info_header ( type(rtbse_env_type rtbse_env)

Writes the header for the etrs iteration updates - only for log level > medium.

Parameters
rtbse_envEntry point - rtbse environment

Definition at line 156 of file rt_bse_io.F.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ print_timestep_info()

subroutine, public rt_bse_io::print_timestep_info ( type(rtbse_env_type rtbse_env,
integer  step,
real(kind=dp), dimension(:), intent(in)  electron_num_re,
real(kind=dp), optional  convergence,
integer, optional  etrs_num,
real(kind=dp), optional  step_walltime 
)

Writes the summary line of a completed propagation timestep.

Parameters
rtbse_envEntry point - rtbse environment
stepIndex of the completed timestep
electron_num_reReal part of the electron number, one entry per spin channel
convergenceOptional convergence metric reached by the ETRS iteration
etrs_numOptional number of ETRS iterations used in this timestep
step_walltimeOptional wall time of this timestep, in seconds

Definition at line 176 of file rt_bse_io.F.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ output_mos_contravariant()

subroutine, public rt_bse_io::output_mos_contravariant ( type(rtbse_env_type rtbse_env,
type(cp_cfm_type), dimension(:), pointer  rho,
type(section_vals_type), pointer  print_key_section 
)

Outputs the matrix in MO basis for matrix coefficients corresponding to contravariant operator, i.e. density matrix.

Parameters
rtbse_envEntry point - gwbse environment
rhoDensity matrix in AO basis
rtp_sectionRTP input section

Definition at line 260 of file rt_bse_io.F.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ output_mos_covariant()

subroutine, public rt_bse_io::output_mos_covariant ( type(rtbse_env_type rtbse_env,
type(cp_cfm_type), dimension(:), pointer  ham,
type(section_vals_type), pointer  print_key_section 
)

Outputs the matrix in MO basis for matrix components corresponding to covariant representation, i.e. the Hamiltonian matrix.

Parameters
rtbse_envEntry point - gwbse environment
cohsexcohsex matrix in AO basis, covariant representation
rtp_sectionRTP input section

Definition at line 326 of file rt_bse_io.F.

Here is the call graph for this function:

◆ output_field()

subroutine, public rt_bse_io::output_field ( type(rtbse_env_type rtbse_env,
logical, optional  append_opt 
)

Prints the current field components into a file provided by input.

Parameters
rtbse_envEntry point - gwbse environment
rtp_sectionRTP input section

Definition at line 364 of file rt_bse_io.F.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ read_field()

subroutine, public rt_bse_io::read_field ( type(rtbse_env_type rtbse_env)

Reads the field from the files provided by input - useful for the continuation run.

Parameters
rtbse_envEntry point - gwbse environment
rtp_sectionRTP input section

Definition at line 409 of file rt_bse_io.F.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ output_moments()

subroutine, public rt_bse_io::output_moments ( type(rtbse_env_type rtbse_env,
type(cp_cfm_type), dimension(:), pointer  rho 
)

Outputs the expectation value of moments from a given density matrix.

Note
Moments matrix is provided by the rtbse_env, uses rho_workspace(1:3)
Parameters
rtbse_envEntry point - gwbse environment
rhoDensity matrix in AO basis
rtp_sectionRTP section of the input parameters, where moments destination may be present

Definition at line 447 of file rt_bse_io.F.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ output_restart()

subroutine, public rt_bse_io::output_restart ( type(rtbse_env_type), pointer  rtbse_env,
type(cp_cfm_type), dimension(:), pointer  rho,
integer  time_index 
)

Outputs the restart info (last finished iteration step) + restard density matrix.

Parameters
restart_sectionPrint key section for the restart files
rhoDensity matrix in AO basis
time_indexTime index to be written into the info file

Definition at line 494 of file rt_bse_io.F.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ read_restart()

subroutine, public rt_bse_io::read_restart ( type(rtbse_env_type), pointer  rtbse_env)

Reads the density matrix from restart files and updates the starting time.

Parameters
restart_sectionPrint key section for the restart files
rhoDensity matrix in AO basis
time_indexTime index to be written into the info file

Definition at line 538 of file rt_bse_io.F.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ output_restart_linearized()

subroutine, public rt_bse_io::output_restart_linearized ( type(rtbse_env_type), pointer  rtbse_env,
type(cp_cfm_type), dimension(:), pointer  rho 
)

Linearized RT-BSE restart writer. Writes the restart set: lab-frame MO-active density matrices, the .info step index (sim_step = steps completed = the resume step), the once-per-run C_active gauge reference, and the appended RESTART.trace record feeding the FT prefix on continuation. All indices derive from sim_step so the .info/.trace bookkeeping cannot drift apart. (Full RTBSE uses the upstream output_restart above.)

Parameters
rtbse_envRT-BSE environment
rhoDensity matrix (lab frame) to store

Definition at line 598 of file rt_bse_io.F.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ read_restart_info()

subroutine, public rt_bse_io::read_restart_info ( type(rtbse_env_type), pointer  rtbse_env)

Early phase of the restart read: the starting step index from the .info file, the original run's dt peeked from the RESTART.trace header (so ENFORCE_MAX_DT can inherit it), and an SCF_GUESS hygiene check. Runs BEFORE initialize_maximum_timestep; the trace prefix records are loaded separately by read_restart_trace once the trace arrays are sized.

Parameters
rtbse_envRT-BSE environment

Definition at line 718 of file rt_bse_io.F.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ read_restart_trace()

subroutine, public rt_bse_io::read_restart_trace ( type(rtbse_env_type), pointer  rtbse_env)

Reads the RESTART.trace prefix (records 1..sim_start) into the in-memory moment/field/ time traces so the continuation FT covers the full history. Header guards: version, n_spin, dims, dt (abort); kick params (warn); eps_active > 0.1 meV (warn). All ranks read (the traces are replicated). Record layout matches write_restart_trace verbatim.

Parameters
rtbse_envRT-BSE environment

Definition at line 768 of file rt_bse_io.F.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ check_restart_eps_consistency()

subroutine, public rt_bse_io::check_restart_eps_consistency ( type(rtbse_env_type), pointer  rtbse_env)

Compares the original run's active eigenvalues (stashed by read_restart_trace) against the recomputed eps_active, once the Hamiltonian is built. Prints the max deviation and warns above 0.1 meV (GW analytic continuation gives run-to-run QP noise above FP, so the threshold is deliberately loose). Frees the stash. No-op if nothing was stashed.

Parameters
rtbse_envRT-BSE environment

Definition at line 873 of file rt_bse_io.F.

Here is the caller graph for this function:

◆ read_restart_density()

subroutine, public rt_bse_io::read_restart_density ( type(rtbse_env_type), pointer  rtbse_env)

Late phase of the restart read: overwrites rho from the lab-frame restart matrices and sets restart_extracted. MO-active for the linearized path, AO otherwise (cp_fm_read_unformatted aborts on a size mismatch, guarding a changed active window).

Parameters
rtbse_envRT-BSE environment

Definition at line 898 of file rt_bse_io.F.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ read_restart_c()

subroutine, public rt_bse_io::read_restart_c ( type(rtbse_env_type), pointer  rtbse_env,
type(cp_fm_type), dimension(:), pointer  c_old,
logical, intent(out)  found 
)

Reads the previous run's C_active slabs (gauge reference for the restart basis bridge).

Parameters
rtbse_envRT-BSE environment
C_oldCaller-created fm array (n_spin) on fm_struct_ao_mo_active, filled on success
found.TRUE. iff all per-spin C files were present and read

Definition at line 950 of file rt_bse_io.F.

Here is the call graph for this function:
Here is the caller graph for this function: