Loading [MathJax]/jax/output/HTML-CSS/config.js
Cantera  3.2.0a1
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages

Base class for 'walls' (walls, pistons, etc.) connecting reactors. More...

#include <Wall.h>

Inheritance diagram for WallBase:
[legend]

Detailed Description

Base class for 'walls' (walls, pistons, etc.) connecting reactors.

Definition at line 22 of file Wall.h.

Public Member Functions

 WallBase (shared_ptr< ReactorBase > r0, shared_ptr< ReactorBase > r1, const string &name="(none)")
 
string type () const override
 String indicating the connector implemented.
 
virtual double expansionRate ()
 Rate of volume change (m^3/s) for the adjacent reactors at current reactor network time.
 
virtual double heatRate ()
 Heat flow rate through the wall (W) at current reactor network time.
 
double area ()
 Area in (m^2).
 
virtual void setArea (double a)
 Set the area [m^2].
 
bool install (ReactorBase &leftReactor, ReactorBase &rightReactor)
 Install the wall between two reactors or reservoirs.
 
virtual void initialize ()
 Called just before the start of integration.
 
virtual bool ready ()
 True if the wall is correctly configured and ready to use.
 
ReactorBaseleft () const
 Return a reference to the Reactor or Reservoir to the left of the wall.
 
ReactorBaseright ()
 Return a reference to the Reactor or Reservoir to the right of the wall.
 
void setSimTime (double time)
 Set current reactor network time.
 
 ConnectorNode (const string &name="(none)")
 Transitional constructor.
 
 ConnectorNode (shared_ptr< ReactorBase > r0, shared_ptr< ReactorBase > r1, const string &name="(none)")
 Instantiate a ConnectorNode object with associated ReactorBase objects.
 
 ConnectorNode (const ConnectorNode &)=delete
 
- Public Member Functions inherited from ConnectorNode
 ConnectorNode (const string &name="(none)")
 Transitional constructor.
 
 ConnectorNode (shared_ptr< ReactorBase > r0, shared_ptr< ReactorBase > r1, const string &name="(none)")
 Instantiate a ConnectorNode object with associated ReactorBase objects.
 
 ConnectorNode (const ConnectorNode &)=delete
 
ConnectorNodeoperator= (const ConnectorNode &)=delete
 
virtual string type () const
 String indicating the connector implemented.
 
string name () const
 Retrieve connector name.
 
void setName (const string &name)
 Set connector name.
 
void setDefaultName (map< string, int > &counts)
 Set the default name of a connector. Returns false if it was previously set.
 

Protected Attributes

ReactorBasem_left = nullptr
 
ReactorBasem_right = nullptr
 
double m_time = 0.0
 current reactor network time
 
double m_area = 1.0
 
- Protected Attributes inherited from ConnectorNode
pair< shared_ptr< ReactorBase >, shared_ptr< ReactorBase > > m_nodes
 Pair of reactors forming end points of the connector.
 
string m_name
 ConnectorNode name.
 
bool m_defaultNameSet = false
 true if default name has been previously set.
 

Constructor & Destructor Documentation

◆ WallBase()

WallBase ( shared_ptr< ReactorBase r0,
shared_ptr< ReactorBase r1,
const string &  name = "(none)" 
)

Definition at line 13 of file Wall.cpp.

Member Function Documentation

◆ type()

string type ( ) const
inlineoverridevirtual

String indicating the connector implemented.

Usually corresponds to the name of the derived class.

Reimplemented from ConnectorNode.

Definition at line 29 of file Wall.h.

◆ expansionRate()

virtual double expansionRate ( )
inlinevirtual

Rate of volume change (m^3/s) for the adjacent reactors at current reactor network time.

This method is called by Reactor::evalWalls(). Base class method does nothing (that is, constant volume), but may be overloaded.

Since
New in Cantera 3.0.

Reimplemented in Wall.

Definition at line 40 of file Wall.h.

◆ heatRate()

virtual double heatRate ( )
inlinevirtual

Heat flow rate through the wall (W) at current reactor network time.

This method is called by Reactor::evalWalls(). Base class method does nothing (that is, an adiabatic wall), but may be overloaded.

Since
New in Cantera 3.0.

Reimplemented in Wall.

Definition at line 50 of file Wall.h.

◆ area()

double area ( )
inline

Area in (m^2).

Definition at line 55 of file Wall.h.

◆ setArea()

void setArea ( double  a)
virtual

Set the area [m^2].

Definition at line 44 of file Wall.cpp.

◆ install()

bool install ( ReactorBase leftReactor,
ReactorBase rightReactor 
)

Install the wall between two reactors or reservoirs.

Deprecated:
To be removed after Cantera 3.2. Reactors should be provided to constructor instead.

Definition at line 28 of file Wall.cpp.

◆ initialize()

virtual void initialize ( )
inlinevirtual

Called just before the start of integration.

Definition at line 68 of file Wall.h.

◆ ready()

virtual bool ready ( )
inlinevirtual

True if the wall is correctly configured and ready to use.

Definition at line 71 of file Wall.h.

◆ left()

ReactorBase & left ( ) const
inline

Return a reference to the Reactor or Reservoir to the left of the wall.

Definition at line 76 of file Wall.h.

◆ right()

ReactorBase & right ( )
inline

Return a reference to the Reactor or Reservoir to the right of the wall.

Definition at line 81 of file Wall.h.

◆ setSimTime()

void setSimTime ( double  time)
inline

Set current reactor network time.

Since
New in Cantera 3.0.

Definition at line 89 of file Wall.h.

◆ ConnectorNode() [1/2]

ConnectorNode ( const string &  name = "(none)")
inline

Transitional constructor.

Todo:
Implement deprecation warning.

Definition at line 32 of file ConnectorNode.h.

◆ ConnectorNode() [2/2]

ConnectorNode ( shared_ptr< ReactorBase r0,
shared_ptr< ReactorBase r1,
const string &  name = "(none)" 
)
inline

Instantiate a ConnectorNode object with associated ReactorBase objects.

Parameters
r0First reactor.
r1Second reactor.
nameName of the connector.

Definition at line 38 of file ConnectorNode.h.

Member Data Documentation

◆ m_left

ReactorBase* m_left = nullptr
protected

Definition at line 94 of file Wall.h.

◆ m_right

ReactorBase* m_right = nullptr
protected

Definition at line 95 of file Wall.h.

◆ m_time

double m_time = 0.0
protected

current reactor network time

Definition at line 98 of file Wall.h.

◆ m_area

double m_area = 1.0
protected

Definition at line 100 of file Wall.h.


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