ODT
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | Private Member Functions | List of all members
domain Class Reference

#include <domain.h>

Public Member Functions

int domainPositionToIndex (double position, const bool LowSide, int dbg)
 
void setDomainFromRegion (const int i1, const int i2)
 
double cyclePeriodicDomain (const int icycle)
 
void backCyclePeriodicDomain (const double backCycleDistance)
 
double Ldomain ()
 
void init (inputoutput *p_io, meshManager *p_mesher, streams *p_strm, IdealGasPhase *p_gas, Transport *p_tran, micromixer *p_mimx, eddy *p_ed, domain *p_eddl, solver *p_solv, randomGenerator *p_rand, bool LisEddyDomain=false)
 
 domain (domain *p_domn, param *p_pram)
 
virtual ~domain ()
 

Public Attributes

domaindomn
 (for one domain to point to another (eddl))
 
int ngrd
 number of grid cells
 
int ngrdf
 number of grid cell faces = ngrd+1
 
vector< dv * > v
 All domain variables are stored in here.
 
dvpos
 pointers to gas properties
 
dvposf
 access as: posf->d[i], or posf->var_name, etc.
 
dvrho
 
dvdvisc
 
dvuvel
 
dvvvel
 
dvwvel
 
dvsdiff
 
dvsca
 
dvphase
 
dventh
 
dvtemp
 
dvmixf
 
dvchi
 
dvhr
 
dvaDL
 
vector< dv * >::iterator ysp
 access as: ysp=v.begin(), (*ysp)->d[i] or (*(ysp+k))->d[i], or ysp[k]->d[i].
 
vector< dv * >::iterator svar
 iterator for increment to go through moments (*(ysp+k))->d[i];)
 
vector< dv * >::iterator eta
 iterator for increment to go through species etc. (*(ysp+k))->d[i];)
 
map< string, dv * > varMap
 
IdealGasPhase * gas
 pointer to cantera thermochemistry object (reaction rates, Cp, etc.)
 
Transport * tran
 pointer to cantera transport object (viscosity, diffusivity, etc.)
 
streamsstrm
 pointer to gas stream properties
 
inputoutputio
 pointer to input/output object
 
parampram
 pointer to the parameters object
 
micromixermimx
 pointer to micromixer for diffusion, reaction, domain evolution.
 
eddyed
 pointer to object for eddy operations
 
domaineddl
 pointer to eddyline object
 
solversolv
 pointer to solver object
 
meshManagermesher
 pointer to mesh manager object
 
randomGeneratorrand
 
int nTrans
 number of transported variables on the domain.
 
domaincasedomc
 domaincase class: set specific vars...
 

Private Member Functions

void initEddyDomain ()
 

Detailed Description

Class implementing domain object

Author
David O. Lignell

Definition at line 34 of file domain.h.

Constructor & Destructor Documentation

◆ domain()

domain::domain ( domain * p_domn,
param * p_pram )

Constructor

Definition at line 34 of file domain.cc.

◆ ~domain()

virtual domain::~domain ( )
inlinevirtual

Definition at line 116 of file domain.h.

Member Function Documentation

◆ backCyclePeriodicDomain()

void domain::backCyclePeriodicDomain ( const double backCycleDistance)

Back cycle domain for periodic flows. Intended to be called some time after cyclePeriodicDomain is called. Splits the cell at posf.at(ngrd) - backCycleDistace, then moves end cells after the split to the beginning of the domain.

Parameters
<em>input:</em>distance from the end to split and move the domain.

Definition at line 336 of file domain.cc.

◆ cyclePeriodicDomain()

double domain::cyclePeriodicDomain ( const int icycle)

Cycle domain for periodic flows.

Parameters
icycleinput: move all cells before and including this one to the end of the domain.
Returns
the cycle distance (used for backcycling).

Definition at line 304 of file domain.cc.

◆ domainPositionToIndex()

int domain::domainPositionToIndex ( double position,
const bool LowSide,
int dbg )

Find index of cell for given position (residing in cell). Start search assuming a uniform grid, then search forward or back till hit the cell index. If position is on cell face j, then if LowSide true, return j, else j-1.
For start of eddy region, set LowSide to true
For end of eddy region, set LowSide to false
(This is so triplet maps don't overlap cells)


e.g., usual:   | { | | | | } |    5 pts, eddy pos between cell faces
      okay:    {   | | | |   }    5 pts, eddy pos on cell faces (1 or both)
      bad:     |   { | | }   |    5 pts, eddy pos on internal faces (1 or both)
                                                                                  
Parameters
positioninput: position to find corresponding index.
LowSideinput: flag true, then return j if position is on cell face j, else j-1.
Returns
index of position.

Definition at line 234 of file domain.cc.

◆ init()

void domain::init ( inputoutput * p_io,
meshManager * p_mesher,
streams * p_strm,
IdealGasPhase * p_gas,
Transport * p_tran,
micromixer * p_mimx,
eddy * p_ed,
domain * p_eddl,
solver * p_solv,
randomGenerator * p_rand,
bool LisEddyDomain = false )

Initializer

Definition at line 46 of file domain.cc.

◆ initEddyDomain()

void domain::initEddyDomain ( )
private

Initialize data members of the eddy domain. Note, none of the other members of this domain should be used (like random). Note, all variables here should have corresponding variables (by var_name) in the main domn. This is needed for using the eddl object.

Definition at line 167 of file domain.cc.

◆ Ldomain()

double domain::Ldomain ( )

Compute size of domain based on faces.

Definition at line 156 of file domain.cc.

◆ setDomainFromRegion()

void domain::setDomainFromRegion ( const int i1,
const int i2 )

Set the domain from a region of the domn. Normally called by eddy domain.

Parameters
i1input: index of starting cell of domn to build from
i2input: index of ending cell of domn to build from If i2 < i1, we have a periodic region (wrap around the domain). This only happens in planar cases, not cylindrical or sphericial. nonwrap: | | * | * | * | * | * | * | | | i1 i2 new domain consists of *'d cells

Wrap: | 4 | 5 | | | | | 1 | 2 | 3 | i2 i1 New domain consists of #'d cells: 1 2 3 4 5}

Definition at line 207 of file domain.cc.

Member Data Documentation

◆ aDL

dv* domain::aDL

Definition at line 62 of file domain.h.

◆ chi

dv* domain::chi

Definition at line 60 of file domain.h.

◆ domc

domaincase* domain::domc

domaincase class: set specific vars...

Definition at line 84 of file domain.h.

◆ domn

domain* domain::domn

(for one domain to point to another (eddl))

Definition at line 40 of file domain.h.

◆ dvisc

dv* domain::dvisc

Definition at line 50 of file domain.h.

◆ ed

eddy* domain::ed

pointer to object for eddy operations

Definition at line 75 of file domain.h.

◆ eddl

domain* domain::eddl

pointer to eddyline object

Definition at line 76 of file domain.h.

◆ enth

dv* domain::enth

Definition at line 57 of file domain.h.

◆ eta

vector<dv*>::iterator domain::eta

iterator for increment to go through species etc. (*(ysp+k))->d[i];)

Definition at line 65 of file domain.h.

◆ gas

IdealGasPhase* domain::gas

pointer to cantera thermochemistry object (reaction rates, Cp, etc.)

Definition at line 69 of file domain.h.

◆ hr

dv* domain::hr

Definition at line 61 of file domain.h.

◆ io

inputoutput* domain::io

pointer to input/output object

Definition at line 72 of file domain.h.

◆ mesher

meshManager* domain::mesher

pointer to mesh manager object

Definition at line 78 of file domain.h.

◆ mimx

micromixer* domain::mimx

pointer to micromixer for diffusion, reaction, domain evolution.

Definition at line 74 of file domain.h.

◆ mixf

dv* domain::mixf

Definition at line 59 of file domain.h.

◆ ngrd

int domain::ngrd

number of grid cells

Definition at line 42 of file domain.h.

◆ ngrdf

int domain::ngrdf

number of grid cell faces = ngrd+1

Definition at line 43 of file domain.h.

◆ nTrans

int domain::nTrans

number of transported variables on the domain.

Definition at line 82 of file domain.h.

◆ phase

dv* domain::phase

Definition at line 56 of file domain.h.

◆ pos

dv* domain::pos

pointers to gas properties

Definition at line 47 of file domain.h.

◆ posf

dv* domain::posf

access as: posf->d[i], or posf->var_name, etc.

Definition at line 48 of file domain.h.

◆ pram

param* domain::pram

pointer to the parameters object

Definition at line 73 of file domain.h.

◆ rand

randomGenerator* domain::rand

Definition at line 80 of file domain.h.

◆ rho

dv* domain::rho

Definition at line 49 of file domain.h.

◆ sca

dv* domain::sca

Definition at line 55 of file domain.h.

◆ sdiff

dv* domain::sdiff

Definition at line 54 of file domain.h.

◆ solv

solver* domain::solv

pointer to solver object

Definition at line 77 of file domain.h.

◆ strm

streams* domain::strm

pointer to gas stream properties

Definition at line 71 of file domain.h.

◆ svar

vector<dv*>::iterator domain::svar

iterator for increment to go through moments (*(ysp+k))->d[i];)

Definition at line 64 of file domain.h.

◆ temp

dv* domain::temp

Definition at line 58 of file domain.h.

◆ tran

Transport* domain::tran

pointer to cantera transport object (viscosity, diffusivity, etc.)

Definition at line 70 of file domain.h.

◆ uvel

dv* domain::uvel

Definition at line 51 of file domain.h.

◆ v

vector<dv*> domain::v

All domain variables are stored in here.

Definition at line 45 of file domain.h.

◆ varMap

map<string,dv*> domain::varMap

Definition at line 67 of file domain.h.

◆ vvel

dv* domain::vvel

Definition at line 52 of file domain.h.

◆ wvel

dv* domain::wvel

Definition at line 53 of file domain.h.

◆ ysp

vector<dv*>::iterator domain::ysp

access as: ysp=v.begin(), (*ysp)->d[i] or (*(ysp+k))->d[i], or ysp[k]->d[i].

Definition at line 63 of file domain.h.


The documentation for this class was generated from the following files: