aim4.noise

## Class UniformProportionalNoiseFunction

- java.lang.Object
- - aim4.noise.UniformProportionalNoiseFunction

- All Implemented Interfaces:
    NoiseFunction

      public class UniformProportionalNoiseFunction
      extends Object
      implements NoiseFunction

  NoiseFunction that adds noise uniformly within a fixed proportion of the true value.

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `UniformProportionalNoiseFunction(double proportion)` Class constructor.

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `double` | `apply(double trueValue)` Apply the noise function to the given value.

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

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

- - ### Constructor Detail

    - #### UniformProportionalNoiseFunction

          public UniformProportionalNoiseFunction(double proportion)

      Class constructor.
      Parameters:
        `proportion` - the proportion of the true value to use as bounds for the noise function.

  - ### Method Detail

    - #### apply

          public double apply(double trueValue)

      Apply the noise function to the given value.
      Specified by:
        `apply` in interface `NoiseFunction`
      Parameters:
        `trueValue` - the actual value of the quantity.
      Returns:
        the value of the quantity with noise added.

Copyright © 2013. All rights reserved.