Class Smooth_Composite

java.lang.Object
de.tilman_neumann.jml.factor.base.congruence.Smooth_Composite
All Implemented Interfaces:
Smooth

public class Smooth_Composite
extends java.lang.Object
implements Smooth
A smooth congruence composed from several partials.
  • Constructor Summary

    Constructors
    Constructor Description
    Smooth_Composite​(java.util.Set<? extends AQPair> aqPairs)
    Constructor from several AQ-pairs.
  • Method Summary

    Modifier and Type Method Description
    void addMyAQPairsViaXor​(java.util.Set<AQPair> targetSet)
    Add this's AQPairs to the target set via xor.
    boolean equals​(java.lang.Object o)
    Checks if this composite smooth relation is equal to another object.
    Simple smooths (having exactly one AQPair) and composite smooths (having strictly more than one AQPair) can never be equal; hence it is correct to have two separate equals() implementations that reject all objects of the other type.
    java.util.Set<AQPair> getAQPairs()  
    java.lang.Integer[] getMatrixElements()  
    int hashCode()  
    boolean isExactSquare()
    Test if the Q of this smooth congruence is an exact square.
    java.lang.String toString()  

    Methods inherited from class java.lang.Object

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

    • Smooth_Composite

      public Smooth_Composite​(java.util.Set<? extends AQPair> aqPairs)
      Constructor from several AQ-pairs.
      Parameters:
      aqPairs -
  • Method Details

    • getAQPairs

      public java.util.Set<AQPair> getAQPairs()
      Specified by:
      getAQPairs in interface Smooth
      Returns:
      the set of AQPairs this smooth relation consists of
    • addMyAQPairsViaXor

      public void addMyAQPairsViaXor​(java.util.Set<AQPair> targetSet)
      Description copied from interface: Smooth
      Add this's AQPairs to the target set via xor. This operation permits to get around without creating new array objects for all those congruence sub-classes that represent just a single AQPair.
      Specified by:
      addMyAQPairsViaXor in interface Smooth
    • getMatrixElements

      public java.lang.Integer[] getMatrixElements()
      Specified by:
      getMatrixElements in interface Smooth
      Returns:
      set matrix elements. For a smooth relation these are the small factors appearing with odd exponent.
    • isExactSquare

      public boolean isExactSquare()
      Description copied from interface: Smooth
      Test if the Q of this smooth congruence is an exact square. Since smooth congruences can not have non-square large Q-factors, only the small Q-factors need to be checked.
      Specified by:
      isExactSquare in interface Smooth
      Returns:
      true if Q is square
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class java.lang.Object
    • equals

      public boolean equals​(java.lang.Object o)
      Checks if this composite smooth relation is equal to another object.
      Simple smooths (having exactly one AQPair) and composite smooths (having strictly more than one AQPair) can never be equal; hence it is correct to have two separate equals() implementations that reject all objects of the other type.
      Overrides:
      equals in class java.lang.Object
    • toString

      public java.lang.String toString()
      Overrides:
      toString in class java.lang.Object