|
SSJ V. labo. |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectumontreal.iro.lecuyer.stat.StatProbe
umontreal.iro.lecuyer.stat.FunctionOfMultipleMeansTally
umontreal.iro.lecuyer.stat.list.lincv.FunctionOfMultipleMeansTallyWithCV
public class FunctionOfMultipleMeansTallyWithCV
Represents a function of multiple means tally for an estimator with linear
control variables. This extends the function of multiple means tally
to use a function
h(μ, ν) = g(μ) - βft(C - ν), where
βf = (βf,…, βf, q-1) is a q-dimensional vector. One
must provide a definition for
g(μ) and its gradient
∇g(μ) through an implementation of the
MultivariateFunction
interface.
Constructor Summary | |
---|---|
FunctionOfMultipleMeansTallyWithCV(MultivariateFunction funcNoCV,
int p,
int q)
Creates a new function of multiple means tally for a function funcNoCV of p variables, and with q control variables. |
|
FunctionOfMultipleMeansTallyWithCV(MultivariateFunction funcNoCV,
ListOfTalliesWithCV<Tally> l)
Constructs a new function of multiple means tally with control variables from the list of tallies l, and the function funcNoCV. |
Method Summary | |
---|---|
FunctionOfMultipleMeansTallyWithCV |
clone()
Clones this object and the function which is stored inside. |
void |
estimateBeta()
Uses the sample averages and covariances obtained from the internal list of tallies to estimate the βf vector minimizing the variance of h(bar(X)n, C). |
void |
estimateBetaFromMatrix(DoubleMatrix2D mbeta)
Multiples the given q×p matrix by the gradient ∇g(bar(X)n) to get an estimate of the βf* vector minimizing the variance. |
double[] |
getBeta()
Returns the βf vector. |
double |
getBeta(int i)
Returns the value of βf, i. |
int |
getDimensionWithoutCV()
Returns the dimension of this tally excluding the control variables. |
double |
getExpectedValue(int i)
Gets the expected value of the ith component of ν. |
double[] |
getExpectedValues()
Gets an array containing the vector ν. |
MultivariateFunction |
getFunctionWithoutCV()
Returns the implementation computing the function g(μ). |
ListOfTalliesWithCV<Tally> |
getListOfTalliesWithCV()
Returns the list of tallies with control variables used by this object. |
int |
getNumControlVariables()
Returns the number of control variables being used. |
void |
setBeta(double[] beta)
Sets the value of βf vector to beta. |
void |
setBeta(int i,
double b)
Sets the value of βf, i. |
void |
setExpectedValue(int i,
double e)
Sets the expected value of the ith component of ν to e. |
void |
setExpectedValues(double[] exp)
Sets the vector ν to to given array exp. |
Methods inherited from class umontreal.iro.lecuyer.stat.FunctionOfMultipleMeansTally |
---|
add, average, confidenceIntervalDelta, formatCIDelta, formatCIDelta, getConfidenceLevel, getDimension, getFunction, getListOfTallies, init, max, min, numberObs, report, reportAndCIDelta, reportAndCIDelta, setConfidenceIntervalDelta, setConfidenceIntervalNone, setConfidenceLevel, setName, setShowNumberObs, shortReport, shortReportHeader, standardDeviation, sum, variance |
Methods inherited from class umontreal.iro.lecuyer.stat.StatProbe |
---|
addObservationListener, clearObservationListeners, getName, isBroadcasting, isCollecting, notifyListeners, removeObservationListener, report, report, setBroadcasting, setCollecting |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public FunctionOfMultipleMeansTallyWithCV(MultivariateFunction funcNoCV, int p, int q)
funcNoCV
- the function used.p
- the number of dimensions.q
- the number of control variables.public FunctionOfMultipleMeansTallyWithCV(MultivariateFunction funcNoCV, ListOfTalliesWithCV<Tally> l)
funcNoCV
- the function being computed.l
- the list of tallies used.Method Detail |
---|
public MultivariateFunction getFunctionWithoutCV()
getFunction
which returns
h(μ, ν).
public int getNumControlVariables()
public int getDimensionWithoutCV()
getDimension
minus
the number of control variables.
public double getBeta(int i)
i
- the index of the control variable.
public void setBeta(int i, double b)
i
- the index of the control variable.b
- the value of βf, i.public double[] getBeta()
public void setBeta(double[] beta)
beta
- the new
βf vector.public ListOfTalliesWithCV<Tally> getListOfTalliesWithCV()
public double getExpectedValue(int i)
i
- the component of ν to query.
public void setExpectedValue(int i, double e)
i
- the component of ν to set.e
- the new value of the expectation.public double[] getExpectedValues()
public void setExpectedValues(double[] exp)
exp
- the new ν vector.public void estimateBeta()
estimateBeta
from the internal list of tallies
to get a β matrix, and calls
estimateBetaFromMatrix
to get
the
βf vector.
public void estimateBetaFromMatrix(DoubleMatrix2D mbeta)
estimateBeta
.
from the internal list of tallies.
mbeta
- the β matrix.public FunctionOfMultipleMeansTallyWithCV clone()
clone
in class FunctionOfMultipleMeansTally
|
SSJ V. labo. |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |