:py:mod:`gnome.weatherers.bio_degradation` ========================================== .. py:module:: gnome.weatherers.bio_degradation .. autoapi-nested-parse:: model bio degradation process Module Contents --------------- Classes ~~~~~~~ .. autoapisummary:: gnome.weatherers.bio_degradation.Biodegradation .. py:class:: Biodegradation(waves=None, **kwargs) Bases: :py:obj:`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 Base weatherer class; defines the API for all weatherers Passes optional arguments to base (Process) class via super. See base class for optional arguments: `gnome.movers.mover.Process` adds 'mass_components', 'mass' to array_types since all weatherers need these. .. py:attribute:: _schema .. py:attribute:: _ref_as :value: 'biodegradation' .. py:attribute:: _req_refs :value: ['waves'] .. py:method:: prepare_for_model_run(sc) Add biodegradation key to mass_balance if it doesn't exist. - Assumes all spills have the same type of oil - let's only define this the first time .. py:method:: initialize_data(sc, num_released) Initialize needed weathering data arrays but only if 'on' is True .. py:method:: bio_degradate_oil(K, data, yield_factor) Calculate oil bio degradation K - biodegradation rate coefficients are calculated for temperate or arctic environment conditions yield_factor - specific surface value (sq meter per kg) yield_factor = 1 / ( d * ro) where d - droplet diameter ro - droplet density data['mass_components'] - mass of pseudocomponents .. py:method:: get_K_comp_rates(type_and_bp) Get bio degradation rate coefficient based on component type and its boiling point for temparate or arctic environment conditions. It must take into consideration saturates below C30 and aromatics only. type_and_bp - a tuple ('type', 'boiling_point') - 'type': component type, string - 'boiling_point': float value self.arctic - flag for arctic conditions - TRUE if arctic conditions (below 6 deg C) - FALSE if temperate Rate units: kg/m^2 per day(!) .. py:method:: weather_elements(sc, time_step, model_time) weather elements over time_step