gnome.weatherers.evaporation¶
model evaporation process
Classes¶
Base Weathering agent. This is almost exactly like the base Mover |
|
playing around with blob evaporation and time varying fay_area |
Module Contents¶
- class gnome.weatherers.evaporation.Evaporation(water=None, wind=None, **kwargs)¶
Bases:
gnome.weatherers.Weatherer
Base Weathering agent. This is almost exactly like the base Mover in the way that it acts upon the model. It contains the same API as the mover as well. Not Serializable since it does is partial implementation
- Parameters:
conditions – gnome.environment.Conditions object which contains things like water temperature
wind (Wind API, specifically must have get_value(time) method) – wind object for obtaining speed at specified time
- water = None¶
- wind = None¶
- prepare_for_model_run(sc)¶
add evaporated key to mass_balance for now also add ‘density’ key here Assumes all spills have the same type of oil
- weather_elements(sc, time_step, model_time)¶
weather elements over time_step
sets ‘evaporation’ in sc.mass_balance
currently also sets ‘density’ in sc.mass_balance but may update this as we add more weatherers and perhaps density gets set elsewhere
Following diff eq models rate of change each pseudocomponent of oil:
dm(t)/dt = -(1 - fw) * A/B * m(t)
Over a time-step, A, B, C are assumed constant. m(t) is the component mass at beginning of timestep; m(t + Dt) is mass at end of timestep:
m(t + Dt) = m(t) * exp(-L * Dt) L := (1 - fw) * A/B
Define properties for each pseudocomponent of oil and constants:
vp: vapor pressure mw: molecular weight
The following quantities are defined for a given blob of oil. The thickness of the blob is same for all LEs regardless of how many LEs are used to model the blob:
area: area computed from fay spreading m_i: mass of component 'i' sum_m_mw: sum(m_i/mw_i) over all components
effect of wind - mass transport coefficient:
K: See _mass_transport_coeff()
Finally, Evaporation of component ‘i’ for blob of oil:
A = area * K * vp B = gas_constant * water_temp * sum_m_mw
- L becomes::
L = (1 - fw) * area * K * vp/(gas_constant * water_temp * sum_m_mw)
- class gnome.weatherers.evaporation.BlobEvaporation(water=None, wind=None, **kwargs)¶
Bases:
Evaporation
playing around with blob evaporation and time varying fay_area experimental code - not currently used by Model. Testing out the algorithm in ipython notebooks.
- See documentation in source code:
gnome/documentation/evaporation/blob_evap.ipynb
- Parameters:
conditions – gnome.environment.Conditions object which contains things like water temperature
wind (Wind API, specifically must have get_value(time) method) – wind object for obtaining speed at specified time