22 #ifndef SGSOLVERWORKER_V2_HPP
23 #define SGSOLVERWORKER_V2_HPP
27 #include "sgsolver_maxminmax.hpp"
79 QTextEdit * _logTextEdit):
118 catch (exception & e)
121 qDebug() <<
"solve failed" << endl;
const SGSolution_MaxMinMax & getSolution() const
Definition: sgsolver_maxminmax.hpp:191
double getParam(SG::DBL_PARAM param) const
Method for getting double parameters.
Definition: sgenv.cpp:96
enum SGSolverWorker::STATUS status
SGSolver_MaxMinMax solver
The main object for performing calculations.
Definition: sgsolverworker.hpp:54
Class for implementing the twist algorithm within SGViewer.
Definition: sgsolverworker.hpp:47
Describes a stochastic game.
Definition: sggame.hpp:40
const SGSolver_MaxMinMax & getSolver() const
Returns the solver object.
Definition: sgsolverworker.hpp:135
QString exceptionMsg
Exception message caught by solver.
Definition: sgsolverworker.hpp:60
SGSolve specific exceptions.
Definition: sgexception.hpp:36
STATUS getStatus() const
Returns the status of the worker.
Definition: sgsolverworker.hpp:88
void resultReady(bool)
Signal that gets emitted when iteration finishes.
void exceptionCaught()
Signal that gets emitted when an exception is caught.
@ MAXITERATIONS
Definition: sgnamespace.hpp:143
double iterate()
One iteration of the endogenous algorith.
Definition: sgsolver_maxminmax.cpp:270
@ FAILED
Definition: sgsolverworker.hpp:66
const QString & getExceptionMsg() const
Returns the exception message (if one is caught)
Definition: sgsolverworker.hpp:90
Class for solving stochastic games.
Definition: sgsolver_maxminmax.hpp:43
@ ERRORTOL
Definition: sgnamespace.hpp:69
Records the progress of SGSolver_MaxMinMax::solve().
Definition: sgsolution_maxminmax.hpp:40
Manages parameters for algorithm behavior.
Definition: sgenv.hpp:35
@ CONVERGED
Definition: sgsolverworker.hpp:68
QTextEdit * logTextEdit
A pointer to the text edit in which to report progress.
Definition: sgsolverworker.hpp:56
const SGSolution_MaxMinMax & getSolution() const
Returns the SGSolution object.
Definition: sgsolverworker.hpp:131
const SGEnv & env
An environment object to hold settings.
Definition: sgsolverworker.hpp:48
void iterate()
Iterates.
Definition: sgsolverworker.hpp:97
@ MAX_ITERATIONS_REACHED
Definition: sgnamespace.hpp:59
@ NOTCONVERGED
Definition: sgsolverworker.hpp:70
SGSolverWorker(const SGEnv &_env, const SGGame &game, QTextEdit *_logTextEdit)
Constructor.
Definition: sgsolverworker.hpp:77
void initialize()
Initializes the solve routines.
Definition: sgsolver_maxminmax.cpp:470
int numIter
Number of iterations.
Definition: sgsolverworker.hpp:58
STATUS
Code for status at the end of the iteration.
Definition: sgsolverworker.hpp:65