multiphaseEulerFoam v8: PhaseSystems - help understanding typedefs
Hi,
to make it short I am going straight to the point. My apologies for the lack of accuracy with the language and/or technicalities with regards to either the programming language or the OpenFOAM's code terminologies. For the solver in the subject we find under the multiphaseSystem.C all the aliases for the multiphase system types (the ones we must specify in constant/phaseProperties when setting up a case). For example: Code:
typedef 1.The parameter that is past to these PhaseSystems is the phaseSystem class. Is it correct to say that all these typedefs are also a phaseSystem? 2.Most of member functions used by these PhaseSystems come from the phaseSystem class. For example, the pure virtual member function: Code:
virtual autoPtr<momentumTransferTable> momentumTransfer() = 0 In .H: Code:
virtual autoPtr<phaseSystem::momentumTransferTable> momentumTransfer(); Code:
template<class BasePhaseSystem> Code:
momentumTransfer() In .H: Code:
virtual autoPtr<phaseSystem::momentumTransferTable> momentumTransfer(); Code:
template<class BasePhaseSystem> b.If so, this is why the MomentumTransferPhaseSystem is an inner class in this typedef, so that by using Code:
BasePhaseSystem::momentumTransferf() There are other member functions that could be used in place of the Code:
momentumTransfer() Extra question: If someone would be able to explain better these templated classes under PhaseSystem which are of type BasePhaseSystem, but at the same time inherits from BasePhaseSystem itself, it would be a great help. Thank you very much for your time. |
Well, after talking to someone that knows the code much better than I do, the answers for the question 2 are:
a.Yes, the momentumTransfer() is a necessary member function to account for the mass transfer process, which is not modeled in the MomentumTransferPhaseSystem class, hence it does not exist in the inherited code. b.Basically, the momentumTransfer() declared/defined in PhaseTransferPhaseSystem is just adding new momentum sources on top of the already existent in MomentumTransferPhaseSystem. |
As for the extra question, a quick explanation is given here ( http://www.researchgate.net/publicat...le_user_manual on page 203), which uses KinematicParcel rather than BasePhaseSystem as an example.
First the code snippet: Code:
template < class ParcelType > Quote:
|
All times are GMT -4. The time now is 03:29. |