RUFAS.routines.field.crop.nutrient_uptake module#

class RUFAS.routines.field.crop.nutrient_uptake.NutrientUptake(crop_data: CropData | None)#

Bases: ABC

Manages overlapping logic for nitrogen, phosphorus, and water uptake in crops.

Parameters#

crop_dataOptional[CropData], optional

An instance of CropData containing crop specifications and attributes. Defaults to a new instance of CropData if not provided.

__init__(crop_data: CropData | None)#
abstractmethod uptake(soil_data: SoilData) None#

Abstract method for nutrient uptake.

static determine_layer_nutrient_demands(uptake_potentials: list[float], nutrient_availabilities: list[float]) list[float]#

Calculates the demand for a nutrient from each soil layer.

Parameters#

uptake_potentialslist[float]

Maximum uptake of the nutrient by the plant from each soil layer.

nutrient_availabilitieslist[float]

Available amount of the nutrient in each soil layer.

Returns#

list[float]

Demands for the nutrient from each soil layer.

References#

pseudocode: C.5.C.5

static tally_total_nutrient_uptake(actual_nutrient_uptakes: list[float]) float#

Determines total nutrient extracted from soil by summing actual uptake from each layer.

Parameters#

actual_nutrient_uptakesOptional[List[float]]

Actual nutrient uptake from each soil layer (kg/ha or mm).

_abc_impl = <_abc._abc_data object>#