RUFAS.EEE.energy module#

class RUFAS.EEE.energy.EnergyEstimator#

Bases: object

Class to estimate energy consumption for various operations on the farm

static estimate_all() None#

Runs all estimation functions and performs pre/post processing for them.

report_diesel_consumption(diesel_consumption_data: dict[str, Any], herd_size: int, tractor_size: TractorSize, diesel_consumption_tractor_implement_liter_per_ton: float) None#

Reports diesel consumption data for a specific tractor-implement operation.

Parameters#

diesel_consumption_datadict[str, Any]

Diesel consumption data for the operation.

herd_sizeint

Number of animals in the herd.

tractor_sizeTractorSize

Size of the tractor used.

diesel_consumption_tractor_implement_liter_per_tonfloat

Diesel consumption per ton of implement.

parse_inputs_for_diesel_consumption_calculation() list[dict[str, Any]]#

Parses the OutputManager variables pool for diesel consumption calculation.

calculate_diesel_consumption(crop_yield: float, field_production_size: float, tractor: Tractor, clay_percent: float, application_mass: float | None = None, application_dm_content: float | None = None) float#

General estimate of diesel fuel consumption for a given attachment type and tractor size. Different practices use different types of tools/implements; the equation to estimate diesel fuel consumption may be the same across practices, but different implements have different parameter values.

Parameters#

crop_yield: float

Amount of crop yielded per hectares (metric ton/ha).

field_production_size: float

The filed area under production (ha).

tractor: Tractor

The specifications of the tractor.

clay_percentfloat

The clay percentage of the field under production (unitless).

application_massfloat | None = None

The mass of a manure or fertilizer application (kg).

application_dm_contentfloat | None = None

The dry matter content of a manure or fertilizer application (kg).

Returns#

float

Diesel Consumption for Tractor-Implement (l/ha).

_calculate_total_power_needed(tractor: Tractor, implement: TractorImplement, crop_yield_ton_per_ha: float, field_production_size_ha: float, clay_percent: float, application_mass: float | None = None) float#

Calculates the total power needed to perform the field operation by the tractor and implement where applicable. Implements Helper Function 412 in EEE Functions file.

Parameters#

tractorTractor

The specifications of the tractor.

implementTractorImplement

The specifications of the implement.

crop_yield_ton_per_hafloat

Amount of crop yielded per hectares (metric ton/ha)

field_production_size_hafloat

The filed area under production (ha)

clay_percentfloat

The clay percentage of the field under production (unitless).

application_massfloat | None = None

The mass of a manure or fertilizer application (kg).

Returns#

float

The total power needed for the field operation (kW)