All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class sdsu.algorithms.data.Poisson

java.lang.Object
   |
   +----sdsu.algorithms.data.ProbabilityDistribution
           |
           +----sdsu.algorithms.data.DiscreteProbability
                   |
                   +----sdsu.algorithms.data.Poisson

public class Poisson
extends DiscreteProbability
The Poisson distrubution addresses the question of how many events occur in a unit of time or space. This class is adapted from Smalltalk-80: The language and Its Implementation, Goldberg & Robson, Addison-Wesley, 1983, chapter 21, pages 417-438.

Version:
1.0 10 June 1997
Author:
Roger Whitney (whitney@cs.sdsu.edu)

Constructor Index

 o Poisson(double)
Returns a Poisson distribution object.

Method Index

 o density(double)
Returns the probability that numberOfEvents will occur in one unit (time, space).
 o mean()
Returns the mean of the distribution
 o nextElement()
Returns the number events that occur in simualtion of one unit (of time or space).
 o variance()
Returns the variance of the probability distribution

Constructors

 o Poisson
 public Poisson(double averageEvents) throws OutOfBoundsException
Returns a Poisson distribution object.

Parameters:
averageEvents - the averate number of events happening per unit (time, space).
Throws: OutOfBoundsException
thrown if averageEvents is not greater than 0.0.

Methods

 o density
 public double density(double numberOfEvents)
Returns the probability that numberOfEvents will occur in one unit (time, space).

Parameters:
numberOfEvents - does not make sense unless is integer value.
Overrides:
density in class ProbabilityDistribution
 o mean
 public double mean()
Returns the mean of the distribution

Overrides:
mean in class ProbabilityDistribution
 o variance
 public double variance()
Returns the variance of the probability distribution

Overrides:
variance in class ProbabilityDistribution
 o nextElement
 public double nextElement()
Returns the number events that occur in simualtion of one unit (of time or space).

Overrides:
nextElement in class ProbabilityDistribution

All Packages  Class Hierarchy  This Package  Previous  Next  Index