de.fu_berlin.ties.util
Class MathUtils

java.lang.Object
  extended by de.fu_berlin.ties.util.MathUtils

public final class MathUtils
extends Object

A static class that provides some mathematical utility methods. No instances of this class can be created, only the static members should be used.

Version:
$Revision: 1.6 $, $Date: 2006/10/21 16:04:27 $, $Author: siefkes $
Author:
Christian Siefkes

Method Summary
static double mean(double[] values)
          Returns the arithmetic mean of an array of values.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

mean

public static double mean(double[] values)
Returns the arithmetic mean of an array of values.

Parameters:
values - the values to use
Returns:
the arithmetic mean of the values; or NaN (Not-a-Number) if the array is empty or at least one value is NaN


Copyright © 2003-2007 Christian Siefkes. All Rights Reserved.