public class MarkovChainMonteCarlo extends Object
Modifier and Type | Field and Description |
---|---|
private MonteCarloAcceptor |
acceptor |
private int |
burnIn |
private MonteCarloResults |
consumer |
private static RNG |
GENERATOR |
private MarkovChainController |
mcController |
private MonteCarloScenario |
model |
private int |
numAcceptedSteps |
private int |
numSimulations |
private int |
numStepsTaken |
private Set<MarkovChainObserver> |
observers |
private MarkovStepGenerator |
pathGenerator |
private int |
thinningInterval |
private FileOutput |
writer |
Constructor and Description |
---|
MarkovChainMonteCarlo(MonteCarloScenario model,
int numSimulations,
MonteCarloResults consumer,
MarkovChainController controller,
MarkovStepGenerator generator)
Create a Monte Carlo instance.
|
MarkovChainMonteCarlo(MonteCarloScenario model,
int numSimulations,
MonteCarloResults consumer,
MarkovStepGenerator generator)
Create a Monte Carlo instance.
|
Modifier and Type | Method and Description |
---|---|
void |
addObserver(MarkovChainObserver observer)
Add an observer to the list of observers.
|
void |
run()
Run the MonteCarlo Simulation.
|
private int numStepsTaken
private int numSimulations
private int numAcceptedSteps
private int burnIn
private int thinningInterval
private MonteCarloAcceptor acceptor
private MarkovChainController mcController
private Set<MarkovChainObserver> observers
private FileOutput writer
private MonteCarloScenario model
private MarkovStepGenerator pathGenerator
private MonteCarloResults consumer
private static final RNG GENERATOR
public MarkovChainMonteCarlo(MonteCarloScenario model, int numSimulations, MonteCarloResults consumer, MarkovStepGenerator generator)
model
- The Monte Carlo Model to be run.numSimulations
- The number of time the Monte Carlo model should be run at each step.consumer
- the object that will consume and aggregate the MC results.generator
- the object that will generate the Monte Carlo chain/path.public MarkovChainMonteCarlo(MonteCarloScenario model, int numSimulations, MonteCarloResults consumer, MarkovChainController controller, MarkovStepGenerator generator)
model
- The Monte Carlo Model to be run.numSimulations
- The number of time the Monte Carlo model should be run at each step.consumer
- the object that will consume and aggregate the MC results.controller
- the controller object for this class.generator
- the object that will generate the Monte Carlo chain/path.public final void run()
public final void addObserver(MarkovChainObserver observer)
observer
- the observer that is used to monitor/take measurements.Copyright © 2015 University of Glasgow. All rights reserved.