Class VecBuilder<N extends Num>

java.lang.Object
edu.wpi.first.math.MatBuilder<N,​N1>
edu.wpi.first.math.VecBuilder<N>
Type Parameters:
N - The dimension of the vector to be constructed.

public class VecBuilder<N extends Num>
extends MatBuilder<N,​N1>
A specialization of MatBuilder for constructing vectors (Nx1 matrices).
  • Constructor Summary

    Constructors 
    Constructor Description
    VecBuilder​(Nat<N> rows)  
  • Method Summary

    Modifier and Type Method Description
    static Vector<N1> fill​(double n1)
    Returns a 1x1 vector containing the given elements.
    static Vector<N2> fill​(double n1, double n2)
    Returns a 2x1 vector containing the given elements.
    static Vector<N3> fill​(double n1, double n2, double n3)
    Returns a 3x1 vector containing the given elements.
    static Vector<N4> fill​(double n1, double n2, double n3, double n4)
    Returns a 4x1 vector containing the given elements.
    static Vector<N5> fill​(double n1, double n2, double n3, double n4, double n5)
    Returns a 5x1 vector containing the given elements.
    static Vector<N6> fill​(double n1, double n2, double n3, double n4, double n5, double n6)
    Returns a 6x1 vector containing the given elements.
    static Vector<N7> fill​(double n1, double n2, double n3, double n4, double n5, double n6, double n7)
    Returns a 7x1 vector containing the given elements.
    static Vector<N8> fill​(double n1, double n2, double n3, double n4, double n5, double n6, double n7, double n8)
    Returns a 8x1 vector containing the given elements.
    static Vector<N9> fill​(double n1, double n2, double n3, double n4, double n5, double n6, double n7, double n8, double n9)
    Returns a 9x1 vector containing the given elements.
    static Vector<N10> fill​(double n1, double n2, double n3, double n4, double n5, double n6, double n7, double n8, double n9, double n10)
    Returns a 10x1 vector containing the given elements.

    Methods inherited from class edu.wpi.first.math.MatBuilder

    fill

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

  • Method Details

    • fill

      public static Vector<N1> fill​(double n1)
      Returns a 1x1 vector containing the given elements.
      Parameters:
      n1 - the first element.
      Returns:
      1x1 vector
    • fill

      public static Vector<N2> fill​(double n1, double n2)
      Returns a 2x1 vector containing the given elements.
      Parameters:
      n1 - the first element.
      n2 - the second element.
      Returns:
      2x1 vector
    • fill

      public static Vector<N3> fill​(double n1, double n2, double n3)
      Returns a 3x1 vector containing the given elements.
      Parameters:
      n1 - the first element.
      n2 - the second element.
      n3 - the third element.
      Returns:
      3x1 vector
    • fill

      public static Vector<N4> fill​(double n1, double n2, double n3, double n4)
      Returns a 4x1 vector containing the given elements.
      Parameters:
      n1 - the first element.
      n2 - the second element.
      n3 - the third element.
      n4 - the fourth element.
      Returns:
      4x1 vector
    • fill

      public static Vector<N5> fill​(double n1, double n2, double n3, double n4, double n5)
      Returns a 5x1 vector containing the given elements.
      Parameters:
      n1 - the first element.
      n2 - the second element.
      n3 - the third element.
      n4 - the fourth element.
      n5 - the fifth element.
      Returns:
      5x1 vector
    • fill

      public static Vector<N6> fill​(double n1, double n2, double n3, double n4, double n5, double n6)
      Returns a 6x1 vector containing the given elements.
      Parameters:
      n1 - the first element.
      n2 - the second element.
      n3 - the third element.
      n4 - the fourth element.
      n5 - the fifth element.
      n6 - the sixth element.
      Returns:
      6x1 vector
    • fill

      public static Vector<N7> fill​(double n1, double n2, double n3, double n4, double n5, double n6, double n7)
      Returns a 7x1 vector containing the given elements.
      Parameters:
      n1 - the first element.
      n2 - the second element.
      n3 - the third element.
      n4 - the fourth element.
      n5 - the fifth element.
      n6 - the sixth element.
      n7 - the seventh element.
      Returns:
      7x1 vector
    • fill

      public static Vector<N8> fill​(double n1, double n2, double n3, double n4, double n5, double n6, double n7, double n8)
      Returns a 8x1 vector containing the given elements.
      Parameters:
      n1 - the first element.
      n2 - the second element.
      n3 - the third element.
      n4 - the fourth element.
      n5 - the fifth element.
      n6 - the sixth element.
      n7 - the seventh element.
      n8 - the eighth element.
      Returns:
      8x1 vector
    • fill

      public static Vector<N9> fill​(double n1, double n2, double n3, double n4, double n5, double n6, double n7, double n8, double n9)
      Returns a 9x1 vector containing the given elements.
      Parameters:
      n1 - the first element.
      n2 - the second element.
      n3 - the third element.
      n4 - the fourth element.
      n5 - the fifth element.
      n6 - the sixth element.
      n7 - the seventh element.
      n8 - the eighth element.
      n9 - the ninth element.
      Returns:
      9x1 vector
    • fill

      public static Vector<N10> fill​(double n1, double n2, double n3, double n4, double n5, double n6, double n7, double n8, double n9, double n10)
      Returns a 10x1 vector containing the given elements.
      Parameters:
      n1 - the first element.
      n2 - the second element.
      n3 - the third element.
      n4 - the fourth element.
      n5 - the fifth element.
      n6 - the sixth element.
      n7 - the seventh element.
      n8 - the eighth element.
      n9 - the ninth element.
      n10 - the tenth element.
      Returns:
      10x1 vector