pmc_env_state Namespace Reference

The env_state_t structure and associated subroutines. More...

Classes

struct  env_state_t
 Current environment state. More...

Functions

subroutine env_state_alloc (env_state)
 Allocate an empty environment.
subroutine env_state_free (env_state)
 Free all storage.
subroutine env_state_add (env_state, env_state_delta)
 env_state += env_state_delta
subroutine env_state_scale (env_state, alpha)
 env_state *= alpha
subroutine env_state_copy (env_from, env_to)
 env_to = env_from
subroutine env_state_change_water_volume (env_state, aero_data, dv)
 Adds the given water volume to the water vapor and updates all environment quantities.
real *8 env_state_sat_vapor_pressure (env_state)
 Computes the current saturation vapor pressure (Pa).
real *8 aero_particle_kappa_rh (aero_particle, aero_data, env_state)
 Returns the critical relative humidity from the kappa value (1).
real *8 env_state_air_den (env_state)
 Air density (kg m^{-3}).
real *8 env_state_air_molar_den (env_state)
 Air molar density (mole m^{-3}).
subroutine gas_state_mole_dens_to_ppb (gas_state, env_state)
 Convert (mole m^{-3}) to (ppb).
subroutine env_state_update_gas_state (env_state, delta_t, old_height, gas_data, gas_state)
 Do emissions and background dilution from the environment.
subroutine env_state_update_aero_state (env_state, delta_t, old_height, bin_grid, aero_data, aero_state, aero_binned)
 Do emissions and background dilution from the environment for a particle aerosol distribution.
subroutine env_state_update_aero_binned (env_state, delta_t, old_height, bin_grid, aero_data, aero_binned)
 Do emissions and background dilution from the environment for a binned aerosol distribution.
subroutine inout_write_env_state (file, env_state)
 Write full state.
subroutine inout_read_env_state (file, env_state)
 Read full state.
subroutine spec_read_env_state (file, env_state)
 Read environment specification from a inout file.
subroutine env_state_average (env_vec, env_avg)
 Computes the average of an array of env_state.
subroutine env_state_mix (val)
 Average val over all processes.
integer pmc_mpi_pack_size_env_state (val)
 Determines the number of bytes required to pack the given value.
subroutine pmc_mpi_pack_env_state (buffer, position, val)
 Packs the given value into the buffer, advancing position.
subroutine pmc_mpi_unpack_env_state (buffer, position, val)
 Unpacks the given value from the buffer, advancing position.
subroutine pmc_mpi_reduce_avg_env_state (val, val_avg)
 Computes the average of val across all processes, storing the result in val_avg on the root process.

Detailed Description

The env_state_t structure and associated subroutines.


Function Documentation

real*8 pmc_env_state::aero_particle_kappa_rh ( type(aero_particle_t),intent(in)  aero_particle,
type(aero_data_t),intent(in)  aero_data,
type(env_state_t),intent(in)  env_state 
)

Returns the critical relative humidity from the kappa value (1).

Parameters:
aero_particle Aerosol particle.
aero_data Aerosol data.
env_state Environment state.
subroutine pmc_env_state::env_state_add ( type(env_state_t),intent(inout)  env_state,
type(env_state_t),intent(in)  env_state_delta 
)

env_state += env_state_delta

Parameters:
env_state Environment.
env_state_delta Increment.
real*8 pmc_env_state::env_state_air_den ( type(env_state_t),intent(in)  env_state  ) 

Air density (kg m^{-3}).

Parameters:
env_state Environment state.
real*8 pmc_env_state::env_state_air_molar_den ( type(env_state_t),intent(in)  env_state  ) 

Air molar density (mole m^{-3}).

Parameters:
env_state Environment state.
subroutine pmc_env_state::env_state_alloc ( type(env_state_t),intent(out)  env_state  ) 

Allocate an empty environment.

Parameters:
env_state Environment.
subroutine pmc_env_state::env_state_average ( type(env_state_t),dimension(:),intent(in)  env_vec,
type(env_state_t),intent(out)  env_avg 
)

Computes the average of an array of env_state.

Parameters:
env_vec Array of env_state.
env_avg Average of env_vec.
subroutine pmc_env_state::env_state_change_water_volume ( type(env_state_t),intent(inout)  env_state,
type(aero_data_t),intent(in)  aero_data,
real*8,intent(in)  dv 
)

Adds the given water volume to the water vapor and updates all environment quantities.

Parameters:
env_state Environment state to update.
aero_data Aero_data constants.
dv Conc of water added (m^3/m^3).
subroutine pmc_env_state::env_state_copy ( type(env_state_t),intent(in)  env_from,
type(env_state_t),intent(inout)  env_to 
)

env_to = env_from

Parameters:
env_from Original.
env_to Destination.
subroutine pmc_env_state::env_state_free ( type(env_state_t),intent(out)  env_state  ) 

Free all storage.

Parameters:
env_state Environment.
subroutine pmc_env_state::env_state_mix ( type(env_state_t),intent(inout)  val  ) 

Average val over all processes.

Parameters:
val Value to average.
real*8 pmc_env_state::env_state_sat_vapor_pressure ( type(env_state_t),intent(in)  env_state  ) 

Computes the current saturation vapor pressure (Pa).

Parameters:
env_state Environment state.
subroutine pmc_env_state::env_state_scale ( type(env_state_t),intent(inout)  env_state,
real*8,intent(in)  alpha 
)

env_state *= alpha

Parameters:
env_state Environment.
alpha Scale factor.
subroutine pmc_env_state::env_state_update_aero_binned ( type(env_state_t),intent(in)  env_state,
real*8,intent(in)  delta_t,
real*8,intent(in)  old_height,
type(bin_grid_t),intent(in)  bin_grid,
type(aero_data_t),intent(in)  aero_data,
type(aero_binned_t),intent(inout)  aero_binned 
)

Do emissions and background dilution from the environment for a binned aerosol distribution.

Parameters:
env_state Current environment.
delta_t Time increment to update over.
old_height Previous height (m).
bin_grid Bin grid.
aero_data Aero data values.
aero_binned Aero binned to update.
subroutine pmc_env_state::env_state_update_aero_state ( type(env_state_t),intent(in)  env_state,
real*8,intent(in)  delta_t,
real*8,intent(in)  old_height,
type(bin_grid_t),intent(in)  bin_grid,
type(aero_data_t),intent(in)  aero_data,
type(aero_state_t),intent(inout)  aero_state,
type(aero_binned_t),intent(inout)  aero_binned 
)

Do emissions and background dilution from the environment for a particle aerosol distribution.

Parameters:
env_state Current environment.
delta_t Time increment to update over.
old_height Previous height (m).
bin_grid Bin grid.
aero_data Aero data values.
aero_state Aero state to update.
aero_binned Aero binned to update.
subroutine pmc_env_state::env_state_update_gas_state ( type(env_state_t),intent(in)  env_state,
real*8,intent(in)  delta_t,
real*8,intent(in)  old_height,
type(gas_data_t),intent(in)  gas_data,
type(gas_state_t),intent(inout)  gas_state 
)

Do emissions and background dilution from the environment.

Parameters:
env_state Current environment.
delta_t Time increment to update over.
old_height Previous height (m).
gas_data Gas data values.
gas_state Gas state to update.
subroutine pmc_env_state::gas_state_mole_dens_to_ppb ( type(gas_state_t),intent(inout)  gas_state,
type(env_state_t),intent(in)  env_state 
)

Convert (mole m^{-3}) to (ppb).

Parameters:
gas_state Gas state.
env_state Environment state.
subroutine pmc_env_state::inout_read_env_state ( type(inout_file_t),intent(inout)  file,
type(env_state_t),intent(out)  env_state 
)

Read full state.

Parameters:
file File to read from.
env_state Environment to read.
subroutine pmc_env_state::inout_write_env_state ( type(inout_file_t),intent(inout)  file,
type(env_state_t),intent(in)  env_state 
)

Write full state.

Parameters:
file File to write to.
env_state Environment to write.
subroutine pmc_env_state::pmc_mpi_pack_env_state ( character,dimension(:),intent(inout)  buffer,
integer,intent(inout)  position,
type(env_state_t),intent(in)  val 
)

Packs the given value into the buffer, advancing position.

Parameters:
buffer Memory buffer.
position Current buffer position.
val Value to pack.
integer pmc_env_state::pmc_mpi_pack_size_env_state ( type(env_state_t),intent(in)  val  ) 

Determines the number of bytes required to pack the given value.

Parameters:
val Value to pack.
subroutine pmc_env_state::pmc_mpi_reduce_avg_env_state ( type(env_state_t),intent(in)  val,
type(env_state_t),intent(out)  val_avg 
)

Computes the average of val across all processes, storing the result in val_avg on the root process.

Parameters:
val Value to average.
val_avg Result.
subroutine pmc_env_state::pmc_mpi_unpack_env_state ( character,dimension(:),intent(inout)  buffer,
integer,intent(inout)  position,
type(env_state_t),intent(out)  val 
)

Unpacks the given value from the buffer, advancing position.

Parameters:
buffer Memory buffer.
position Current buffer position.
val Value to pack.
subroutine pmc_env_state::spec_read_env_state ( type(inout_file_t),intent(inout)  file,
type(env_state_t),intent(out)  env_state 
)

Read environment specification from a inout file.

Parameters:
file Inout file.
env_state Environment data.

Generated on 29 Mar 2010 for PartMC by  doxygen 1.6.1