RUFAS.biophysical.feed_storage.hay module#
- RUFAS.biophysical.feed_storage.hay.FINAL_MOISTURE_PERCENTAGE = 12#
Number of days after a hayed crop is stored during which it experiences increased dry matter and moisture loss.
- RUFAS.biophysical.feed_storage.hay.INITIAL_LOSS_PERIOD = 30#
These loss coefficients determine how much additional dry matter is lost in specific types of hayed crops. References Feed Storage Scientific Documentation table FS.HAY.7.
- class RUFAS.biophysical.feed_storage.hay.Hay(config: dict[str, str | float])#
Bases:
Storage
Represents a Hay storage subclass of Storage.
Parameters#
- configdict[str, str | float]
Configuration dictionary for the hay storage.
Attributes#
- bale_sizefloat
Diameter of the hay bale in meters.
- target_dry_matterfloat
The target dry matter content of hay after drying down in storage (unitless).
- additional_dry_matter_loss_coefficientfloat
Coefficient determining how much additional dry matter is lost in hayed crops (unitless).
Methods#
- calculate_protein_loss():
Calculates the protein loss in the hay.
- __init__(config: dict[str, str | float]) None #
- process_degradations(weather: Weather, time: RufasTime) None #
Processes the loss of moisture in hayed crops, and calls the base class’s implementation of process_degradations to process the loss of dry matter.
Parameters#
- weatherWeather
Weather instance containing all weather information for the simulation.
- timeRufasTime
RufasTime instance tracking the current time of the simulation.
References#
Feed Storage Scientific Documentation table FS.HAY.9.
- project_degradations(crops: list[HarvestedCrop], weather: Weather, time: RufasTime) list[HarvestedCrop] #
Projects the state of crops currently stored at a given future date.
Parameters#
- cropslist[HarvestedCrop]
List of HarvestedCrops to project degradations for.
- weatherWeather
Weather instance containing all weather information for the simulation.
- timeRufasTime
RufasTime instance containing the date at which the state of the stored crops should be projected.
Returns#
- list[HarvestedCrop]
Crops in the state they are projected to be in at the given date.
- calculate_dry_matter_loss_to_gas(crop: HarvestedCrop, weather_conditions: list[CurrentDayConditions], time: RufasTime) float #
Calculates the base amount of gaseous dry matter lost in a hayed crop.
Parameters#
- cropHarvestedCrop
The hayed crop to process dry matter loss in.
- weather_conditionslist[CurrentDayConditions]
List of daily weather conditions over which dry matter loss will be calculated.
- timeRufasTime
RufasTime instance containing the time that loss should be processed up to.
Returns#
- float
Mass of gaseous dry matter lost since from hayed crop since the last time it losses were processed for it (kg).
References#
FS.HAY.6, FS.HAY.7
- _calculate_initial_dry_matter_loss_to_gas(crop: HarvestedCrop, time: date) float #
Calculates the amount of gaseous dry matter lost in a hayed crop in its first 30 days of storage.
Parameters#
- cropHarvestedCrop
The hayed crop to process dry matter loss in.
- timedate
The date that loss should be processed up to.
Returns#
- float
Gaseous dry matter loss from the hayed crop that occurred in the first 30 days of storage (kg).
References#
[1] Feed Storage Scientific Documentation, equation FS.HAY.3, FS.HAY.4, FS.HAY.5
- _calculate_subsequent_dry_matter_loss_to_gas(crop: HarvestedCrop, time: date) float #
Calculates the amount of gaseous dry matter lost in a hayed crop after its first 30 days of storage.
Parameters#
- cropHarvestedCrop
The hayed crop to process dry matter loss in.
- timedate
The date that loss should be processed up to.
Returns#
- float
Gaseous dry matter loss from the hayed crop that occurred after the first 30 days of storage (kg).
References#
[1] Feed Storage Scientific Documentation, equation FS.HAY.6
- _calculate_additional_dry_matter_loss(crop: HarvestedCrop, weather_conditions: list[CurrentDayConditions]) float #
Calculates additional dry matter loss in hayed crops.
Parameters#
- cropHarvestedCrop
The hayed crop to process dry matter loss in.
- weather_conditionslist[CurrentDayConditions]
List of daily weather conditions over which additional dry matter loss will be calculated.
Returns#
- float
Loss of dry matter that occurred over the specified period of weather conditions in kg.
Notes#
If the additional dry matter loss coefficient is 0, the equation this method implements will always result in zero, so 0 is returned immediately in this case to avoid unnecessary computation.
References#
[1] Feed Storage Scienitific Documentation, equation FS.HAY.7 and Table FS.HAY.8
- class RUFAS.biophysical.feed_storage.hay.ProtectedIndoors(config: dict[str, str | float])#
Bases:
Hay
Represents protected indoors hay storage, a subclass of Hay.
- __init__(config: dict[str, str | float]) None #
- class RUFAS.biophysical.feed_storage.hay.ProtectedWrapped(config: dict[str, str | float])#
Bases:
Hay
Represents protected wrapped hay storage, a subclass of Hay.
- __init__(config: dict[str, str | float]) None #
- class RUFAS.biophysical.feed_storage.hay.ProtectedTarped(config: dict[str, str | float])#
Bases:
Hay
Represents protected tarped hay storage, a subclass of Hay.
- __init__(config: dict[str, str | float]) None #
- class RUFAS.biophysical.feed_storage.hay.Unprotected(config: dict[str, str | float])#
Bases:
Hay
Represents unprotected hay storage, a subclass of Hay.
Notes#
The nutrient-specific loss coefficients are listed in tables FS.HAY.10 and FS.HAY.11 of the Feed Storage Scientific Documentation.
- __init__(config: dict[str, str | float]) None #