diff --git a/applications/utilities/postProcessing/dataConversion/foamToEnsight/ensightMesh.C b/applications/utilities/postProcessing/dataConversion/foamToEnsight/ensightMesh.C index 8a44c5411b3fe81208f7e336163ff8814d6fa4db..df6fe4da410916a26eeaafe81dee7094ef8c203b 100644 --- a/applications/utilities/postProcessing/dataConversion/foamToEnsight/ensightMesh.C +++ b/applications/utilities/postProcessing/dataConversion/foamToEnsight/ensightMesh.C @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -1150,13 +1150,13 @@ void Foam::ensightMesh::write labelList pointToGlobal; labelList uniqueMeshPointLabels; autoPtr<globalIndex> globalPointsPtr = - mesh_.globalData().mergePoints - ( - p.meshPoints(), - p.meshPointMap(), - pointToGlobal, - uniqueMeshPointLabels - ); + mesh_.globalData().mergePoints + ( + p.meshPoints(), + p.meshPointMap(), + pointToGlobal, + uniqueMeshPointLabels + ); pointField uniquePoints(mesh_.points(), uniqueMeshPointLabels); // Renumber the patch faces @@ -1225,13 +1225,13 @@ void Foam::ensightMesh::write labelList pointToGlobal; labelList uniqueMeshPointLabels; autoPtr<globalIndex> globalPointsPtr = - mesh_.globalData().mergePoints - ( - fz().meshPoints(), - fz().meshPointMap(), - pointToGlobal, - uniqueMeshPointLabels - ); + mesh_.globalData().mergePoints + ( + fz().meshPoints(), + fz().meshPointMap(), + pointToGlobal, + uniqueMeshPointLabels + ); pointField uniquePoints(mesh_.points(), uniqueMeshPointLabels); diff --git a/src/finiteVolume/fields/fvPatchFields/derived/externalCoupledMixed/externalCoupledMixedFvPatchField.C b/src/finiteVolume/fields/fvPatchFields/derived/externalCoupledMixed/externalCoupledMixedFvPatchField.C index 5da9b8a19de35c99c505b506279af1af0bd3a98e..15e315b8dea2297e07f126ed6208338c463281e8 100644 --- a/src/finiteVolume/fields/fvPatchFields/derived/externalCoupledMixed/externalCoupledMixedFvPatchField.C +++ b/src/finiteVolume/fields/fvPatchFields/derived/externalCoupledMixed/externalCoupledMixedFvPatchField.C @@ -30,6 +30,7 @@ License #include "IFstream.H" #include "OFstream.H" #include "globalIndex.H" +#include "ListListOps.H" // * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * // @@ -52,6 +53,62 @@ Foam::fileName Foam::externalCoupledMixedFvPatchField<Type>::baseDir() const } +template<class Type> +void Foam::externalCoupledMixedFvPatchField<Type>::writeGeometry() const +{ + int tag = Pstream::msgType() + 1; + + const label procI = Pstream::myProcNo(); + const polyPatch& p = this->patch().patch(); + const polyMesh& mesh = p.boundaryMesh().mesh(); + + labelList pointToGlobal; + labelList uniquePointIDs; + (void)mesh.globalData().mergePoints + ( + p.meshPoints(), + p.meshPointMap(), + pointToGlobal, + uniquePointIDs + ); + + List<pointField> allPoints(Pstream::nProcs()); + allPoints[procI] = pointField(mesh.points(), uniquePointIDs); + Pstream::gatherList(allPoints, tag); + + List<faceList> allFaces(Pstream::nProcs()); + faceList& patchFaces = allFaces[procI]; + patchFaces = p.localFaces(); + forAll(patchFaces, faceI) + { + inplaceRenumber(pointToGlobal, patchFaces[faceI]); + } + + Pstream::gatherList(allFaces, tag); + + if (Pstream::master()) + { + OFstream osPoints(baseDir()/"patchPoints"); + if (log_) + { + Info<< "writing patch points to: " << osPoints.name() << endl; + } + + osPoints<< + ListListOps::combine<pointField>(allPoints, accessOp<pointField>()); + + OFstream osFaces(baseDir()/"patchFaces"); + if (log_) + { + Info<< "writing patch faces to: " << osFaces.name() << endl; + } + + osFaces<< + ListListOps::combine<faceList>(allFaces, accessOp<faceList>()); + } +} + + template<class Type> Foam::fileName Foam::externalCoupledMixedFvPatchField<Type>::lockFile() const { @@ -346,6 +403,8 @@ Foam::externalCoupledMixedFvPatchField<Type>::externalCoupledMixedFvPatchField this->refValue() = *this; this->refGrad() = pTraits<Type>::zero; this->valueFraction() = 1.0; + + writeGeometry(); } diff --git a/src/finiteVolume/fields/fvPatchFields/derived/externalCoupledMixed/externalCoupledMixedFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/derived/externalCoupledMixed/externalCoupledMixedFvPatchField.H index 50376e097de456e9123a04202db210801cca4e1e..a51ef9af7bffa612d8a587bea073d0b397e883e3 100644 --- a/src/finiteVolume/fields/fvPatchFields/derived/externalCoupledMixed/externalCoupledMixedFvPatchField.H +++ b/src/finiteVolume/fields/fvPatchFields/derived/externalCoupledMixed/externalCoupledMixedFvPatchField.H @@ -137,6 +137,9 @@ protected: //- Return the file path to the base communications folder fileName baseDir() const; + //- Write the geometry to the comms dir + void writeGeometry() const; + //- Return the file path to the lock file fileName lockFile() const; diff --git a/src/finiteVolume/fields/fvPatchFields/derived/mappedFixedInternalValue/mappedFixedInternalValueFvPatchField.C b/src/finiteVolume/fields/fvPatchFields/derived/mappedFixedInternalValue/mappedFixedInternalValueFvPatchField.C index 819f39ecfb88b20368f1f8c6db3522d87066fc36..680d3f89f0fa51d9042a14435acd65539b51bbb3 100644 --- a/src/finiteVolume/fields/fvPatchFields/derived/mappedFixedInternalValue/mappedFixedInternalValueFvPatchField.C +++ b/src/finiteVolume/fields/fvPatchFields/derived/mappedFixedInternalValue/mappedFixedInternalValueFvPatchField.C @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -135,6 +135,7 @@ void Foam::mappedFixedInternalValueFvPatchField<Type>::updateCoeffs() break; } case mappedPatchBase::NEARESTPATCHFACE: + case mappedPatchBase::NEARESTPATCHFACEAMI: { const label samplePatchI = mpp.samplePolyPatch().index(); const fvPatchField<Type>& nbrPatchField = diff --git a/src/meshTools/AMIInterpolation/AMIInterpolation/AMIInterpolation.H b/src/meshTools/AMIInterpolation/AMIInterpolation/AMIInterpolation.H index 1ce855b3aec678896dc6eadbb216e66877bacdf2..0b7633035536627ff5134a06e76589f5fd63eb89 100644 --- a/src/meshTools/AMIInterpolation/AMIInterpolation/AMIInterpolation.H +++ b/src/meshTools/AMIInterpolation/AMIInterpolation/AMIInterpolation.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -42,6 +42,7 @@ Description SourceFiles AMIInterpolation.C AMIInterpolationName.C + AMIInterpolationParallelOps.C \*---------------------------------------------------------------------------*/ diff --git a/tutorials/lagrangian/reactingParcelFoam/filter/system/fvOptions b/tutorials/lagrangian/reactingParcelFoam/filter/system/fvOptions index a6fa8898ba577ffbd6af1c575adf5d43f08ac45c..ea198445a4b91941c3e04500cb7e7f2a4a59f8ea 100644 --- a/tutorials/lagrangian/reactingParcelFoam/filter/system/fvOptions +++ b/tutorials/lagrangian/reactingParcelFoam/filter/system/fvOptions @@ -33,8 +33,14 @@ filter1 coordinateSystem { - e1 (1 0 0); - e2 (0 1 0); + type cartesian; + origin (0 0 0); + coordinateRotation + { + type axesRotation; + e1 (1 0 0); + e2 (0 1 0); + } } } } diff --git a/tutorials/lagrangian/sprayFoam/aachenBomb/chemkin/therm.dat b/tutorials/lagrangian/sprayFoam/aachenBomb/chemkin/therm.dat new file mode 100644 index 0000000000000000000000000000000000000000..b0fcfd816f1c4d30a7aa117333e76c4cd5e4f12d --- /dev/null +++ b/tutorials/lagrangian/sprayFoam/aachenBomb/chemkin/therm.dat @@ -0,0 +1,23 @@ +THERMO ALL + 200.000 1000.000 6000.000 +C7H16 P10/85C 7.H 16. 0. 0.G 200.000 6000.000 1000. 1 + 2.04565203E+01 3.48575357E-02-1.09226846E-05 1.67201776E-09-9.81024850E-14 2 +-3.25556365E+04-8.04405017E+01 1.11532994E+01-9.49419773E-03 1.95572075E-04 3 +-2.49753662E-07 9.84877715E-11-2.67688904E+04-1.59096837E+01-2.25846141E+04 4 +O2 ATcT06O 2. 0. 0. 0.G 200.000 6000.000 1000. 1 + 3.45852381E+00 1.04045351E-03-2.79664041E-07 3.11439672E-11-8.55656058E-16 2 + 1.0dev 63E+04 4.15264119E+00 3.78535371E+00-3.21928540E-03 1.12323443E-05 3 +-1.17254068E-08 4.17659585E-12 1.02922572E+04 3.27320239E+00 1.13558105E+04 4 +N2 G 8/02N 2. 0. 0. 0.G 200.000 6000.000 1000. 1 + 2.95257637E+00 1.39690040E-03-4.92631603E-07 7.86010195E-11-4.60755204E-15 2 +-9.23948688E+02 5.87188762E+00 3.53100528E+00-1.23660988E-04-5.02999433E-07 3 + 2.43530612E-09-1.40881235E-12-1.04697628E+03 2.96747038E+00 0.00000000E+00 4 +CO2 L 7/88C 1O 2 0 0G 200.000 6000.000 1000. 1 + 0.46365111E+01 0.27414569E-02-0.99589759E-06 0.16038666E-09-0.91619857E-14 2 +-0.49024904E+05-0.19348955E+01 0.23568130E+01 0.89841299E-02-0.71220632E-05 3 + 0.24573008E-08-0.14288548E-12-0.48371971E+05 0.99009035E+01-0.47328105E+05 4 +H2O L 5/89H 2O 1 0 0G 200.000 6000.000 1000. 1 + 0.26770389E+01 0.29731816E-02-0.77376889E-06 0.94433514E-10-0.42689991E-14 2 +-0.29885894E+05 0.68825500E+01 0.41986352E+01-0.20364017E-02 0.65203416E-05 3 +-0.54879269E-08 0.17719680E-11-0.30293726E+05-0.84900901E+00-0.29084817E+05 4 +END