public class MonotonicityConcept extends MapTypeInfiniteConcept<Concept>
(x <= Concept1) ? Bottom :
(y <= Concept2) ? Top :
Concept1
may have a monotonicity that is monotonic with respect to the
variable x, but antimonotonic with respect to y (and constant
with respect to all other variables).
This class represents exactly such concepts, representing them as
{x = Monotonic, y = Animonotonic}, in a manner and syntax
similar to records of the Ptolemy II type system. In records,
however, accessing an undefined tag is an error, whereas in
expressions, they are simply constant with respect to any
variables that are not free.Red (blickly) |
Red (blickly) |
Entity.ContainedObjectsIterator
isAcceptable
_changeListeners, _changeLock, _changeRequests, _debugging, _debugListeners, _deferChangeRequests, _elementName, _isPersistent, _verbose, _workspace, ATTRIBUTES, CLASSNAME, COMPLETE, CONTENTS, DEEP, FULLNAME, LINKS
Modifier | Constructor and Description |
---|---|
protected |
MonotonicityConcept(Ontology ontology)
Create a new Monotonicity concept, belonging to the given
ontology.
|
Modifier and Type | Method and Description |
---|---|
int |
compare(Concept concept)
Compare this concept with the given concept.
|
static MonotonicityConcept |
createMonotonicityConcept(Ontology ontology)
Create a new monotonicity concept, belonging to the given
ontology, with an automatically generated name.
|
ColorAttribute |
getColor()
Return the correct color for this monotonicity concept by looking
at the color of the finite monotonicity representative.
|
Concept |
getMonotonicity(java.lang.String variableName)
Get the monotonicity of this concept with respect to a specific
variable.
|
Concept |
greatestLowerBound(Concept concept)
Compute the greatest lower bound (GLB) of this and another concept.
|
Concept |
leastUpperBound(Concept concept)
Compute the least upper bound (LUB) of this and another concept.
|
void |
putMonotonicity(java.lang.String variable,
Concept monotonicity)
Set the monotonicity of this concept with respect to a specific
variable.
|
_combinedKeys, _commonKeys, _values, equals, getConcept, hashCode, keySet, putConcept, toString
getRepresentative
getAssociatedObject, getOntology, getValue, getVariables, initialize, isAboveOrEqualTo, isSettable, isValueAcceptable, setValue
_adjustDeferrals, _checkContainer, _getContainedObject, _propagateExistence, clone, getContainer, instantiate, isAtomic, isOpaque, moveDown, moveToFirst, moveToIndex, moveToLast, moveUp, newPort, propagateExistence, setContainer, setName
_addPort, _description, _exportMoMLContents, _removePort, _validateSettables, connectedPortList, connectedPorts, connectionsChanged, containedObjectsIterator, getAttribute, getPort, getPorts, linkedRelationList, linkedRelations, portList, removeAllPorts, setClassDefinition, uniqueName
_setParent, exportMoML, getChildren, getElementName, getParent, getPrototypeList, isClassDefinition, isWithinClassDefinition
_addAttribute, _adjustOverride, _attachText, _cloneFixAttributeFields, _containedDecorators, _copyChangeRequestList, _debug, _debug, _debug, _debug, _debug, _executeChangeRequests, _getIndentPrefix, _isMoMLSuppressed, _markContentsDerived, _notifyHierarchyListenersAfterChange, _notifyHierarchyListenersBeforeChange, _propagateValue, _removeAttribute, _splitName, _stripNumericSuffix, addChangeListener, addDebugListener, addHierarchyListener, attributeChanged, attributeDeleted, attributeList, attributeList, attributeTypeChanged, clone, decorators, deepContains, depthInHierarchy, description, description, event, executeChangeRequests, exportMoML, exportMoML, exportMoML, exportMoML, exportMoMLPlain, getAttribute, getAttributes, getChangeListeners, getClassName, getDecoratorAttribute, getDecoratorAttributes, getDerivedLevel, getDerivedList, getDisplayName, getFullName, getModelErrorHandler, getName, getName, getSource, handleModelError, isDeferringChangeRequests, isOverridden, isPersistent, lazyContainedObjectsIterator, message, notifyOfNameChange, propagateValue, propagateValues, removeAttribute, removeChangeListener, removeDebugListener, removeHierarchyListener, requestChange, setClassName, setDeferringChangeRequests, setDerivedLevel, setDisplayName, setModelErrorHandler, setPersistent, setSource, sortContainedObjects, toplevel, validateSettables, workspace
finalize, getClass, notify, notifyAll, wait, wait, wait
getDerivedLevel, getDerivedList, propagateValue
description, getDisplayName, getFullName, getName, getName
protected MonotonicityConcept(Ontology ontology) throws IllegalActionException, NameDuplicationException
ontology
- The finite ontology to which this belongs.
This should be the 4 element monotonicity lattice if we
are really going to be doing inference on monotonicity
of expressions.NameDuplicationException
- Should never be thrown.IllegalActionException
- If the base class throws it.public static MonotonicityConcept createMonotonicityConcept(Ontology ontology)
ontology
- The finite ontology to which this belongs.
This should be the 4 element monotonicity lattice if we
are really going to be doing inference on monotonicity
of expressions.public int compare(Concept concept) throws IllegalActionException
compare
in class InfiniteConcept
concept
- The concept with which we are comparing.IllegalActionException
- If the specified concept
does not have the same ontology as this one.Concept.isAboveOrEqualTo(ptolemy.data.ontologies.Concept)
public ColorAttribute getColor() throws IllegalActionException
getColor
in class Concept
IllegalActionException
- Thrown if there is an error getting
the color for the finite monotonicity concept.public Concept getMonotonicity(java.lang.String variableName)
variableName
- The variable whose monotonicity we are querying.public Concept greatestLowerBound(Concept concept)
greatestLowerBound
in class InfiniteConcept
concept
- The other concept.public Concept leastUpperBound(Concept concept)
leastUpperBound
in class InfiniteConcept
concept
- The other concept.public void putMonotonicity(java.lang.String variable, Concept monotonicity)
variable
- The variable whose monotonicity we are querying.monotonicity
- The monotonicity of this concept with respect
to the given variable.getMonotonicity(String)