|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object
|
+--net.agmodel.physical.GeneralSequenceImpl
|
+--net.agmodel.weatherData.GeneralMetSequenceImpl
|
+--net.agmodel.weatherData.RHImpl
Humidity manages a sequence of water vapour measurements. It stores these measurements in their original form (eg RH measurements are stored as RH) and provides methods for calculating the others. The getInstant and getValueOverInterval methods return RH measurements - descendent classes handle wet and dry bulb temperature pairs. A link to a temperature class is used for calculations like dewpoint temperature.
| Field Summary |
| Fields inherited from class net.agmodel.weatherData.GeneralMetSequenceImpl |
rb |
| Fields inherited from class net.agmodel.physical.GeneralSequenceImpl |
dateRange, maximumTemporalInterpolation, summaryHistory |
| Constructor Summary | |
RHImpl(Interval dateRange,
SummaryHistory composition,
AirTemperature temperature)
|
|
| Method Summary | |
RHImpl |
average(Duration newResolution)
Creates a new RH sequence, averaging RH to a lower resolution. |
static double |
calcDewpointFromRH(double drybulb,
double rh)
Estimates the dew point temperature from dry bulb temperature and rh. |
static double |
calcTcFromVapourPressure(double vp)
Estimates the temperature for a given vapor pressure. |
static double |
calcVapourPressure(double t)
Estimates the vapour pressure for a given temperature From Weather Algorithms Index |
Object |
clone()
Note that this method does not clone the linked Temperature sequence - the clone refers to the existing one. |
JigsawQuantity |
getAverage(Interval interval)
Returns the average humidity over the interval. |
JigsawQuantity |
getAverageDewpoint(Interval interval)
Returns the average dewpoint temperature over the interval. |
String |
getContentsAsString(Date time,
String delimiter)
Returns the measurement associated with a particular time as a string. |
float[] |
getCoverage(int index)
Indicates which array elements returned by getData(int) are missing.
|
double[] |
getData(int index)
Creates a one-dimensional array containing one subcomponent of the data. |
JigsawQuantity |
getInstant(Date time)
Returns the instantaneous humidity at a particular point in time. |
JigsawQuantity |
getInstantDewpoint(Date time)
Returns the instantaneous dewpoint temperature at a particular point in time. |
JigsawQuantity |
getMaximum(Interval interval)
Returns the maximum humidity over the interval. |
JigsawQuantity |
getMinimum(Interval interval)
Returns the minimum humidity over the interval. |
int |
getNumberOfSubComponents()
Get the number of sub-components in the sequence. |
String |
getSubHeading(int index)
Gets a brief description of the data stored in a Sequence subcomponent in the language of the default locale. |
void |
putInstantRH(Date time,
float value)
Records the instantaneous humidity at a particular time |
void |
putRHOverInterval(Interval interval,
float value)
Records the humidity over some subinterval. |
static double |
saturatedVapourPressure(double temperature)
Source: "Evapotranspiration and Irrigation Water Requirements" American Society of Civil Engineers, 1990 |
protected void |
setStore(Store newStore)
|
void |
setSubHeading(int index,
String aHeading)
Does nothing |
void |
setTemperatureSequence(AirTemperature temperature)
|
MetSequence |
summarize(Duration longerResolution)
Creates a lower resolution sequence which summarizes this sequence |
static double |
vapourPressureDeficit(double t,
double rH)
|
| Methods inherited from class net.agmodel.weatherData.GeneralMetSequenceImpl |
getColumnHeading, getName, getSequenceElement, getSequenceHeading, getUnitsHeading, setColumnHeading, setName, setSequenceHeading, setUnitsHeading |
| Methods inherited from class net.agmodel.physical.GeneralSequenceImpl |
cancelTemporalInterpolation, dumpSequence, getAllCoverage, getAllData, getCurrentResolution, getDateRange, getMaximumTemporalInterpolation, getResolution, getSubHeading, getSummaryHistory, getSummaryKind, getTemporalInterpolation, getUnitsHeading, setTemporalInterpolation |
| Methods inherited from class java.lang.Object |
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface net.agmodel.weatherData.MetSequence |
getSequenceElement |
| Methods inherited from interface net.agmodel.physical.CompoundSequence |
cancelTemporalInterpolation, getAllCoverage, getAllData, getMaximumTemporalInterpolation, getTemporalInterpolation, getUnitsHeading, setSequenceHeading, setTemporalInterpolation, setUnitsHeading |
| Methods inherited from interface net.agmodel.physical.Sequence |
dumpSequence, getColumnHeading, getCurrentResolution, getDateRange, getName, getResolution, getSequenceHeading, getSubHeading, getSummaryKind, getUnitsHeading, setColumnHeading, setName |
| Constructor Detail |
public RHImpl(Interval dateRange,
SummaryHistory composition,
AirTemperature temperature)
| Method Detail |
protected void setStore(Store newStore)
public void setTemperatureSequence(AirTemperature temperature)
public static double saturatedVapourPressure(double temperature)
public static double vapourPressureDeficit(double t,
double rH)
public static double calcVapourPressure(double t)
public static double calcTcFromVapourPressure(double vp)
vp - the vapour pressure in millibars
public static double calcDewpointFromRH(double drybulb,
double rh)
drybulb - the temperature in Celsiusrh - the relative humidity in %
public void putInstantRH(Date time,
float value)
time - the point in timevalue - the humidity at that time
IllegalArgumentException - if the time is outside the interval that the period is intended to store
public void putRHOverInterval(Interval interval,
float value)
interval - the period of time over which the measurement was taken.value - the humidity over that interval
IllegalArgumentException - if the subinterval is outside the interval that the sequence was constructed to storepublic JigsawQuantity getMinimum(Interval interval)
Humidity
getMinimum in interface Humiditypublic JigsawQuantity getMaximum(Interval interval)
Humidity
getMaximum in interface Humiditypublic JigsawQuantity getInstant(Date time)
Humidity
getInstant in interface Humiditypublic JigsawQuantity getAverage(Interval interval)
Humidity
getAverage in interface Humidity
public String getContentsAsString(Date time,
String delimiter)
Sequence
getContentsAsString in interface SequencegetContentsAsString in class GeneralSequenceImpltime - the time of interest.delimiter - a string to use between values if required.public RHImpl average(Duration newResolution)
newResolution - the target resolution required.
public JigsawQuantity getInstantDewpoint(Date time)
Humidity
getInstantDewpoint in interface Humiditypublic JigsawQuantity getAverageDewpoint(Interval interval)
Humidity
getAverageDewpoint in interface Humiditypublic MetSequence summarize(Duration longerResolution)
MetSequence
summarize in interface MetSequencelongerResolution - the new resolution to summarize to
public int getNumberOfSubComponents()
Sequence
getNumberOfSubComponents in interface SequencegetNumberOfSubComponents in class GeneralMetSequenceImplSequence.getSequenceHeading(String)public String getSubHeading(int index)
CompoundSequence
getSubHeading in interface CompoundSequencegetSubHeading in class GeneralMetSequenceImplSequence.getNumberOfSubComponents(),
Sequence.getSequenceHeading(String)
public void setSubHeading(int index,
String aHeading)
setSubHeading in interface CompoundSequencesetSubHeading in class GeneralMetSequenceImplaHeading - the new headingindex - the zero-based index of the headingSequence.getNumberOfSubComponents(),
Sequence.getSequenceHeading(String)public double[] getData(int index)
CompoundSequenceCompoundSequence.getCoverage(int) to test for missing values
(at present these are returned as Double.NaN but don't rely on this).
getData in interface CompoundSequencegetData in class GeneralSequenceImplindex - the zero-based index of the subcomponent
Sequence.getNumberOfSubComponents()public float[] getCoverage(int index)
CompoundSequenceCompoundSequence.getData(int) are missing.
Coverage values are in the range JigsawQuantity.DEVOID to JigsawQuantity.COMPLETE.
getCoverage in interface CompoundSequencegetCoverage in class GeneralSequenceImplindex - the zero-based index of the subcomponent
public Object clone()
clone in interface Sequenceclone in class GeneralSequenceImpl
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||