Package apron

Class Coeff

java.lang.Object
apron.Coeff
All Implemented Interfaces:
Serializable, Cloneable
Direct Known Subclasses:
Interval, Scalar

public abstract class Coeff extends Object implements Cloneable, Serializable
Abstract class of constant coefficients that can appear in expressions.

A coefficient can be either a Scalar real singleton or an Interval set of real values. The Coeff class provides methods to manipulate coefficients independently from the underlying representation.

See Also:
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    abstract int
    Compare this and x for inclusion.
    abstract Coeff
    Creates a copy of the coefficient, of the same kind.
    static Coeff
    Creates a 0 coefficient as a double Scalar.
    boolean
    Whether x is a Coeff has the same value.
    abstract int
    Returns a hash of the value of this.
    abstract Scalar
    inf()
    Returns a reference to the lower bound of this.
    abstract boolean
    isEqual(int i)
    Whether this represents the singleton i.
    abstract boolean
    Whether this equals x.
    abstract boolean
    Whether this represents a singleton.
    abstract boolean
    Whether this represents the singleton 0.
    abstract void
    neg()
    Negates this.
    abstract Scalar
    sup()
    Returns a reference to the upper bound of this.
    abstract String
    Returns a string representation of this.

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • Coeff

      public Coeff()
  • Method Details

    • create

      public static Coeff create()
      Creates a 0 coefficient as a double Scalar.
    • copy

      public abstract Coeff copy()
      Creates a copy of the coefficient, of the same kind.
    • inf

      public abstract Scalar inf()
      Returns a reference to the lower bound of this.
    • sup

      public abstract Scalar sup()
      Returns a reference to the upper bound of this.
    • toString

      public abstract String toString()
      Returns a string representation of this.
      Overrides:
      toString in class Object
    • hashCode

      public abstract int hashCode()
      Returns a hash of the value of this.
      Overrides:
      hashCode in class Object
    • isZero

      public abstract boolean isZero()
      Whether this represents the singleton 0.
    • isScalar

      public abstract boolean isScalar()
      Whether this represents a singleton.
    • isEqual

      public abstract boolean isEqual(int i)
      Whether this represents the singleton i.
    • isEqual

      public abstract boolean isEqual(Coeff x)
      Whether this equals x.
    • cmp

      public abstract int cmp(Coeff x)
      Compare this and x for inclusion.
      See Also:
    • neg

      public abstract void neg()
      Negates this.
    • equals

      public boolean equals(Object x)
      Whether x is a Coeff has the same value.
      Overrides:
      equals in class Object