org.n52.operation.cropmodeling
Class CropData

java.lang.Object
  extended by org.n52.operation.cropmodeling.AttributeData
      extended by org.n52.operation.cropmodeling.CropData

public class CropData
extends AttributeData

Read crop data from a parameter file (crops.crp) The file contains crop related parameters and is a comma-delimited text file.

File organisation:

Crop parameter data is organised in sections of 10 lines.

First line: contains the name of the crop (may be surrounded by double quotes)

Second line: 9 items;

  • the first item indicates the croptype (C3 or C4)
  • second item is the threshold temperature
  • third item indicates the heat requirement
  • fourth item indicates the the heat requirement for the leaves

    Third line:

  • first item is the MaxSpecificLeafArea
  • second item is the MinSpecificLeafArea
  • third item is the ExtinctionCoefficient
  • fourth until seventh item describe relativeMaintenanceRespiration

    Fourth line:

    describes the conversionEfficiency of the different parts of crop: leaf, root, stem, storage

    Author:
    willem nieuwenhuis

    Field Summary
     
    Fields inherited from class org.n52.operation.cropmodeling.AttributeData
    attributes, name
     
    Constructor Summary
    CropData(java.lang.String dataFileName, java.lang.String cropName)
               
     
    Method Summary
     double getAllocatedMassFraction(int organIndex, double relativeDevelopmentStage)
               
     double getIndexedAttribute(java.lang.String attributeName, int index)
               
     boolean isC3Crop()
               
     
    Methods inherited from class org.n52.operation.cropmodeling.AttributeData
    getAttributeData, getAttributes, setAttributeData
     
    Methods inherited from class java.lang.Object
    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
     

    Constructor Detail

    CropData

    public CropData(java.lang.String dataFileName,
                    java.lang.String cropName)
    Parameters:
    dataFileName -
    cropName -
    Method Detail

    getAllocatedMassFraction

    public double getAllocatedMassFraction(int organIndex,
                                           double relativeDevelopmentStage)
    Parameters:
    organIndex -
    relativeDevelopmentStage -
    Returns:
    the mass fraction

    getIndexedAttribute

    public double getIndexedAttribute(java.lang.String attributeName,
                                      int index)
    Overrides:
    getIndexedAttribute in class AttributeData
    Returns:
    NaN

    isC3Crop

    public boolean isC3Crop()
    Returns:
    Returns the c3Crop.