|
[Sponsors] |
Adding a new parameter to the injected particles |
![]() |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
![]() |
![]() |
#1 |
Senior Member
Farzad Faraji
Join Date: Nov 2019
Posts: 204
Rep Power: 6 ![]() |
Dear friend
I want to add a property(exactly like "rho" for particles) to my particle properties. Actually I want to add "Mass Fraction" at the injection to my particles. I know that I should change KinematicParcel.C and KinematicCloud.C (constructor part), but it is a little ambiguous to me which one is an Eulerian parameter and which one is a Lagrangian parameter(I make them RED). Lets I copy the code here; Code:
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // template<class CloudType> Foam::KinematicCloud<CloudType>::KinematicCloud ( const word& cloudName, const volScalarField& rho, const volVectorField& U, const volScalarField& mu, const dimensionedVector& g, bool readFields ) : CloudType(rho.mesh(), cloudName, false), kinematicCloud(), cloudCopyPtr_(nullptr), mesh_(rho.mesh()), particleProperties_ ( IOobject ( cloudName + "Properties", rho.mesh().time().constant(), rho.mesh(), IOobject::MUST_READ_IF_MODIFIED, IOobject::NO_WRITE ) ), outputProperties_ ( IOobject ( cloudName + "OutputProperties", mesh_.time().timeName(), "uniform"/cloud::prefix/cloudName, mesh_, IOobject::READ_IF_PRESENT, IOobject::NO_WRITE ) ), Thanks, Farzad |
|
![]() |
![]() |
![]() |
![]() |
#2 |
Senior Member
Farzad Faraji
Join Date: Nov 2019
Posts: 204
Rep Power: 6 ![]() |
Dear friends
After reviewing the code for few times, I remembered that I remember that the green lines are for Eulerian rho(density of Fluid) and red lines are for Lagrangian(density of particle) as below; [CODE] Code:
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // template<class CloudType> Foam::KinematicCloud<CloudType>::KinematicCloud ( const word& cloudName, const volScalarField& rho, const volVectorField& U, const volScalarField& mu, const dimensionedVector& g, bool readFields ) : CloudType(rho.mesh(), cloudName, false), kinematicCloud(), cloudCopyPtr_(nullptr), mesh_(rho.mesh()), particleProperties_ ( IOobject ( cloudName + "Properties", rho.mesh().time().constant(), rho.mesh(), IOobject::MUST_READ_IF_MODIFIED, IOobject::NO_WRITE )[/COLOR] ), outputProperties_ ( IOobject ( cloudName + "OutputProperties", mesh_.time().timeName(), "uniform"/cloud::prefix/cloudName, mesh_, IOobject::READ_IF_PRESENT, IOobject::NO_WRITE ) ), Thanks, Farzad |
|
![]() |
![]() |
![]() |
Tags |
injection, lagrangian, parameter, particles |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
What is the importance of SPREAD PARAMETER in a rosin rammler particles distribution? | mariconeagles96 | Fluent Multiphase | 1 | May 9, 2018 14:55 |
conjugateHeatFoam + interFoam | farhagim | OpenFOAM Programming & Development | 15 | July 19, 2016 07:55 |
What limits the amount of injected lagrangian particles? | Kabra | OpenFOAM Running, Solving & CFD | 0 | October 12, 2015 07:57 |
[PyFoam] running pyFoam(Plot)Runner.py in parallel | Studi | OpenFOAM Community Contributions | 10 | September 6, 2015 16:38 |
particles model | ati_ros61 | FLOW-3D | 3 | December 6, 2009 16:03 |