Octopus
|
This module implements the abstract system type. More...
This module implements the abstract system type.
Data Types | |
type | barrier_t |
interface | system_do_algorithmic_operation |
Execute one operation that is part of a larger algorithm. Returns true if the operation was successfully executed, false otherwise. More... | |
interface | system_init_interaction |
initialize a given interaction of the system More... | |
interface | system_initial_conditions |
set initial conditions for a system More... | |
interface | system_is_tolerance_reached |
check whether a system has reached a given tolerance More... | |
type | system_iterator_t |
type | system_list_t |
These classes extends the list and list iterator to create a system list. More... | |
interface | system_restart_read_data |
interface | system_restart_write_data |
interface | system_store_current_status |
For some algorithms it might be necessary to store the status of a system at a given algorithmic step. More... | |
type | system_t |
Abstract class for systems. More... | |
interface | system_update_kinetic_energy |
Functions/Subroutines | |
subroutine, public | system_execute_algorithm (this) |
perform one or more algorithmic operations More... | |
subroutine, public | system_reset_iteration_counters (this, accumulated_iterations) |
recursive subroutine, public | system_create_interactions (this, interaction_factory, available_partners) |
create the interactions of the system More... | |
logical function | system_update_couplings (this) |
Update the couplings (quantities) of the interaction partners. More... | |
subroutine | system_update_interactions (this) |
Attempt to update all interactions of the system. More... | |
subroutine | system_update_interactions_start (this) |
subroutine | system_update_interactions_finish (this) |
subroutine, public | system_restart_write (this) |
logical function, public | system_restart_read (this) |
subroutine | system_output_start (this) |
subroutine | system_output_write (this) |
subroutine | system_output_finish (this) |
subroutine, public | system_init_algorithm (this, factory) |
recursive logical function | system_algorithm_finished (this) |
subroutine, public | system_init_iteration_counters (this) |
Initialize the iteration counters of the system and its interactions, algorithms and quantities. More... | |
subroutine, public | system_propagation_start (this) |
subroutine, public | system_propagation_finish (this) |
subroutine | system_iteration_info (this) |
logical function | system_process_is_slave (this) |
subroutine, public | system_end (this) |
subroutine | system_list_add_node (this, partner) |
recursive logical function | system_list_contains (this, partner) |
class(system_t) function, pointer | system_iterator_get_next (this) |
subroutine, public | system_init_parallelization (this, grp) |
Basic functionality: copy the MPI group. This function needs to be implemented by extended types that need more initialization for their parallelization. More... | |
subroutine | system_start_barrier (this, target_time, barrier_index) |
subroutine | system_end_barrier (this, barrier_index) |
logical function | system_arrived_at_barrier (this, barrier_index) |
logical function | system_arrived_at_any_barrier (this) |
subroutine, public | system_update_potential_energy (this) |
Calculate the potential energy of the system. The potential energy is defined as the sum of all energies arising from interactions with external systems. (Note that multisystems override this function) More... | |
subroutine | system_update_internal_energy (this) |
Calculate the internal energy of the system. The internal energy is defined as the sum of all energies arising from intra-interactions and the entropy terms (if available). (Note that multisystems override this function) More... | |
subroutine, public | system_update_total_energy (this) |
Calculate the total energy of the system. The total energy is defined as the sum of the kinetic, the internal and the potential energies. More... | |
Variables | |
integer, parameter, public | number_barriers = 1 |
integer, parameter, public | barrier_restart = 1 |
subroutine, public system_oct_m::system_execute_algorithm | ( | class(system_t), intent(inout) | this | ) |
perform one or more algorithmic operations
The following subroutine takes a system and performs as many algorithmic operations as possible on the system until a barrier is reached. There are two types of barriers:
The couplings update is always considered a barrier, even if the update was successful. This is to allow other system to also update their couplings with this system before it moves on to the next operations.
Definition at line 330 of file system.F90.
subroutine, public system_oct_m::system_reset_iteration_counters | ( | class(system_t), intent(inout) | this, |
integer, intent(in) | accumulated_iterations | ||
) |
Definition at line 448 of file system.F90.
recursive subroutine, public system_oct_m::system_create_interactions | ( | class(system_t), intent(inout) | this, |
class(interactions_factory_abst_t), intent(in) | interaction_factory, | ||
class(partner_list_t), intent(in), target | available_partners | ||
) |
create the interactions of the system
Given a list of available partners, this routine creates all the supported interactions between the system and the partners. To do so, it uses an interaction factory. It also initializes all the interactions (calling system_t::init_interaction() and interaction_partner_t::init_interaction_as_partner())
[in,out] | this | system for which interactions are created. |
[in] | interaction_factory | factory that creates the actual interactions |
[in] | available_partners | a list of available partners for the given system. |
Definition at line 501 of file system.F90.
|
private |
Update the couplings (quantities) of the interaction partners.
This function loops over all interactions and the corresponding interaction partners and attempts to update their couplings to the requested iteration. It returns true if all couplings have been successfully updated.
Definition at line 652 of file system.F90.
|
private |
Attempt to update all interactions of the system.
First we try to update the systems own quantities required for the interaction, and then try to update the interaction itself.
Definition at line 689 of file system.F90.
|
private |
Definition at line 762 of file system.F90.
|
private |
Definition at line 774 of file system.F90.
subroutine, public system_oct_m::system_restart_write | ( | class(system_t), intent(inout) | this | ) |
Definition at line 786 of file system.F90.
logical function, public system_oct_m::system_restart_read | ( | class(system_t), intent(inout) | this | ) |
Definition at line 825 of file system.F90.
|
private |
Definition at line 869 of file system.F90.
|
private |
Definition at line 881 of file system.F90.
|
private |
Definition at line 893 of file system.F90.
subroutine, public system_oct_m::system_init_algorithm | ( | class(system_t), intent(inout) | this, |
class(algorithm_factory_t), intent(in) | factory | ||
) |
Definition at line 905 of file system.F90.
|
private |
Definition at line 928 of file system.F90.
subroutine, public system_oct_m::system_init_iteration_counters | ( | class(system_t), intent(inout) | this | ) |
Initialize the iteration counters of the system and its interactions, algorithms and quantities.
Note that th iteration counters for interactions, and on-demand quantities are initialized to one iteration before the algorithm iteration counter. This is necessary, as the interactions and on-demand quantities first need to be updated.
Definition at line 943 of file system.F90.
subroutine, public system_oct_m::system_propagation_start | ( | class(system_t), intent(inout) | this | ) |
Definition at line 976 of file system.F90.
subroutine, public system_oct_m::system_propagation_finish | ( | class(system_t), intent(inout) | this | ) |
Definition at line 1030 of file system.F90.
|
private |
Definition at line 1063 of file system.F90.
|
private |
Definition at line 1092 of file system.F90.
subroutine, public system_oct_m::system_end | ( | class(system_t), intent(inout) | this | ) |
Definition at line 1104 of file system.F90.
|
private |
Definition at line 1129 of file system.F90.
|
private |
Definition at line 1146 of file system.F90.
|
private |
Definition at line 1174 of file system.F90.
subroutine, public system_oct_m::system_init_parallelization | ( | class(system_t), intent(inout) | this, |
type(mpi_grp_t), intent(in) | grp | ||
) |
Basic functionality: copy the MPI group. This function needs to be implemented by extended types that need more initialization for their parallelization.
Definition at line 1194 of file system.F90.
|
private |
Definition at line 1209 of file system.F90.
|
private |
Definition at line 1223 of file system.F90.
|
private |
Definition at line 1236 of file system.F90.
|
private |
Definition at line 1256 of file system.F90.
subroutine, public system_oct_m::system_update_potential_energy | ( | class(system_t), intent(inout) | this | ) |
Calculate the potential energy of the system. The potential energy is defined as the sum of all energies arising from interactions with external systems. (Note that multisystems override this function)
Definition at line 1278 of file system.F90.
|
private |
Calculate the internal energy of the system. The internal energy is defined as the sum of all energies arising from intra-interactions and the entropy terms (if available). (Note that multisystems override this function)
Definition at line 1305 of file system.F90.
subroutine, public system_oct_m::system_update_total_energy | ( | class(system_t), intent(inout) | this | ) |
Calculate the total energy of the system. The total energy is defined as the sum of the kinetic, the internal and the potential energies.
External energy as the sum over interaction energies
Self energy arises from the interaction with itself
Definition at line 1330 of file system.F90.
integer, parameter, public system_oct_m::number_barriers = 1 |
Definition at line 165 of file system.F90.
integer, parameter, public system_oct_m::barrier_restart = 1 |
Definition at line 165 of file system.F90.