viewFactorsGen: Added test for transforming patches and issue an error
This commit is contained in:
@ -47,7 +47,7 @@ for (label proci = 0; proci < Pstream::nProcs(); proci++)
|
||||
const vector& remA = remoteArea[j];
|
||||
const label& remAgg = remoteAgg[j];
|
||||
|
||||
const vector& d = remFc - fc;
|
||||
const vector d(remFc - fc);
|
||||
|
||||
if (((d & fA) < 0.) && ((d & remA) > 0))
|
||||
{
|
||||
@ -138,7 +138,7 @@ for (label proci = 0; proci < Pstream::nProcs(); proci++)
|
||||
{
|
||||
const vector& endP = end[rayID];
|
||||
const vector& startP = hitInfo[hitIndex].hitPoint();
|
||||
const vector& d = endP - startP;
|
||||
const vector d(endP - startP);
|
||||
|
||||
startHitItself.append(startP + 0.01*d);
|
||||
endHitItself.append(startP + 1.01*d);
|
||||
|
||||
@ -2,7 +2,7 @@
|
||||
========= |
|
||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||
\\ / O peration | Website: https://openfoam.org
|
||||
\\ / A nd | Copyright (C) 2011-2018 OpenFOAM Foundation
|
||||
\\ / A nd | Copyright (C) 2011-2020 OpenFOAM Foundation
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
@ -39,18 +39,16 @@ Description
|
||||
|
||||
#include "argList.H"
|
||||
#include "Time.H"
|
||||
#include "fvMesh.H"
|
||||
#include "singleCellFvMesh.H"
|
||||
#include "volFields.H"
|
||||
#include "surfaceFields.H"
|
||||
#include "fixedValueFvPatchFields.H"
|
||||
#include "distributedTriSurfaceMesh.H"
|
||||
#include "cyclicAMIPolyPatch.H"
|
||||
#include "mapDistribute.H"
|
||||
#include "wedgePolyPatch.H"
|
||||
#include "meshTools.H"
|
||||
#include "uindirectPrimitivePatch.H"
|
||||
#include "DynamicField.H"
|
||||
#include "scalarMatrices.H"
|
||||
#include "scalarListIOList.H"
|
||||
|
||||
using namespace Foam;
|
||||
@ -251,6 +249,20 @@ int main(int argc, char *argv[])
|
||||
#include "createTime.H"
|
||||
#include "createNamedMesh.H"
|
||||
|
||||
const polyBoundaryMesh& patches = mesh.boundaryMesh();
|
||||
|
||||
forAll(patches, patchi)
|
||||
{
|
||||
const polyPatch& pp = patches[patchi];
|
||||
if (isA<cyclicTransform>(pp) || isA<wedgePolyPatch>(pp))
|
||||
{
|
||||
FatalErrorIn(args.executable()) << args.executable()
|
||||
<< " does not currently support transforming patches, "
|
||||
"cyclic and wedge."
|
||||
<< exit(FatalError);
|
||||
}
|
||||
}
|
||||
|
||||
// Read view factor dictionary
|
||||
IOdictionary viewFactorDict
|
||||
(
|
||||
@ -333,7 +345,6 @@ int main(int argc, char *argv[])
|
||||
label nCoarseFaces = 0; // total number of coarse faces
|
||||
label nFineFaces = 0; // total number of fine faces
|
||||
|
||||
const polyBoundaryMesh& patches = mesh.boundaryMesh();
|
||||
const polyBoundaryMesh& coarsePatches = coarseMesh.boundaryMesh();
|
||||
|
||||
labelList viewFactorsPatches(patches.size());
|
||||
|
||||
Reference in New Issue
Block a user