org.encog.mathutil.randomize

## Class GaussianRandomizer

- java.lang.Object
- - org.encog.mathutil.randomize.BasicRandomizer
  - - org.encog.mathutil.randomize.GaussianRandomizer

- All Implemented Interfaces:
    Randomizer

      public class GaussianRandomizer
      extends BasicRandomizer

  Generally, you will not want to use this randomizer as a pure neural network randomizer. More on this later in the description. Generate random numbers that fall within a Gaussian curve. The mean represents the center of the curve, and the standard deviation helps determine the length of the curve on each side. This randomizer is used mainly for special cases where I want to generate random numbers in a Gaussian range. For a pure neural network initializer, it leaves much to be desired. However, it can make for a decent randomizer. Usually, the Nguyen Widrow randomizer performs better. Uses the "Box Muller" method. http://en.wikipedia.org/wiki/Box%E2%80%93Muller_transform Ported from C++ version provided by Everett F. Carter Jr., 1994

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `GaussianRandomizer(double mean, double standardDeviation)` Construct a Gaussian randomizer.

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `double` | `boxMuller(double m, double s)` Compute a Gaussian random number.
    `double` | `randomize(double d)` Generate a random number.

    - ### Methods inherited from class org.encog.mathutil.randomize.BasicRandomizer

      `getRandom, nextDouble, nextDouble, randomize, randomize, randomize, randomize, randomize, randomize, setRandom`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### GaussianRandomizer

          public GaussianRandomizer(double mean,
                            double standardDeviation)

      Construct a Gaussian randomizer. The mean, the standard deviation.
      Parameters:
        `mean` - The mean.
        `standardDeviation` - The standard deviation.

  - ### Method Detail

    - #### boxMuller

          public double boxMuller(double m,
                         double s)

      Compute a Gaussian random number.
      Parameters:
        `m` - The mean.
        `s` - The standard deviation.
      Returns:
        The random number.

    - #### randomize

          public double randomize(double d)

      Generate a random number.
      Parameters:
        `d` - The input value, not used.
      Returns:
        The random number.

Copyright © 2014. All Rights Reserved.