Package samer.maths

Class Vec.ForArray

  • java.lang.Object
    • samer.maths.Vec.ForArray
  • All Implemented Interfaces:
    java.io.Serializable, Mat, Vec
    Enclosing interface:
    Vec


    public static class Vec.ForArray
    extends java.lang.Object
    implements Vec, Mat, java.io.Serializable
    An implementation of Vec that uses an array to store the values.
    See Also:
    Serialized Form
    • Nested Class Summary

      • Nested classes/interfaces inherited from interface samer.maths.Vec

        Vec.ForArray
    • Constructor Summary

      Constructors 
      Constructor and Description
      ForArray(double[] a) 
      ForArray(int n) 
    • Constructor Detail

      • ForArray

        public ForArray(double[] a)
      • ForArray

        public ForArray(int n)
    • Method Detail

      • size

        public int size()
        Specified by:
        size in interface Vec
      • array

        public double[] array()
        Specified by:
        array in interface Vec
      • mat

        public Mat mat()
        Specified by:
        mat in interface Vec
      • width

        public int width()
        Specified by:
        width in interface Mat
      • height

        public int height()
        Specified by:
        height in interface Mat
      • get

        public double get(int i,
                          int j)
        Specified by:
        get in interface Mat
      • set

        public void set(int i,
                        int j,
                        double t)
        Specified by:
        set in interface Mat