Documentation of 'org.apache.commons.math3.random.UnitSphereRandomVectorGenerator' Java class
UnitSphereRandomVectorGenerator
org.apache.commons.math3.random

Class UnitSphereRandomVectorGenerator

  • All Implemented Interfaces:
    RandomVectorGenerator


    public class UnitSphereRandomVectorGenerator
    extends java.lang.Object
    implements RandomVectorGenerator
    Generate random vectors isotropically located on the surface of a sphere.
    Since:
    2.1
    • Constructor Detail

      • UnitSphereRandomVectorGenerator

        public UnitSphereRandomVectorGenerator(int dimension,
                                               RandomGenerator rand)
        Parameters:
        dimension - Space dimension.
        rand - RNG for the individual components of the vectors.
      • UnitSphereRandomVectorGenerator

        public UnitSphereRandomVectorGenerator(int dimension)
        Create an object that will use a default RNG (MersenneTwister), in order to generate the individual components.
        Parameters:
        dimension - Space dimension.
    • Method Detail

      • nextVector

        public double[] nextVector()
        Generate a random vector.
        Specified by:
        nextVector in interface RandomVectorGenerator
        Returns:
        a random vector as an array of double.

DMelt 3.0 © DataMelt by jWork.ORG

You see the box below because you did not login.