diff --git a/src/lagrangian/intermediate/Make/files b/src/lagrangian/intermediate/Make/files index d29f2c32bf..ab3933d123 100755 --- a/src/lagrangian/intermediate/Make/files +++ b/src/lagrangian/intermediate/Make/files @@ -48,4 +48,8 @@ submodels/addOns/radiation/scatter/cloudScatter/cloudScatter.C IntegrationScheme/makeIntegrationSchemes.C +/* Data entries */ +submodels/IO/DataEntry/makeDataEntries.C + + LIB = $(FOAM_LIBBIN)/liblagrangianIntermediate diff --git a/src/lagrangian/intermediate/clouds/Templates/KinematicCloud/KinematicCloud.C b/src/lagrangian/intermediate/clouds/Templates/KinematicCloud/KinematicCloud.C index c68238a28f..1ddd934275 100644 --- a/src/lagrangian/intermediate/clouds/Templates/KinematicCloud/KinematicCloud.C +++ b/src/lagrangian/intermediate/clouds/Templates/KinematicCloud/KinematicCloud.C @@ -437,7 +437,13 @@ void Foam::KinematicCloud::inject ); // Velocity of parcels - vector pU = this->injection().velocity(iParcel, timeInj); + vector pU = this->injection().velocity + ( + iParcel, + timeInj, + this->meshInfo(), + rndGen_ + ); // Determine the injection cell label pCell = -1; @@ -496,8 +502,9 @@ void Foam::KinematicCloud::postInjectCheck() { if (nParcelsAdded_) { - Pout<< "\n--> Cloud: " << this->name() << nl << - " Added " << nParcelsAdded_ << " new parcels" << nl << endl; + Pout<< "\n--> Cloud: " << this->name() << nl + << " Added " << nParcelsAdded_ + << " new parcels" << nl << endl; } // Reset parcel counters diff --git a/src/lagrangian/intermediate/clouds/Templates/ReactingCloud/ReactingCloud.C b/src/lagrangian/intermediate/clouds/Templates/ReactingCloud/ReactingCloud.C index 5251907c13..e787c5f41b 100644 --- a/src/lagrangian/intermediate/clouds/Templates/ReactingCloud/ReactingCloud.C +++ b/src/lagrangian/intermediate/clouds/Templates/ReactingCloud/ReactingCloud.C @@ -277,7 +277,12 @@ void Foam::ReactingCloud::inject ); // Velocity of parcels - vector pU = this->injection().velocity(iParcel, timeInj); + vector pU = this->injection().velocity + ( + iParcel, + timeInj, + this->meshInfo() + ); // Determine the injection cell label pCell = -1; diff --git a/src/lagrangian/intermediate/parcels/derived/basicKinematicParcel/makeBasicKinematicParcelInjectionModels.C b/src/lagrangian/intermediate/parcels/derived/basicKinematicParcel/makeBasicKinematicParcelInjectionModels.C index 7b72076611..ce0444a05c 100644 --- a/src/lagrangian/intermediate/parcels/derived/basicKinematicParcel/makeBasicKinematicParcelInjectionModels.C +++ b/src/lagrangian/intermediate/parcels/derived/basicKinematicParcel/makeBasicKinematicParcelInjectionModels.C @@ -26,8 +26,9 @@ License #include "basicKinematicParcel.H" #include "KinematicCloud.H" -#include "ManualInjection.H" #include "NoInjection.H" +#include "ManualInjection.H" +#include "ConeInjection.H" namespace Foam { @@ -35,6 +36,12 @@ namespace Foam // Add instances of injection model to the table makeInjectionModelType + ( + NoInjection, + KinematicCloud, + basicKinematicParcel + ); + makeInjectionModelType ( ManualInjection, KinematicCloud, @@ -42,7 +49,7 @@ namespace Foam ); makeInjectionModelType ( - NoInjection, + ConeInjection, KinematicCloud, basicKinematicParcel ); diff --git a/src/lagrangian/intermediate/submodels/IO/DataEntry/Constant/Constant.C b/src/lagrangian/intermediate/submodels/IO/DataEntry/Constant/Constant.C new file mode 100644 index 0000000000..9b896215ef --- /dev/null +++ b/src/lagrangian/intermediate/submodels/IO/DataEntry/Constant/Constant.C @@ -0,0 +1,90 @@ +/*---------------------------------------------------------------------------*\ + ========= | + \\ / F ield | OpenFOAM: The Open Source CFD Toolbox + \\ / O peration | + \\ / A nd | Copyright (C) 1991-2007 OpenCFD Ltd. + \\/ M anipulation | +------------------------------------------------------------------------------- +License + This file is part of OpenFOAM. + + OpenFOAM is free software; you can redistribute it and/or modify it + under the terms of the GNU General Public License as published by the + Free Software Foundation; either version 2 of the License, or (at your + option) any later version. + + OpenFOAM is distributed in the hope that it will be useful, but WITHOUT + ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + for more details. + + You should have received a copy of the GNU General Public License + along with OpenFOAM; if not, write to the Free Software Foundation, + Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA + +\*---------------------------------------------------------------------------*/ + +#include "Constant.H" + +// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // + +template +Foam::Constant::Constant +( + const word& entryName, + const dictionary& dict +) +: + DataEntry(typeName, entryName, dict), + value_(this->dict_.lookup("value")) +{} + + +template<> +Foam::Constant::Constant +( + const word& entryName, + const dictionary& dict +) +: + DataEntry