Enum DependentVectorsHandler

java.lang.Object
java.lang.Enum<DependentVectorsHandler>
org.hipparchus.linear.DependentVectorsHandler
All Implemented Interfaces:
Serializable, Comparable<DependentVectorsHandler>, java.lang.constant.Constable

public enum DependentVectorsHandler extends Enum<DependentVectorsHandler>
Since:
2.1
  • Enum Constant Details

    • GENERATE_EXCEPTION

      public static final DependentVectorsHandler GENERATE_EXCEPTION
      Generate a MathIllegalArgumentException if dependent vectors are found.
    • ADD_ZERO_VECTOR

      public static final DependentVectorsHandler ADD_ZERO_VECTOR
      Replace dependent vectors by vectors with norm 0.

      This behavior matches the Wolfram language API. It keeps the number of output vectors equal to the number of input vectors. The only two norms output vectors can have are 0 and 1.

    • REDUCE_BASE_TO_SPAN

      public static final DependentVectorsHandler REDUCE_BASE_TO_SPAN
      Ignore dependent vectors.

      This behavior ensures the output vectors form an orthonormal basis, i.e. all vectors are independent and they all have norm 1. The number of output vectors may be smaller than the number of input vectors, this number corresponds to the dimension of the span of the input vectors.

  • Method Details

    • values

      public static DependentVectorsHandler[] values()
      Returns an array containing the constants of this enum type, in the order they are declared.
      Returns:
      an array containing the constants of this enum type, in the order they are declared
    • valueOf

      public static DependentVectorsHandler valueOf(String name)
      Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum type has no constant with the specified name
      NullPointerException - if the argument is null
    • manageDependent

      public abstract int manageDependent(int index, List<RealVector> basis)
      Manage a dependent vector.
      Parameters:
      index - of the vector in the basis
      basis - placeholder for basis vectors
      Returns:
      next index to manage
    • manageDependent

      public abstract <T extends CalculusFieldElement<T>> int manageDependent(Field<T> field, int index, List<FieldVector<T>> basis)
      Manage a dependent vector.
      Type Parameters:
      T - type of the vectors components
      Parameters:
      field - field to which the vectors belong
      index - of the vector in the basis
      basis - placeholder for basis vectors
      Returns:
      next index to manage