public class PowerGenerationPatternContainer extends java.lang.Object implements AsciiSerializable, java.lang.Cloneable, hec.rss.model.reports.AltInputReportInfc
Title: Hec Java Development
Description: This is a simple container class that manages and contains a group of individual Power Generation Patterns indexed by date.
Copyright: Copyright (c) 2003
Company:
| Constructor and Description |
|---|
PowerGenerationPatternContainer() |
| Modifier and Type | Method and Description |
|---|---|
void |
clearPwrGenPatterns() |
static void |
clipPatternToMax(double[] pattern,
double[] patmax,
int istart,
int inum,
double reqval)
clip the pattern to the given max limit from the given starting index
distributing overage filling the rest of the pattern
|
java.lang.Object |
clone()
Clone this object
|
double[] |
computeAdjustedPattern(double[] pattern,
double targetValue,
double preValue,
double postValue,
int adjustmentType,
int istep) |
double |
computePatternValueForStep(RunTimeStep rts,
int requiredInterval,
int period,
int startDayOfWeek,
double[] patmax,
double[] patmin,
double totalVol,
double remainVol,
int ipatStart)
Computes the required value (energy or flow volume) required by the pattern for the given RunTimeStep.
|
double[][] |
computePowerGenPattern(RunTimeStep rts,
double powerReq,
int computeType,
int startOfWeek,
int dayWeekBelongsTo,
double maxCap,
double overUnderPower,
double shouldHaveBeenComputed,
int periodToSatisfy,
int dayOfPeriodSatisfyStart)
Computes a power pattern that satisfies the given energy requirement.
|
void |
fillPatternTS(RunTimeWindow rtw,
double[] tsarray)
fill the given double array from the pattern
|
void |
fillPatternTSByLocal(RunTimeWindow rtw,
double[] tsarray) |
java.lang.Object |
getFieldObject(java.lang.reflect.Field fld)
This method allows access to java.lang.reflect.Field objects within the implementing
class.
|
SystemPwrGenerationPattern |
getGenPatternForDay(HecTime htime) |
double[] |
getPattern(RunTimeStep rts,
int requiredInterval,
int startDayOfWeek)
develops the specific pattern for the given time step and requirement interval
|
boolean |
getPatternForDay(HecTime htime,
double[] daypattern)
fills the given double array with the pattern factors for the given day
|
java.util.Map |
getPowerGenerationTable() |
java.lang.String[] |
getPwrGenPaternDates()
Returns the set of dates that a power generation pattern is entered for.
|
SystemPwrGenerationPattern |
getPwrGenPattern(java.lang.String key)
Returns a SystemPwrGenerationPattern that containes the information for a speicific power generation.
|
int[] |
getPwrGenPatternTimes() |
boolean |
isSystemPwrGenarationPatternSeasonal() |
void |
outputReport(hec.rss.model.reports.AlternativeInputReport report,
org.jdom.Element elem)
Alternative Input Report Interface for data.
|
static void |
scalePattern(double[] pattern,
double reqval,
int istart,
int inum,
double[] patmax,
double[] patmin)
adjust part of a base pattern to meet a total requirement by the "scaling"
method give restrictions of max and min values.
|
boolean |
setFieldObject(java.lang.reflect.Field fld,
java.lang.Object fobj)
This allows access to fields withing the implementing object to set there data.
|
void |
setPwrGenPattern(java.lang.String date,
SystemPwrGenerationPattern pattern)
Sets a specific power generation pattern for a given date.
|
void |
setResIds(int[] reservoirIndexArray) |
void |
setResPatternContainer(java.util.Hashtable<java.lang.Object,PowerGenerationPatternContainer> resPatternTable) |
void |
setSystemPwrGenearationPatternSeasonal(boolean b) |
void |
setUseLocalGeneration(boolean b) |
public void setUseLocalGeneration(boolean b)
public void setResIds(int[] reservoirIndexArray)
public void setResPatternContainer(java.util.Hashtable<java.lang.Object,PowerGenerationPatternContainer> resPatternTable)
public void fillPatternTSByLocal(RunTimeWindow rtw, double[] tsarray)
public void fillPatternTS(RunTimeWindow rtw, double[] tsarray)
rtw - tsarray - public void setPwrGenPattern(java.lang.String date,
SystemPwrGenerationPattern pattern)
date - the seasonal date to apply the power generation patternpattern - the specific power generation pattern.public void clearPwrGenPatterns()
public java.util.Map getPowerGenerationTable()
public java.lang.String[] getPwrGenPaternDates()
public int[] getPwrGenPatternTimes()
public SystemPwrGenerationPattern getPwrGenPattern(java.lang.String key)
key - is of the form 01JAN i.e. DDMMMpublic boolean isSystemPwrGenarationPatternSeasonal()
public void setSystemPwrGenearationPatternSeasonal(boolean b)
public SystemPwrGenerationPattern getGenPatternForDay(HecTime htime)
public boolean getPatternForDay(HecTime htime, double[] daypattern)
htime - HecTime representing the daydaypattern - a double array of size 24public double[][] computePowerGenPattern(RunTimeStep rts, double powerReq, int computeType, int startOfWeek, int dayWeekBelongsTo, double maxCap, double overUnderPower, double shouldHaveBeenComputed, int periodToSatisfy, int dayOfPeriodSatisfyStart)
rts - the current time step that gives the current date. Used to find the correct
seasonal pattern of the patterns are seasonal. Also, the day is used if the pattern
differentiates between days,weeks, or week days/ends.enerygReq - the required enery to fullfill.int - computeType tells the duration of the energyReq, i.e. that pattern must statisfy
the energy req over a month of time.
Valid values are PowerGenerationOptions.REQ_SPECIFIED_DAILY,..._WEEKLY,or ..._MONTHLYdouble - maxCappublic double computePatternValueForStep(RunTimeStep rts, int requiredInterval, int period, int startDayOfWeek, double[] patmax, double[] patmin, double totalVol, double remainVol, int ipatStart)
rts - public static void scalePattern(double[] pattern,
double reqval,
int istart,
int inum,
double[] patmax,
double[] patmin)
pattern - base - istart - public static void clipPatternToMax(double[] pattern,
double[] patmax,
int istart,
int inum,
double reqval)
pattern - patmax - istart - public double[] computeAdjustedPattern(double[] pattern,
double targetValue,
double preValue,
double postValue,
int adjustmentType,
int istep)
public double[] getPattern(RunTimeStep rts, int requiredInterval, int startDayOfWeek)
rts - current time steprequiredInterval - GENERATION_PERIOD_DAILY or GENERATION_PERIOD_WEEKLYpublic java.lang.Object clone()
clone in class java.lang.Objectpublic java.lang.Object getFieldObject(java.lang.reflect.Field fld)
FieldAccessorgetFieldObject in interface FieldAccessorfld - The field to get.public boolean setFieldObject(java.lang.reflect.Field fld,
java.lang.Object fobj)
FieldAccessorsetFieldObject in interface FieldAccessorfld - The java field object representing the member field to be setfobj - The data to set in that fieldpublic void outputReport(hec.rss.model.reports.AlternativeInputReport report,
org.jdom.Element elem)
hec.rss.model.reports.AltInputReportInfcoutputReport in interface hec.rss.model.reports.AltInputReportInfc