CAMP 1.0.0
Chemistry Across Multiple Phases
|
A chemical mechanism. More...
Public Member Functions | |
procedure | load (this, json, j_obj) |
Load reactions from an input file. | |
procedure | initialize (this, chem_spec_data, aero_rep_data, n_cells) |
Initialize the mechanism. | |
procedure | name (this) |
Get the mechanism name. | |
procedure | size (this) |
Get the size of the reaction database. | |
procedure | get_rxn (this, rxn_id) |
Get a reaction by its index. | |
procedure | pack_size (this, comm) |
Determine the number of bytes required to pack the given value. | |
procedure | bin_pack (this, buffer, pos, comm) |
Packs the given value into the buffer, advancing position. | |
procedure | bin_unpack (this, buffer, pos, comm) |
Unpacks the given value from the buffer, advancing position. | |
procedure | print (this, file_unit) |
Print the mechanism data. | |
final | finalize (this) |
Finalize the mechanism. | |
Public Attributes | |
character(len=:), allocatable | mech_name |
Mechanism name. | |
character(len=:), allocatable | fixed_file_prefix |
Path and prefix for fixed module output. | |
type(rxn_data_ptr), dimension(:), pointer | rxn_ptr => null() |
Reactions. | |
Private Member Functions | |
procedure, private | ensure_size (this, num_rxn) |
Ensure there is enough room in the reaction dataset to add a specified number of reactions. | |
Private Attributes | |
integer(kind=i_kind) | num_rxn = 0 |
Number of reactions. | |
A chemical mechanism.
Instances of mechanism_data_t represent complete CAMP: Chemical Mechanism chemical mechanism. Multiple mechanisms may be used during one model run and will be solved simultaneously.
Definition at line 60 of file mechanism_data.F90.
|
final |
Finalize the mechanism.
[in,out] | this | Mechanism data |
Definition at line 90 of file mechanism_data.F90.
procedure camp_mechanism_data::mechanism_data_t::bin_pack | ( | class(mechanism_data_t), intent(in) | this, |
character, dimension(:), intent(inout) | buffer, | ||
integer, intent(inout) | pos, | ||
integer, intent(in) | comm | ||
) |
Packs the given value into the buffer, advancing position.
[in] | this | Chemical mechanism |
[in,out] | buffer | Memory buffer |
[in,out] | pos | Current buffer position |
[in] | comm | MPI communicator |
Definition at line 84 of file mechanism_data.F90.
procedure camp_mechanism_data::mechanism_data_t::bin_unpack | ( | class(mechanism_data_t), intent(inout) | this, |
character, dimension(:), intent(inout) | buffer, | ||
integer, intent(inout) | pos, | ||
integer, intent(in) | comm | ||
) |
Unpacks the given value from the buffer, advancing position.
[in,out] | this | Chemical mechanism |
[in,out] | buffer | Memory buffer |
[in,out] | pos | Current buffer position |
[in] | comm | MPI communicator |
Definition at line 86 of file mechanism_data.F90.
|
private |
Ensure there is enough room in the reaction dataset to add a specified number of reactions.
[in,out] | this | Chemical mechanism |
[in] | num_rxn | Number of new reactions to ensure space for |
Definition at line 95 of file mechanism_data.F90.
procedure camp_mechanism_data::mechanism_data_t::get_rxn | ( | class(mechanism_data_t), intent(in) | this, |
integer(kind=i_kind), intent(in) | rxn_id | ||
) |
Get a reaction by its index.
[in] | this | Mechanism data |
[in] | rxn_id | Reaction index |
Definition at line 80 of file mechanism_data.F90.
procedure camp_mechanism_data::mechanism_data_t::initialize | ( | class(mechanism_data_t), intent(inout) | this, |
type(chem_spec_data_t), intent(in) | chem_spec_data, | ||
type(aero_rep_data_ptr), dimension(:), intent(in), pointer | aero_rep_data, | ||
integer(kind=i_kind), intent(in) | n_cells | ||
) |
Initialize the mechanism.
[in,out] | this | Chemical mechanism |
[in] | chem_spec_data | Chemical species data |
[in] | aero_rep_data | Aerosol representation data |
[in] | n_cells | Number of grid cells to solve simultaneously |
Definition at line 74 of file mechanism_data.F90.
procedure camp_mechanism_data::mechanism_data_t::load | ( | class(mechanism_data_t), intent(inout) | this, |
type(json_core), intent(in), pointer | json, | ||
type(json_value), intent(in), pointer | j_obj | ||
) |
Load reactions from an input file.
[in,out] | this | Chemical mechanism |
[in] | json | JSON core |
[in] | j_obj | JSON object |
Definition at line 72 of file mechanism_data.F90.
procedure camp_mechanism_data::mechanism_data_t::name | ( | class(mechanism_data_t), intent(in) | this | ) |
Get the mechanism name.
[in] | this | Chemical mechanism |
Definition at line 76 of file mechanism_data.F90.
procedure camp_mechanism_data::mechanism_data_t::pack_size | ( | class(mechanism_data_t), intent(in) | this, |
integer, intent(in) | comm | ||
) |
Determine the number of bytes required to pack the given value.
[in] | this | Chemical mechanism |
[in] | comm | MPI communicator |
Definition at line 82 of file mechanism_data.F90.
procedure camp_mechanism_data::mechanism_data_t::print | ( | class(mechanism_data_t), intent(in) | this, |
integer(kind=i_kind), optional | file_unit | ||
) |
Print the mechanism data.
[in] | this | Chemical mechanism |
file_unit | File unit for output |
Definition at line 88 of file mechanism_data.F90.
procedure camp_mechanism_data::mechanism_data_t::size | ( | class(mechanism_data_t), intent(in) | this | ) |
Get the size of the reaction database.
[in] | this | Chemical mechanism |
Definition at line 78 of file mechanism_data.F90.
character(len=:), allocatable camp_mechanism_data::mechanism_data_t::fixed_file_prefix |
Path and prefix for fixed module output.
Definition at line 67 of file mechanism_data.F90.
character(len=:), allocatable camp_mechanism_data::mechanism_data_t::mech_name |
Mechanism name.
Definition at line 65 of file mechanism_data.F90.
|
private |
Number of reactions.
Definition at line 63 of file mechanism_data.F90.
type(rxn_data_ptr), dimension(:), pointer camp_mechanism_data::mechanism_data_t::rxn_ptr => null() |
Reactions.
Definition at line 69 of file mechanism_data.F90.