CalculateFlowThread Class Reference

Class for doing the actual calculations, inherits QThread. More...

List of all members.

Signals

void simulationError (QString errorMsg)

Public Member Functions

 CalculateFlowThread (QWidget *parent, Data *data, FrictionFunctions *frictionFunctions, CalculateFunctions *calculateFunctions, bool useMinimumHoldupCriterion, unsigned int id, double tolerance=0.0001)
 CalculateFlowThread (QWidget *parent, Data *data, FrictionFunctions *frictionFunctions, CalculateFunctions *calculateFunctions, RegimeTransitionInterface *regimeTransitionPlugin, unsigned int id, double tolerance=0.0001)
 ~CalculateFlowThread ()
double diameterGas ()
double x ()
double y ()
double holdup ()
double alpha ()
double dpdx ()

Protected Member Functions

void run ()

Private Attributes

QWidget * _parent
Data_data
FrictionFunctions_frictionFunctions
RegimeTransitionInterface_regimeTransitionPlugin
CalculateFunctions_calculateFunctions
double _diameterGas
double _holdup
double _alpha
double _dpdx
double _y
bool _useMinimumHoldupCriterion
unsigned int _resolution
unsigned int _id
double _tolerance

Detailed Description

Class for doing the actual calculations, inherits QThread.


Constructor & Destructor Documentation

CalculateFlowThread::CalculateFlowThread ( QWidget *  parent,
Data data,
FrictionFunctions frictionFunctions,
CalculateFunctions calculateFunctions,
bool  useMinimumHoldupCriterion,
unsigned int  id,
double  tolerance = 0.0001 
)

Constructor that creates the thread and readies for simulation

Parameters:
parent Pointer to parent (owner)
data Flow data
frictionFunctions Pointer to class with pointer to functions
calculateFunctions Pointer to class with pointers to calculate functions
useMinimumHoldupCriterion Should the calculation use the minimum holdup criterion or simply calculate for the selected regime
id Thread identification, used to keep track of it in CalculateManager
tolerance Numerical tolerance in calculation answer
CalculateFlowThread::CalculateFlowThread ( QWidget *  parent,
Data data,
FrictionFunctions frictionFunctions,
CalculateFunctions calculateFunctions,
RegimeTransitionInterface regimeTransitionPlugin,
unsigned int  id,
double  tolerance = 0.0001 
)
CalculateFlowThread::~CalculateFlowThread (  ) 

Destructor, delete data and so on


Member Function Documentation

double CalculateFlowThread::alpha (  ) 

Returns alpha

double CalculateFlowThread::diameterGas (  ) 

Returns hydraulic diameters for all variables

double CalculateFlowThread::dpdx (  ) 

Returns pressure loss

double CalculateFlowThread::holdup (  ) 

Returns holdup

void CalculateFlowThread::run (  )  [protected]

Run thread, gets called from start()

void CalculateFlowThread::simulationError ( QString  errorMsg  )  [signal]

Here is the caller graph for this function:

double CalculateFlowThread::x (  ) 

Returns x value

double CalculateFlowThread::y (  ) 

Returns y value


Member Data Documentation

double CalculateFlowThread::_alpha [private]
double CalculateFlowThread::_dpdx [private]
double CalculateFlowThread::_holdup [private]
unsigned int CalculateFlowThread::_id [private]
QWidget* CalculateFlowThread::_parent [private]
unsigned int CalculateFlowThread::_resolution [private]
double CalculateFlowThread::_y [private]
 All Classes Functions Variables

Generated by  doxygen 1.6.2