Documentation of 'cern.colt.matrix.tfloat.FloatFactory3D' Java class
FloatFactory3D
cern.colt.matrix.tfloat

Class FloatFactory3D

  • All Implemented Interfaces:
    java.io.Serializable, java.lang.Cloneable


    public class FloatFactory3D
    extends PersistentObject
    Factory for convenient construction of 3-d matrices holding float cells. Use idioms like FloatFactory3D.dense.make(4,4,4) to construct dense matrices, FloatFactory3D.sparse.make(4,4,4) to construct sparse matrices. If the factory is used frequently it might be useful to streamline the notation. For example by aliasing:
      FloatFactory3D F = FloatFactory3D.dense;
      F.make(4,4,4);
      F.descending(10,20,5);
      F.random(4,4,5);
      ...
     
    See Also:
    Serialized Form
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method and Description
      FloatMatrix3D ascending(int slices, int rows, int columns)
      Constructs a matrix with cells having ascending values.
      FloatMatrix3D descending(int slices, int rows, int columns)
      Constructs a matrix with cells having descending values.
      FloatMatrix3D make(float[][][] values)
      Constructs a matrix with the given cell values.
      FloatMatrix3D make(int slices, int rows, int columns)
      Constructs a matrix with the given shape, each cell initialized with zero.
      FloatMatrix3D make(int slices, int rows, int columns, float initialValue)
      Constructs a matrix with the given shape, each cell initialized with the given value.
      FloatMatrix3D random(int slices, int rows, int columns)
      Constructs a matrix with uniformly distributed values in (0,1) (exclusive).
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • dense

        public static final FloatFactory3D dense
        A factory producing dense matrices.
      • sparse

        public static final FloatFactory3D sparse
        A factory producing sparse matrices.
    • Method Detail

      • ascending

        public FloatMatrix3D ascending(int slices,
                                       int rows,
                                       int columns)
        Constructs a matrix with cells having ascending values. For debugging purposes.
      • descending

        public FloatMatrix3D descending(int slices,
                                        int rows,
                                        int columns)
        Constructs a matrix with cells having descending values. For debugging purposes.
      • make

        public FloatMatrix3D make(float[][][] values)
        Constructs a matrix with the given cell values. values is required to have the form values[slice][row][column] and have exactly the same number of slices, rows and columns as the receiver.

        The values are copied. So subsequent changes in values are not reflected in the matrix, and vice-versa.

        Parameters:
        values - the values to be filled into the cells.
        Returns:
        this (for convenience only).
        Throws:
        java.lang.IllegalArgumentException - if values.length != slices() || for any 0 <= slice < slices(): values[slice].length != rows() .
        java.lang.IllegalArgumentException - if for any 0 <= column < columns(): values[slice][row].length != columns() .
      • make

        public FloatMatrix3D make(int slices,
                                  int rows,
                                  int columns)
        Constructs a matrix with the given shape, each cell initialized with zero.
      • make

        public FloatMatrix3D make(int slices,
                                  int rows,
                                  int columns,
                                  float initialValue)
        Constructs a matrix with the given shape, each cell initialized with the given value.
      • random

        public FloatMatrix3D random(int slices,
                                    int rows,
                                    int columns)
        Constructs a matrix with uniformly distributed values in (0,1) (exclusive).

DMelt 3.0 © DataMelt by jWork.ORG

You see the box below because you did not login.