mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
Merge branch 'master' of ssh://andy@noisy/home/noisy2/OpenFOAM/OpenFOAM-dev
This commit is contained in:
@ -70,7 +70,11 @@ PtrList<SLList<label> > slPatchCellFaces;
|
||||
// Dummy yywrap to keep yylex happy at compile time.
|
||||
// It is called by yylex but is not used as the mechanism to change file.
|
||||
// See <<EOF>>
|
||||
#if YY_FLEX_SUBMINOR_VERSION < 34
|
||||
extern "C" int yywrap()
|
||||
#else
|
||||
int yyFlexLexer::yywrap()
|
||||
#endif
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
@ -393,7 +397,7 @@ int main(int argc, char *argv[])
|
||||
}
|
||||
|
||||
// Warning: tet face order has changed between version 1.9.6 and 2.0
|
||||
//
|
||||
//
|
||||
label faceIndex[7][6] =
|
||||
{
|
||||
{-1, -1, -1, -1, -1, -1}, // 0
|
||||
|
||||
@ -116,7 +116,11 @@ void uniquify(word& name, HashSet<word>& patchNames)
|
||||
// Dummy yywrap to keep yylex happy at compile time.
|
||||
// It is called by yylex but is not used as the mechanism to change file.
|
||||
// See <<EOF>>
|
||||
#if YY_FLEX_SUBMINOR_VERSION < 34
|
||||
extern "C" int yywrap()
|
||||
#else
|
||||
int yyFlexLexer::yywrap()
|
||||
#endif
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
|
||||
@ -93,7 +93,7 @@ SLList<label> cellGroupEndIndex;
|
||||
SLList<label> cellGroupType;
|
||||
|
||||
// number of zones adjusted at run-time if necessary
|
||||
label maxZoneID = 100;
|
||||
label maxZoneID = 100;
|
||||
label zoneIDBuffer = 10;
|
||||
|
||||
wordList patchTypeIDs(maxZoneID);
|
||||
@ -102,7 +102,11 @@ wordList patchNameIDs(maxZoneID);
|
||||
// Dummy yywrap to keep yylex happy at compile time.
|
||||
// It is called by yylex but is not used as the mechanism to change file.
|
||||
// See <<EOF>>
|
||||
#if YY_FLEX_SUBMINOR_VERSION < 34
|
||||
extern "C" int yywrap()
|
||||
#else
|
||||
int yyFlexLexer::yywrap()
|
||||
#endif
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
@ -343,7 +347,7 @@ endOfSection {space}")"{space}
|
||||
// In FOAM, indices start from zero - adjust
|
||||
pointI = pointGroupStartIndex.last() - 1;
|
||||
|
||||
// reset number of components to default
|
||||
// reset number of components to default
|
||||
pointGroupNumberOfComponents = 3;
|
||||
|
||||
// read number of components in the vector
|
||||
@ -375,7 +379,7 @@ endOfSection {space}")"{space}
|
||||
|
||||
IStringStream vertexXyzStream(YYText());
|
||||
|
||||
// Note: coordinates must be read one at the time.
|
||||
// Note: coordinates must be read one at the time.
|
||||
scalar x = readScalar(vertexXyzStream);
|
||||
scalar y = readScalar(vertexXyzStream);
|
||||
|
||||
@ -387,7 +391,7 @@ endOfSection {space}")"{space}
|
||||
|
||||
IStringStream vertexXyzStream(YYText());
|
||||
|
||||
// Note: coordinates must be read one at the time.
|
||||
// Note: coordinates must be read one at the time.
|
||||
scalar x = readScalar(vertexXyzStream);
|
||||
scalar y = readScalar(vertexXyzStream);
|
||||
scalar z = readScalar(vertexXyzStream);
|
||||
@ -587,7 +591,7 @@ endOfSection {space}")"{space}
|
||||
|
||||
|
||||
// Note. Potentially skip cell set if type is zero.
|
||||
// This entry does not exist in Tgrid files.
|
||||
// This entry does not exist in Tgrid files.
|
||||
if (dimensionOfGrid == 2)
|
||||
{
|
||||
// Tgrid creating triangles
|
||||
@ -702,7 +706,7 @@ endOfSection {space}")"{space}
|
||||
|
||||
IStringStream zoneDataStream(YYText());
|
||||
|
||||
// cell zone-ID not in hexadecimal!!! Inconsistency
|
||||
// cell zone-ID not in hexadecimal!!! Inconsistency
|
||||
label zoneID(readLabel(zoneDataStream));
|
||||
|
||||
if (zoneID > maxZoneID - 1)
|
||||
@ -727,7 +731,7 @@ endOfSection {space}")"{space}
|
||||
// Fluent manual inconsistency, version 6.1.22
|
||||
IStringStream zoneDataStream(YYText());
|
||||
|
||||
// cell zone-ID not in hexadecimal!!! Inconsistency
|
||||
// cell zone-ID not in hexadecimal!!! Inconsistency
|
||||
label zoneID(readLabel(zoneDataStream));
|
||||
|
||||
if (zoneID > maxZoneID - 1)
|
||||
@ -879,7 +883,7 @@ int main(int argc, char *argv[])
|
||||
{
|
||||
scaleFactor = atof(args.options()["scale"].c_str());
|
||||
}
|
||||
|
||||
|
||||
bool writeSets = args.options().found("writeSets");
|
||||
bool writeZones = args.options().found("writeZones");
|
||||
|
||||
@ -901,7 +905,7 @@ int main(int argc, char *argv[])
|
||||
|
||||
Info<< "\n\nFINISHED LEXING\n\n\n";
|
||||
// Lookup table giving number of vertices given a fluent cell type ID
|
||||
// Currently not used.
|
||||
// Currently not used.
|
||||
// label fluentModelNVertices[7] = {-1, 3, 4, 4, 8, 5, 6};
|
||||
|
||||
// Lookup table giving number of vertices given a fluent cell type ID
|
||||
@ -973,7 +977,7 @@ int main(int argc, char *argv[])
|
||||
// Note: In order for the owner-neighbour rules to be right, the
|
||||
// points given by Fluent need to represent the FRONT plane of the
|
||||
// geometry. Therefore, the extrusion will be in -z direction
|
||||
//
|
||||
//
|
||||
forAll (oldPoints, pointI)
|
||||
{
|
||||
points[nNewPoints] = oldPoints[pointI];
|
||||
@ -1131,20 +1135,20 @@ int main(int argc, char *argv[])
|
||||
|
||||
|
||||
//make patchless mesh before analysing boundaries
|
||||
|
||||
|
||||
faceListList patches(0);
|
||||
wordList patchNames(0);
|
||||
wordList patchTypes(0);
|
||||
word defaultFacesName = "defaultFaces";
|
||||
word defaultFacesType = emptyPolyPatch::typeName;
|
||||
wordList patchPhysicalTypes(0);
|
||||
|
||||
|
||||
// Scale the points
|
||||
|
||||
|
||||
points *= scaleFactor;
|
||||
|
||||
|
||||
Info<< "Building patch-less mesh..." << flush;
|
||||
|
||||
|
||||
polyMesh pShapeMesh
|
||||
(
|
||||
IOobject
|
||||
@ -1167,13 +1171,13 @@ int main(int argc, char *argv[])
|
||||
//and zones wont be written
|
||||
//checkmesh done after patch addition as well
|
||||
Info<< "done." << endl;
|
||||
|
||||
|
||||
|
||||
|
||||
Info<< endl << "Building boundary and internal patches." << endl;
|
||||
//adding patches after mesh construction allows topological checks
|
||||
//on whether a patch is internal or external, something fluent
|
||||
//on whether a patch is internal or external, something fluent
|
||||
//doesnt seem to mind
|
||||
|
||||
|
||||
// Make boundary patches
|
||||
|
||||
SLList<label>::iterator faceGroupZoneIDIter = faceGroupZoneID.begin();
|
||||
@ -1183,7 +1187,7 @@ int main(int argc, char *argv[])
|
||||
|
||||
// Note. Not all groups of faces will be boundary patches.
|
||||
// Take care on construction
|
||||
|
||||
|
||||
//2D needs extra space for frontAndBack faces
|
||||
if (dimensionOfGrid == 2)
|
||||
{
|
||||
@ -1221,7 +1225,7 @@ int main(int argc, char *argv[])
|
||||
|
||||
Info<< "Creating patch " << nPatches
|
||||
<< " for zone: " << faceGroupZoneIDIter()
|
||||
<< " start: " << faceGroupStartIndexIter()
|
||||
<< " start: " << faceGroupStartIndexIter()
|
||||
<< " end: " << faceGroupEndIndexIter()
|
||||
<< " type: " << curPatchType << " name: " << curPatchName << endl;
|
||||
|
||||
@ -1251,7 +1255,7 @@ int main(int argc, char *argv[])
|
||||
}
|
||||
|
||||
//inlets and outlets
|
||||
if
|
||||
if
|
||||
(
|
||||
curPatchType == "pressure"
|
||||
|| curPatchType == "pressure-inlet"
|
||||
@ -1317,7 +1321,7 @@ int main(int argc, char *argv[])
|
||||
Info<< "Patch " << faceGroupZoneIDIter()
|
||||
<< ": Faces are defined but "
|
||||
<< "not created as a zone." << endl
|
||||
<< "Null specification is only valid for internal faces."
|
||||
<< "Null specification is only valid for internal faces."
|
||||
<< endl;
|
||||
|
||||
patches[nPatches] = patchFaces;
|
||||
@ -1346,14 +1350,14 @@ int main(int argc, char *argv[])
|
||||
nPatches++;
|
||||
}
|
||||
|
||||
//Now have all patch information,
|
||||
//Now have all patch information,
|
||||
//check whether each patch is internal or external
|
||||
//and add boundaries to mesh
|
||||
//also write face sets of all patches
|
||||
patches.setSize(nPatches);
|
||||
patchTypes.setSize(nPatches);
|
||||
patchNames.setSize(nPatches);
|
||||
|
||||
|
||||
|
||||
//old polyBoundary
|
||||
const polyBoundaryMesh& oPatches = pShapeMesh.boundaryMesh();
|
||||
@ -1401,12 +1405,12 @@ int main(int argc, char *argv[])
|
||||
//if a face is defined as internal but is actually external
|
||||
//it will be put in a default wall boundary
|
||||
//internal boundaries are simply ignored
|
||||
|
||||
|
||||
if(patchTypes[patchI] != "internal" && !pShapeMesh.isInternalFace(meshFaces[0]))
|
||||
{
|
||||
//first face is external and has valid non-internal type
|
||||
|
||||
//check all faces for externalness just to be sure
|
||||
//check all faces for externalness just to be sure
|
||||
//and mark patch number to global list
|
||||
forAll(meshFaces, i)
|
||||
{
|
||||
@ -1424,7 +1428,7 @@ int main(int argc, char *argv[])
|
||||
if(facePatchID[faceI - pShapeMesh.nInternalFaces()]!= -1)
|
||||
{
|
||||
FatalErrorIn(args.executable())
|
||||
<< "Face " << faceI << " on new patch "
|
||||
<< "Face " << faceI << " on new patch "
|
||||
<< patchNames[patchI]
|
||||
<< " has already been marked for repatching to"
|
||||
<< " patch "
|
||||
@ -1435,8 +1439,8 @@ int main(int argc, char *argv[])
|
||||
}
|
||||
|
||||
//add to boundary patch
|
||||
|
||||
Info<< "Adding new patch " << patchNames[patchI]
|
||||
|
||||
Info<< "Adding new patch " << patchNames[patchI]
|
||||
<< " of type " << patchTypes[patchI]
|
||||
<< " as patch " << nBoundaries << endl;
|
||||
|
||||
@ -1458,15 +1462,15 @@ int main(int argc, char *argv[])
|
||||
}
|
||||
else
|
||||
{
|
||||
Info<< "Patch " << patchNames[patchI]
|
||||
Info<< "Patch " << patchNames[patchI]
|
||||
<< " is internal to the mesh "
|
||||
<< " and is not being added to the boundary."
|
||||
<< endl;
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
// Check for any remaining boundary faces
|
||||
|
||||
// Check for any remaining boundary faces
|
||||
// and add them to a default wall patch
|
||||
// this routine should generally not be invoked
|
||||
{
|
||||
@ -1480,16 +1484,16 @@ int main(int argc, char *argv[])
|
||||
}
|
||||
}
|
||||
defaultBoundaryFaces.shrink();
|
||||
|
||||
|
||||
if(defaultBoundaryFaces.size() != 0)
|
||||
{
|
||||
Warning << " fluent mesh has " << defaultBoundaryFaces.size()
|
||||
<< " undefined boundary faces." << endl
|
||||
<< " Adding undefined faces to new patch `default_wall`"
|
||||
<< endl;
|
||||
|
||||
|
||||
// Add patch to new patch list
|
||||
|
||||
|
||||
newPatches.append
|
||||
(
|
||||
polyPatch::New
|
||||
@ -1506,11 +1510,11 @@ int main(int argc, char *argv[])
|
||||
cMeshFace += defaultBoundaryFaces.size();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
newPatches.shrink();
|
||||
|
||||
// Use facePatchIDs map to reorder boundary faces into compact regions
|
||||
|
||||
|
||||
repatchPolyTopoChanger repatcher(pShapeMesh);
|
||||
|
||||
// Add new list of patches
|
||||
@ -1544,11 +1548,11 @@ int main(int argc, char *argv[])
|
||||
// Zones
|
||||
// will write out cell zones and internal faces for those zones
|
||||
// note: zone boundary faces are not added to face zones
|
||||
// the names of boundaries bordering on cell zones are written to
|
||||
// the names of boundaries bordering on cell zones are written to
|
||||
// a list containing the boundary name and cellzone it borders on
|
||||
// interior boundaries are handled via faceSets
|
||||
// cell zones will only be written if there is more than one
|
||||
|
||||
|
||||
if (writeZones && cellGroupZoneID.size()>1)
|
||||
{
|
||||
Info<< "Adding Zones" << endl;
|
||||
@ -1559,14 +1563,14 @@ int main(int argc, char *argv[])
|
||||
|
||||
// Make face zones for cell zones
|
||||
List<faceZone*> fz(nrCellZones);
|
||||
|
||||
|
||||
// List of patch names and the cellZone(s) they border
|
||||
// this is just an info file to make MRF easier to setup
|
||||
// this is just an info file to make MRF easier to setup
|
||||
List<DynamicList<word> > boundaryZones
|
||||
(
|
||||
pShapeMesh.boundaryMesh().size()
|
||||
);
|
||||
|
||||
|
||||
const polyBoundaryMesh& bPatches = pShapeMesh.boundaryMesh();
|
||||
forAll(bPatches, pI)
|
||||
{
|
||||
@ -1591,7 +1595,7 @@ int main(int argc, char *argv[])
|
||||
|
||||
// Mark zone cells, used for finding faces
|
||||
boolList zoneCell(pShapeMesh.nCells(), false);
|
||||
|
||||
|
||||
// shift cell indizes by 1
|
||||
label nr=0;
|
||||
for (label celli = (start() - 1); celli < end(); celli++)
|
||||
@ -1645,11 +1649,11 @@ int main(int argc, char *argv[])
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
cnt++;
|
||||
}
|
||||
|
||||
|
||||
pShapeMesh.addZones(pz, fz, cz);
|
||||
|
||||
forAll(bPatches, pI)
|
||||
@ -1676,10 +1680,10 @@ int main(int argc, char *argv[])
|
||||
}
|
||||
|
||||
Info<< endl << "Writing mesh..." << flush;
|
||||
|
||||
|
||||
Info<< " to " << pShapeMesh.instance()/pShapeMesh.meshDir()
|
||||
<< " " << flush;
|
||||
|
||||
|
||||
pShapeMesh.setInstance(pShapeMesh.instance());
|
||||
pShapeMesh.write();
|
||||
Info<< "done." << endl << endl;
|
||||
|
||||
@ -78,7 +78,11 @@ label nValuesForPatchFaces = 0;
|
||||
// Dummy yywrap to keep yylex happy at compile time.
|
||||
// It is called by yylex but is not used as the mechanism to change file.
|
||||
// See <<EOF>>
|
||||
#if YY_FLEX_SUBMINOR_VERSION < 34
|
||||
extern "C" int yywrap()
|
||||
#else
|
||||
int yyFlexLexer::yywrap()
|
||||
#endif
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
@ -308,7 +312,7 @@ mtype {space}"MTYPE:"{space}
|
||||
|
||||
label nodeI(readLabel(nodeStream));
|
||||
|
||||
// Note: coordinates must be read one at the time.
|
||||
// Note: coordinates must be read one at the time.
|
||||
scalar x = readScalar(nodeStream);
|
||||
scalar y = readScalar(nodeStream);
|
||||
scalar z = readScalar(nodeStream);
|
||||
@ -676,7 +680,7 @@ int main(int argc, char *argv[])
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
labelList pointLookup(maxPointIndex + 1, -1);
|
||||
|
||||
forAll (pointMap, pointI)
|
||||
@ -806,7 +810,7 @@ int main(int argc, char *argv[])
|
||||
]
|
||||
[curFaces[faceI] - 1] // this gives a fluent face - 1
|
||||
];
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -65,7 +65,7 @@ export WM_PROJECT_USER_DIR=$HOME/$WM_PROJECT/$USER-$WM_PROJECT_VERSION
|
||||
|
||||
# Compiler: set to Gcc, Gcc43 or Icc (for Intel's icc)
|
||||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
export WM_COMPILER=Gcc43
|
||||
: ${WM_COMPILER:=Gcc}; export WM_COMPILER
|
||||
|
||||
export WM_COMPILER_ARCH=
|
||||
export WM_COMPILER_LIB_ARCH=
|
||||
|
||||
@ -57,7 +57,7 @@ setenv WM_PROJECT_USER_DIR $HOME/$WM_PROJECT/$LOGNAME-$WM_PROJECT_VERSION
|
||||
|
||||
# Compiler: set to Gcc, Gcc43 or Icc (for Intel's icc)
|
||||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
setenv WM_COMPILER Gcc43
|
||||
if ( ! $?WM_COMPILER ) setenv WM_COMPILER Gcc
|
||||
|
||||
setenv WM_COMPILER_ARCH
|
||||
setenv WM_COMPILER_LIB_ARCH
|
||||
|
||||
@ -21,7 +21,7 @@ License
|
||||
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 "CrankNicholsonDdtScheme.H"
|
||||
@ -69,7 +69,7 @@ CrankNicholsonDdtScheme<Type>::DDt0Field<GeoField>::DDt0Field
|
||||
)
|
||||
:
|
||||
GeoField(io, mesh, dimType),
|
||||
startTimeIndex_(mesh.time().timeIndex())
|
||||
startTimeIndex_(mesh.time().timeIndex())
|
||||
{}
|
||||
|
||||
|
||||
@ -324,7 +324,7 @@ CrankNicholsonDdtScheme<Type>::fvcDdt
|
||||
{
|
||||
dimensionedScalar rDtCoef0 = rDtCoef0_(ddt0);
|
||||
|
||||
ddt0.dimensionedInternalField() =
|
||||
ddt0.dimensionedInternalField() =
|
||||
(
|
||||
(rDtCoef0*dt)*(mesh().V0() - mesh().V00())
|
||||
- mesh().V00()*offCentre_(ddt0.dimensionedInternalField())
|
||||
@ -371,7 +371,7 @@ CrankNicholsonDdtScheme<Type>::fvcDdt
|
||||
{
|
||||
scalar rDtCoef0 = rDtCoef0_(ddt0).value();
|
||||
|
||||
ddt0.internalField() =
|
||||
ddt0.internalField() =
|
||||
(
|
||||
rDtCoef0*
|
||||
(
|
||||
@ -380,7 +380,7 @@ CrankNicholsonDdtScheme<Type>::fvcDdt
|
||||
) - mesh().V00()*offCentre_(ddt0.internalField())
|
||||
)/mesh().V0();
|
||||
|
||||
ddt0.boundaryField() =
|
||||
ddt0.boundaryField() =
|
||||
(
|
||||
rDtCoef0*
|
||||
(
|
||||
@ -461,7 +461,7 @@ CrankNicholsonDdtScheme<Type>::fvcDdt
|
||||
{
|
||||
scalar rDtCoef0 = rDtCoef0_(ddt0).value();
|
||||
|
||||
ddt0.internalField() =
|
||||
ddt0.internalField() =
|
||||
(
|
||||
rDtCoef0*rho.value()*
|
||||
(
|
||||
@ -470,7 +470,7 @@ CrankNicholsonDdtScheme<Type>::fvcDdt
|
||||
) - mesh().V00()*offCentre_(ddt0.internalField())
|
||||
)/mesh().V0();
|
||||
|
||||
ddt0.boundaryField() =
|
||||
ddt0.boundaryField() =
|
||||
(
|
||||
rDtCoef0*rho.value()*
|
||||
(
|
||||
@ -551,7 +551,7 @@ CrankNicholsonDdtScheme<Type>::fvcDdt
|
||||
{
|
||||
scalar rDtCoef0 = rDtCoef0_(ddt0).value();
|
||||
|
||||
ddt0.internalField() =
|
||||
ddt0.internalField() =
|
||||
(
|
||||
rDtCoef0*
|
||||
(
|
||||
@ -562,7 +562,7 @@ CrankNicholsonDdtScheme<Type>::fvcDdt
|
||||
) - mesh().V00()*offCentre_(ddt0.internalField())
|
||||
)/mesh().V0();
|
||||
|
||||
ddt0.boundaryField() =
|
||||
ddt0.boundaryField() =
|
||||
(
|
||||
rDtCoef0*
|
||||
(
|
||||
@ -658,7 +658,7 @@ CrankNicholsonDdtScheme<Type>::fvmDdt
|
||||
{
|
||||
scalar rDtCoef0 = rDtCoef0_(ddt0).value();
|
||||
|
||||
ddt0.internalField() =
|
||||
ddt0.internalField() =
|
||||
(
|
||||
rDtCoef0*
|
||||
(
|
||||
@ -668,7 +668,7 @@ CrankNicholsonDdtScheme<Type>::fvmDdt
|
||||
- mesh().V00()*offCentre_(ddt0.internalField())
|
||||
)/mesh().V0();
|
||||
|
||||
ddt0.boundaryField() =
|
||||
ddt0.boundaryField() =
|
||||
(
|
||||
rDtCoef0*
|
||||
(
|
||||
@ -693,7 +693,7 @@ CrankNicholsonDdtScheme<Type>::fvmDdt
|
||||
- offCentre_(ddt0());
|
||||
}
|
||||
|
||||
fvm.source() =
|
||||
fvm.source() =
|
||||
(
|
||||
rDtCoef*vf.oldTime().internalField()
|
||||
+ offCentre_(ddt0.internalField())
|
||||
@ -740,7 +740,7 @@ CrankNicholsonDdtScheme<Type>::fvmDdt
|
||||
{
|
||||
scalar rDtCoef0 = rDtCoef0_(ddt0).value();
|
||||
|
||||
ddt0.internalField() =
|
||||
ddt0.internalField() =
|
||||
(
|
||||
rDtCoef0*rho.value()*
|
||||
(
|
||||
@ -750,7 +750,7 @@ CrankNicholsonDdtScheme<Type>::fvmDdt
|
||||
- mesh().V00()*offCentre_(ddt0.internalField())
|
||||
)/mesh().V0();
|
||||
|
||||
ddt0.boundaryField() =
|
||||
ddt0.boundaryField() =
|
||||
(
|
||||
rDtCoef0*rho.value()*
|
||||
(
|
||||
@ -775,7 +775,7 @@ CrankNicholsonDdtScheme<Type>::fvmDdt
|
||||
- offCentre_(ddt0());
|
||||
}
|
||||
|
||||
fvm.source() =
|
||||
fvm.source() =
|
||||
(
|
||||
rDtCoef*rho.value()*vf.oldTime().internalField()
|
||||
+ offCentre_(ddt0.internalField())
|
||||
@ -823,7 +823,7 @@ CrankNicholsonDdtScheme<Type>::fvmDdt
|
||||
{
|
||||
scalar rDtCoef0 = rDtCoef0_(ddt0).value();
|
||||
|
||||
ddt0.internalField() =
|
||||
ddt0.internalField() =
|
||||
(
|
||||
rDtCoef0*
|
||||
(
|
||||
@ -835,7 +835,7 @@ CrankNicholsonDdtScheme<Type>::fvmDdt
|
||||
- mesh().V00()*offCentre_(ddt0.internalField())
|
||||
)/mesh().V0();
|
||||
|
||||
ddt0.boundaryField() =
|
||||
ddt0.boundaryField() =
|
||||
(
|
||||
rDtCoef0*
|
||||
(
|
||||
@ -865,7 +865,7 @@ CrankNicholsonDdtScheme<Type>::fvmDdt
|
||||
) - offCentre_(ddt0());
|
||||
}
|
||||
|
||||
fvm.source() =
|
||||
fvm.source() =
|
||||
(
|
||||
rDtCoef*rho.oldTime().internalField()*vf.oldTime().internalField()
|
||||
+ offCentre_(ddt0.internalField())
|
||||
@ -930,14 +930,14 @@ CrankNicholsonDdtScheme<Type>::fvcDdtPhiCorr
|
||||
{
|
||||
if (evaluate(dUdt0))
|
||||
{
|
||||
dUdt0 =
|
||||
dUdt0 =
|
||||
rDtCoef0_(dUdt0)*(U.oldTime() - U.oldTime().oldTime())
|
||||
- offCentre_(dUdt0());
|
||||
}
|
||||
|
||||
if (evaluate(dphidt0))
|
||||
{
|
||||
dphidt0 =
|
||||
dphidt0 =
|
||||
rDtCoef0_(dphidt0)*(phi.oldTime() - phi.oldTime().oldTime())
|
||||
- offCentre_(dphidt0());
|
||||
}
|
||||
@ -1065,7 +1065,7 @@ CrankNicholsonDdtScheme<Type>::fvcDdtPhiCorr
|
||||
)
|
||||
);
|
||||
}
|
||||
else if
|
||||
else if
|
||||
(
|
||||
U.dimensions() == dimVelocity
|
||||
&& phi.dimensions() == rho.dimensions()*dimVelocity*dimArea
|
||||
@ -1117,7 +1117,7 @@ CrankNicholsonDdtScheme<Type>::fvcDdtPhiCorr
|
||||
)
|
||||
);
|
||||
}
|
||||
else if
|
||||
else if
|
||||
(
|
||||
U.dimensions() == rho.dimensions()*dimVelocity
|
||||
&& phi.dimensions() == rho.dimensions()*dimVelocity*dimArea
|
||||
@ -1186,7 +1186,7 @@ tmp<surfaceScalarField> CrankNicholsonDdtScheme<Type>::meshPhi
|
||||
|
||||
if (evaluate(meshPhi0))
|
||||
{
|
||||
meshPhi0 =
|
||||
meshPhi0 =
|
||||
coef0_(meshPhi0)*mesh().phi().oldTime() - offCentre_(meshPhi0());
|
||||
}
|
||||
|
||||
|
||||
@ -50,7 +50,11 @@ int yyFlexLexer::yylex()
|
||||
// Dummy yywrap to keep yylex happy at compile time.
|
||||
// It is called by yylex but is not used as the mechanism to change file.
|
||||
// See <<EOF>>
|
||||
#if YY_FLEX_SUBMINOR_VERSION < 34
|
||||
extern "C" int yywrap()
|
||||
#else
|
||||
int yyFlexLexer::yywrap()
|
||||
#endif
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
|
||||
@ -21,7 +21,7 @@ License
|
||||
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
|
||||
|
||||
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
%{
|
||||
@ -51,7 +51,11 @@ int yyFlexLexer::yylex()
|
||||
// Dummy yywrap to keep yylex happy at compile time.
|
||||
// It is called by yylex but is not used as the mechanism to change file.
|
||||
// See <<EOF>>
|
||||
#if YY_FLEX_SUBMINOR_VERSION < 34
|
||||
extern "C" int yywrap()
|
||||
#else
|
||||
int yyFlexLexer::yywrap()
|
||||
#endif
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
@ -391,7 +395,8 @@ bool triSurface::readSTLASCII(const fileName& STLfileName)
|
||||
// Create the lexer obtaining the approximate number of vertices in the STL
|
||||
// from the file size
|
||||
STLLexer lexer(&STLstream.stdStream(), Foam::size(STLfileName)/400);
|
||||
while(lexer.lex() != 0);
|
||||
while(lexer.lex() != 0)
|
||||
{}
|
||||
|
||||
DynamicList<STLpoint>& STLpoints = lexer.STLpoints();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user