Monte Carlo simulation. More...
Classes | |
struct | run_mc_opt_t |
Options controlling the execution of run_mc(). More... | |
interface | run_mc__interface |
interface | mc_coag__interface |
Functions | |
subroutine | run_mc (kernel, bin_grid, aero_binned, env_data, env_state, aero_data, aero_state, gas_data, gas_state, mc_opt, process_spec_list) |
Do a particle-resolved Monte Carlo simulation. | |
subroutine | mc_coag (kernel, bin_grid, aero_binned, env_state, aero_data, aero_state, mc_opt, k_max, tot_n_samp, n_coag) |
Do coagulation for time del_t. | |
subroutine | compute_n_samp (ni, nj, same_bin, k_max, comp_vol, del_t, n_samp_real) |
Compute the number of samples required for the pair of bins. | |
subroutine | mc_mix (aero_data, aero_state, gas_data, gas_state, aero_binned, env_state, bin_grid, mix_rate) |
Mix data between processes. | |
integer | pmc_mpi_pack_size_mc_opt (val) |
Determines the number of bytes required to pack the given value. | |
subroutine | pmc_mpi_pack_mc_opt (buffer, position, val) |
Packs the given value into the buffer, advancing position. | |
subroutine | pmc_mpi_unpack_mc_opt (buffer, position, val) |
Unpacks the given value from the buffer, advancing position. |
Monte Carlo simulation.
subroutine pmc_run_mc::compute_n_samp | ( | integer,intent(in) | ni, | |
integer,intent(in) | nj, | |||
logical,intent(in) | same_bin, | |||
real*8,intent(in) | k_max, | |||
real*8,intent(in) | comp_vol, | |||
real*8,intent(in) | del_t, | |||
real*8,intent(out) | n_samp_real | |||
) |
Compute the number of samples required for the pair of bins.
ni | Number particles in first bin . | |
nj | Number particles in second bin. | |
same_bin | Whether first bin is second bin. | |
k_max | Maximum kernel value. | |
comp_vol | Computational volume (m^3). | |
del_t | Timestep (s). | |
n_samp_real | Number of samples per timestep. |
subroutine pmc_run_mc::mc_coag | ( | pmc_run_mc::mc_coag__interface | kernel, | |
type(bin_grid_t),intent(in) | bin_grid, | |||
type(aero_binned_t),intent(out) | aero_binned, | |||
type(env_state_t),intent(inout) | env_state, | |||
type(aero_data_t),intent(in) | aero_data, | |||
type(aero_state_t),intent(inout) | aero_state, | |||
type(run_mc_opt_t),intent(in) | mc_opt, | |||
real*8,dimension(bin_grid%n_bin,bin_grid%n_bin),intent(in) | k_max, | |||
integer,intent(out) | tot_n_samp, | |||
integer,intent(out) | n_coag | |||
) |
Do coagulation for time del_t.
bin_grid | Bin grid. | |
aero_binned | Binned distributions. | |
env_state | Environment state. | |
aero_data | Aerosol data. | |
aero_state | Aerosol state. | |
mc_opt | Monte Carlo options. | |
k_max | Maximum kernel. | |
tot_n_samp | Total number of samples tested. | |
n_coag | Number of coagulation events. |
subroutine pmc_run_mc::mc_mix | ( | type(aero_data_t),intent(in) | aero_data, | |
type(aero_state_t),intent(inout) | aero_state, | |||
type(gas_data_t),intent(in) | gas_data, | |||
type(gas_state_t),intent(inout) | gas_state, | |||
type(aero_binned_t),intent(inout) | aero_binned, | |||
type(env_state_t),intent(inout) | env_state, | |||
type(bin_grid_t),intent(in) | bin_grid, | |||
real*8,intent(in) | mix_rate | |||
) |
Mix data between processes.
aero_data | Aerosol data. | |
aero_state | Aerosol state. | |
gas_data | Gas data. | |
gas_state | Gas state. | |
aero_binned | Binned aerosol data. | |
env_state | Environment. | |
bin_grid | Bin grid. | |
mix_rate | Amount to mix (0 to 1). |
subroutine pmc_run_mc::pmc_mpi_pack_mc_opt | ( | character,dimension(:),intent(inout) | buffer, | |
integer,intent(inout) | position, | |||
type(run_mc_opt_t),intent(in) | val | |||
) |
Packs the given value into the buffer, advancing position.
buffer | Memory buffer. | |
position | Current buffer position. | |
val | Value to pack. |
integer pmc_run_mc::pmc_mpi_pack_size_mc_opt | ( | type(run_mc_opt_t),intent(in) | val | ) |
Determines the number of bytes required to pack the given value.
val | Value to pack. |
subroutine pmc_run_mc::pmc_mpi_unpack_mc_opt | ( | character,dimension(:),intent(inout) | buffer, | |
integer,intent(inout) | position, | |||
type(run_mc_opt_t),intent(out) | val | |||
) |
Unpacks the given value from the buffer, advancing position.
buffer | Memory buffer. | |
position | Current buffer position. | |
val | Value to pack. |
subroutine pmc_run_mc::run_mc | ( | pmc_run_mc::run_mc__interface | kernel, | |
type(bin_grid_t),intent(in) | bin_grid, | |||
type(aero_binned_t),intent(out) | aero_binned, | |||
type(env_data_t),intent(in) | env_data, | |||
type(env_state_t),intent(inout) | env_state, | |||
type(aero_data_t),intent(in) | aero_data, | |||
type(aero_state_t),intent(inout) | aero_state, | |||
type(gas_data_t),intent(in) | gas_data, | |||
type(gas_state_t),intent(inout) | gas_state, | |||
type(run_mc_opt_t),intent(in) | mc_opt, | |||
type(process_spec_t),dimension(:),intent(in) | process_spec_list | |||
) |
Do a particle-resolved Monte Carlo simulation.
bin_grid | Bin grid. | |
aero_binned | Binned distributions. | |
env_data | Environment state. | |
env_state | Environment state. | |
aero_data | Aerosol data. | |
aero_state | Aerosol state. | |
gas_data | Gas data. | |
gas_state | Gas state. | |
mc_opt | Monte Carlo options. | |
process_spec_list | Processing spec. |