public class StatNumber extends Object
Constructor and Description |
---|
StatNumber()
Creates a default StatNumber object with a number and error set to 0.0.
|
StatNumber(double num)
Creates a StatNumber object with the specified number and calculates its error.
|
StatNumber(double num,
double err)
Creates a StatNumber object with the specified number and error.
|
Modifier and Type | Method and Description |
---|---|
void |
add(StatNumber num)
Adds two StatNumber objects.
|
void |
divide(StatNumber num)
Divides the current object by the parameter StatNumber
|
double |
error() |
void |
multiply(StatNumber num)
Multiplies the parameter and the current StatNumber
|
double |
number() |
void |
set(double num,
double err)
Sets the number and error of the StatNumber object
|
void |
subtract(StatNumber num)
Subtracts the parameter from the current object
|
public StatNumber()
public StatNumber(double num, double err)
num
- The numbererr
- The errorpublic StatNumber(double num)
num
- What number to store in the StatNumber object.public void set(double num, double err)
num
- What to set the number toerr
- What to set the error topublic double number()
public double error()
public void add(StatNumber num)
num
- The StatNumber to add to this object.public void divide(StatNumber num)
num
- The StatNumber to divide this object bypublic void multiply(StatNumber num)
num
- The StatNumber object to multiply this object bypublic void subtract(StatNumber num)
num
- The StatNumber to subtract from the current StatNumber objectJas4pp 1.5 © Java Analysis Studio for Particle Physics