public class IntervalsFunction extends Parameterizable implements IParamDiffFunction
AbsoluteDateInterval and IParamDiffFunction.
Note that this function is not defined on dates outside of its intervals.
Each function parameters descriptor is enriched with a StandardFieldDescriptors.DATE_INTERVAL corresponding
to the interval where the parameter is defined.
| Constructor and Description |
|---|
IntervalsFunction(Collection<IParamDiffFunction> functionsCollection,
Collection<AbsoluteDateInterval> intervalsCollection)
|
IntervalsFunction(Collection<IParamDiffFunction> functionsCollection,
Collection<AbsoluteDateInterval> intervalsCollection,
boolean updateParamDescriptors)
|
IntervalsFunction(Map<AbsoluteDateInterval,IParamDiffFunction> mapOfFunctions)
Simple constructor to initialize directly the map of intervals and functions.
|
IntervalsFunction(Map<AbsoluteDateInterval,IParamDiffFunction> mapOfFunctions,
boolean updateParamDescriptors)
Simple constructor to initialize directly the map of intervals and functions.
|
| Modifier and Type | Method and Description |
|---|---|
double |
derivativeValue(Parameter p,
SpacecraftState s)
Compute the derivative value with respect to the input parameter.
|
CacheEntry<AbsoluteDateInterval,IParamDiffFunction> |
getEntry(AbsoluteDate date)
|
CacheEntry<AbsoluteDateInterval,IParamDiffFunction> |
getEntry(AbsoluteDate date,
boolean throwException)
|
List<IParamDiffFunction> |
getFunctions()
Getter for the functions associated to the
intervals. |
Map<AbsoluteDateInterval,IParamDiffFunction> |
getIntervalFunctionAssociation()
Getter for the association between
intervals and functions. |
AbsoluteDateIntervalsList |
getIntervals()
Getter for the available intervals.
|
boolean |
isDifferentiableBy(Parameter p)
Tell if the function is differentiable by the given parameter.
|
String |
toString()
Getter for a String representation of this function.
|
double |
value(SpacecraftState s)
Getting the value of the function.
|
addAllParameters, addAllParameters, addParameter, getParameters, supportsParameterclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitgetParameters, supportsParameterpublic IntervalsFunction(Collection<IParamDiffFunction> functionsCollection, Collection<AbsoluteDateInterval> intervalsCollection)
functions and a collection of
intervals. Both collections should be the same size. They define each
sub-function to apply on each interval. The intervals must not overlap with each other.
Each function parameters descriptor is updated with a StandardFieldDescriptors.DATE_INTERVAL
corresponding to the interval where the parameter is defined.
functionsCollection - Collection of functionsintervalsCollection - Collection of intervalsDimensionMismatchException - if intervalsCollection.size() != functionsCollection.size()IllegalArgumentException - if some intervals from the specified collection overlap with each othernullpublic IntervalsFunction(Collection<IParamDiffFunction> functionsCollection, Collection<AbsoluteDateInterval> intervalsCollection, boolean updateParamDescriptors)
functions and a collection of
intervals. Both collections should be the same size. They define each
sub-function to apply on each interval. The intervals must not overlap with each other.functionsCollection - Collection of functionsintervalsCollection - Collection of intervalsupdateParamDescriptors - Indicate if parameters descriptor should be updated with a StandardFieldDescriptors.DATE_INTERVAL
corresponding to the interval where the parameter is defined.DimensionMismatchException - if intervalsCollection.size() != functionsCollection.size()IllegalArgumentException - if some intervals from the specified collection overlap with each othernullpublic IntervalsFunction(Map<AbsoluteDateInterval,IParamDiffFunction> mapOfFunctions)
Each function parameters descriptor is enriched with a StandardFieldDescriptors.DATE_INTERVAL
corresponding to the interval where the parameter is defined.
Note: the given map is stored with a shallow copy.
mapOfFunctions - Map of intervals and functions. Note that the map is not duplicated internally.IllegalArgumentException - if some intervals from the specified map overlap with each othernullNullArgumentException - if mapOfFunctions is nullpublic IntervalsFunction(Map<AbsoluteDateInterval,IParamDiffFunction> mapOfFunctions, boolean updateParamDescriptors)
Note: the given map is stored with a shallow copy.
mapOfFunctions - Map of intervals and functions. Note that the map is not duplicated internally.updateParamDescriptors - Indicate if parameters descriptor should be updated with a StandardFieldDescriptors.DATE_INTERVAL
corresponding to the interval where the parameter is defined.IllegalArgumentException - if some intervals from the specified map overlap with each othernullNullArgumentException - if mapOfFunctions is nullpublic double value(SpacecraftState s)
value in interface IParameterizableFunctions - the spacecraft stateIllegalStateException - if the provided date does not belong to any of the intervalspublic double derivativeValue(Parameter p, SpacecraftState s)
derivativeValue in interface IParamDiffFunctionp - parameters - current stateIllegalStateException - if the provided date does not belong to any of the intervalspublic boolean isDifferentiableBy(Parameter p)
isDifferentiableBy in interface IParamDiffFunctionp - function parameterpublic AbsoluteDateIntervalsList getIntervals()
public List<IParamDiffFunction> getFunctions()
intervals.public Map<AbsoluteDateInterval,IParamDiffFunction> getIntervalFunctionAssociation()
intervals and functions.public CacheEntry<AbsoluteDateInterval,IParamDiffFunction> getEntry(AbsoluteDate date)
entry <interval, function> associated to the provided date.date - date for which we want the corresponding association interval/functioninterval in which the given date is
includedIllegalStateException - if the provided date does not belong to any of the intervalspublic CacheEntry<AbsoluteDateInterval,IParamDiffFunction> getEntry(AbsoluteDate date, boolean throwException)
date - date for which we want the corresponding association interval/functionthrowException - if true an exception is raised if there is no match; if false a null is returned if
there is no matchinterval in which the given date is
includedIllegalStateException - if throwException == true and the provided date does not belong to any of
the
intervalsCopyright © 2025 CNES. All rights reserved.