OpenFOAM logo
Open Source CFD Toolkit

engineTime Class Reference

Inheritance diagram for engineTime:

Inheritance graph
[legend]
Collaboration diagram for engineTime:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 engineTime (const word &name, const fileName &rootPath, const fileName &caseName, const fileName &systemName="system", const fileName &constantName="constant")
 Construct from objectRegistry arguments.
virtual ~engineTime ()
scalar degToRad (const scalar rad) const
 Convert degrees to radians.
scalar degToTime (const scalar theta) const
 Convert degrees to seconds (for given engine speed in RPM).
scalar timeToDeg (const scalar t) const
 Convert seconds to degrees (for given engine speed in RPM).
scalar pistonPosition (const scalar theta) const
 Calculate the piston position from the engine geometry.
const dictionaryengineDict () const
 Return the engine geometry dictionary.
const dimensionedScalarconRodLength () const
 Return the engines connecting-rod length.
const dimensionedScalarbore () const
 Return the engines bore.
const dimensionedScalarstroke () const
 Return the engines stroke.
const dimensionedScalarclearance () const
 Return the engines clearance-gap.
const dimensionedScalarrpm () const
 Return the engines current operating RPM.
scalar theta () const
 Return current crank-angle.
scalar thetaRevolution () const
 Return current crank-angle translated to a single revolution.
scalar deltaTheta () const
 Return crank-angle increment.
dimensionedScalar pistonPosition () const
 Return current piston position.
dimensionedScalar pistonDisplacement () const
 Return piston displacement for current time step.
dimensionedScalar pistonSpeed () const
 Return piston speed for current time step.
scalar userTimeToTime (const scalar theta) const
 Convert the user-time (CA deg) to real-time (s).
scalar timeToUserTime (const scalar t) const
 Convert the real-time (s) into user-time (CA deg).
bool read ()
 Read the controlDict and set all the parameters.

Constructor & Destructor Documentation

engineTime const word name,
const fileName rootPath,
const fileName caseName,
const fileName systemName = "system",
const fileName constantName = "constant"
 

Construct from objectRegistry arguments.

virtual ~engineTime  )  [inline, virtual]
 

Definition at line 98 of file engineTime.H.


Member Function Documentation

const dimensionedScalar& bore  )  const [inline]
 

Return the engines bore.

Definition at line 137 of file engineTime.H.

const dimensionedScalar& clearance  )  const [inline]
 

Return the engines clearance-gap.

Definition at line 149 of file engineTime.H.

const dimensionedScalar& conRodLength  )  const [inline]
 

Return the engines connecting-rod length.

Definition at line 131 of file engineTime.H.

scalar degToRad const scalar  rad  )  const
 

Convert degrees to radians.

scalar degToTime const scalar  theta  )  const
 

Convert degrees to seconds (for given engine speed in RPM).

scalar deltaTheta  )  const
 

Return crank-angle increment.

const dictionary& engineDict  )  const [inline]
 

Return the engine geometry dictionary.

Definition at line 125 of file engineTime.H.

dimensionedScalar pistonDisplacement  )  const
 

Return piston displacement for current time step.

dimensionedScalar pistonPosition  )  const
 

Return current piston position.

scalar pistonPosition const scalar  theta  )  const
 

Calculate the piston position from the engine geometry.

and given crank angle.

dimensionedScalar pistonSpeed  )  const
 

Return piston speed for current time step.

bool read  )  [virtual]
 

Read the controlDict and set all the parameters.

Reimplemented from Time.

const dimensionedScalar& rpm  )  const [inline]
 

Return the engines current operating RPM.

Definition at line 155 of file engineTime.H.

References Foam::dimensionedScalar.

const dimensionedScalar& stroke  )  const [inline]
 

Return the engines stroke.

Definition at line 143 of file engineTime.H.

scalar theta  )  const
 

Return current crank-angle.

scalar thetaRevolution  )  const
 

Return current crank-angle translated to a single revolution.

(value between -180 and 180 with 0 = top dead centre)

scalar timeToDeg const scalar  t  )  const
 

Convert seconds to degrees (for given engine speed in RPM).

scalar timeToUserTime const scalar  t  )  const [virtual]
 

Convert the real-time (s) into user-time (CA deg).

Reimplemented from TimeState.

scalar userTimeToTime const scalar  theta  )  const [virtual]
 

Convert the user-time (CA deg) to real-time (s).

Reimplemented from TimeState.


The documentation for this class was generated from the following file:
For further information go to www.openfoam.org