public class TerminalMerit extends AbstractMerit implements EndpointDefining
KEY_WIDTH (σ)
parameter, while the
terminal point, at which the timeslot has fallen to half of its value, is
defined with KEY_T0 (t0). The overall weight of the merit, i.e. its
scaling between zero and one, is defined in KEY_WEIGHT (k).
The drop
is modeled on top of a tanh function. The default value of
KEY_TANHSTRETCH (s)
is almost always sufficient. Different time paramters can be used, the
default is julian date. The formula used in the
region stretching from t0-σ to t0+σ reads as follows
ts(t) = k·½(1-tanh(s·(t-t0)/σ))Outside this region, the merit is k or zero. This merit is
EndpointDefining.| Modifier and Type | Field and Description |
|---|---|
private static double |
DEFTANHSTRETCH
The default stretch factor in the tanh-transition region.
|
private static String |
DEFTIME
Default remaining night-time parameter name.
|
private static double |
DEFWEIGHT
Default value for the weight.
|
private static double |
DEFWIDTH
Default half-width of the transition region.
|
static String |
KEY_T0
The terminal time, in the middle of the drop-to-zero intervall.
|
static String |
KEY_TANHSTRETCH
The key linked to the stretch of the tanh in the drop phase.
|
static String |
KEY_TIME
The name of the time parameter used.
|
static String |
KEY_WEIGHT
The key linked to the weight of the terminal merit.
|
static String |
KEY_WIDTH
Half of the time it takes the merit to drop to zero.
|
KEY_LISTSEPARATOR, KEY_MAPKEYVALUECHAR, KEY_MAPSEPARATORCONFIG, KEY_CLASS| Constructor and Description |
|---|
TerminalMerit(Map prop)
Constructs a new window merit using only default weights and impacts.
|
| Modifier and Type | Method and Description |
|---|---|
double |
getMerit(GlobalGrouping set,
Appointable target,
Collection ignore,
long dummy)
Calculates the terminal merit.
|
boolean |
isCompleted(GlobalGrouping set,
Appointable target)
Test, if this target is completed.
|
createMerit, getInitializer, initMeritaugment, augment, augment, augment, augment, clone, defaultBoolean, defaultChar, defaultDouble, defaultFloat, defaultInt, defaultLong, defaultObject, defaultObject, defaultProperties, defaultProperty, getAsBoolean, getAsChar, getAsDouble, getAsEnums, getAsFloat, getAsInt, getAsList, getAsLong, getAsMap, getAsMap, getAsObject, getAsObject, getProperties, getProperty, has, initProperties, isNew, parseObject, parseObject, reload, reload, removeProperty, requires, rescanned, setObject, setProperties, setProperty, stringProperties, toStringpublic static final String KEY_WEIGHT
public static final String KEY_WIDTH
public static final String KEY_T0
public static final String KEY_TANHSTRETCH
public static final String KEY_TIME
private static final double DEFWEIGHT
private static final double DEFWIDTH
private static final double DEFTANHSTRETCH
private static final String DEFTIME
public TerminalMerit(Map prop)
AbstractMerit.createMerit(java.util.Map<java.lang.String, java.lang.String>)
method. This create method also takes care of proper parameter
overloading.public double getMerit(GlobalGrouping set, Appointable target, Collection ignore, long dummy)
public boolean isCompleted(GlobalGrouping set, Appointable target)
isCompleted in interface EndpointDefining