From 3a73f3d1aa2efa7450b0a444e21318c431616b08 Mon Sep 17 00:00:00 2001 From: graham Date: Wed, 11 Mar 2009 11:35:03 +0000 Subject: [PATCH] Removed boundary setting in DsmcCloud field calculation, calling correctBoundaryConditions in solver instead. --- applications/solvers/dsmc/dsmcFoam/dsmcFoam.C | 11 ++++++- .../clouds/Templates/DsmcCloud/DsmcCloudI.H | 33 ------------------- 2 files changed, 10 insertions(+), 34 deletions(-) diff --git a/applications/solvers/dsmc/dsmcFoam/dsmcFoam.C b/applications/solvers/dsmc/dsmcFoam/dsmcFoam.C index 920bdc5f20..1ea52cc6aa 100644 --- a/applications/solvers/dsmc/dsmcFoam/dsmcFoam.C +++ b/applications/solvers/dsmc/dsmcFoam/dsmcFoam.C @@ -56,21 +56,30 @@ int main(int argc, char *argv[]) dsmc.evolve(); - // Retrieve field data from dsmcCloud + // Retrieve flow field data from dsmcCloud rhoN = dsmc.rhoN(); + rhoN.correctBoundaryConditions(); rhoM = dsmc.rhoM(); + rhoM.correctBoundaryConditions(); dsmcRhoN = dsmc.dsmcRhoN(); + dsmcRhoN.correctBoundaryConditions(); momentum = dsmc.momentum(); + momentum.correctBoundaryConditions(); linearKE = dsmc.linearKE(); + linearKE.correctBoundaryConditions(); internalE = dsmc.internalE(); + internalE.correctBoundaryConditions(); iDof = dsmc.iDof(); + iDof.correctBoundaryConditions(); + + // Retrieve surface field data from dsmcCloud q = dsmc.q(); diff --git a/src/lagrangian/dsmc/clouds/Templates/DsmcCloud/DsmcCloudI.H b/src/lagrangian/dsmc/clouds/Templates/DsmcCloud/DsmcCloudI.H index 1745389cad..44ce59af50 100644 --- a/src/lagrangian/dsmc/clouds/Templates/DsmcCloud/DsmcCloudI.H +++ b/src/lagrangian/dsmc/clouds/Templates/DsmcCloud/DsmcCloudI.H @@ -358,10 +358,6 @@ Foam::DsmcCloud::rhoN() const rhoN *= nParticle_/mesh().cellVolumes(); - trhoN().boundaryField() = trhoN().boundaryField().boundaryInternalField(); - - trhoN().correctBoundaryConditions(); - return trhoN; } @@ -399,10 +395,6 @@ Foam::DsmcCloud::rhoM() const rhoM *= nParticle_/mesh().cellVolumes(); - trhoM().boundaryField() = trhoM().boundaryField().boundaryInternalField(); - - trhoM().correctBoundaryConditions(); - return trhoM; } @@ -438,11 +430,6 @@ Foam::DsmcCloud::dsmcRhoN() const dsmcRhoN[cellI]++; } - tdsmcRhoN().boundaryField() = - tdsmcRhoN().boundaryField().boundaryInternalField(); - - tdsmcRhoN().correctBoundaryConditions(); - return tdsmcRhoN; } @@ -485,11 +472,6 @@ Foam::DsmcCloud::momentum() const momentum *= nParticle_/mesh().cellVolumes(); - tmomentum().boundaryField() = - tmomentum().boundaryField().boundaryInternalField(); - - tmomentum().correctBoundaryConditions(); - return tmomentum; } @@ -527,11 +509,6 @@ Foam::DsmcCloud::linearKE() const linearKE *= nParticle_/mesh().cellVolumes(); - tlinearKE().boundaryField() = - tlinearKE().boundaryField().boundaryInternalField(); - - tlinearKE().correctBoundaryConditions(); - return tlinearKE; } @@ -569,11 +546,6 @@ Foam::DsmcCloud::internalE() const internalE *= nParticle_/mesh().cellVolumes(); - tinternalE().boundaryField() = - tinternalE().boundaryField().boundaryInternalField(); - - tinternalE().correctBoundaryConditions(); - return tinternalE; } @@ -612,11 +584,6 @@ Foam::DsmcCloud::iDof() const iDof *= nParticle_/mesh().cellVolumes(); - tiDof().boundaryField() = - tiDof().boundaryField().boundaryInternalField(); - - tiDof().correctBoundaryConditions(); - return tiDof; }