From de1d4567f374e8fc94349b9d619c505adf8e480f Mon Sep 17 00:00:00 2001 From: Jorge Gonzalez Date: Thu, 9 Feb 2023 15:32:04 +0100 Subject: [PATCH] Issue for particles in quad cell Due to a high convergence value (1.0e-2) in phy2logQuad (variable conv), particles were being stuck in some elements, reaching a segmentation fault. The new limit (1.0e-4) should avoid this. --- src/modules/mesh/2DCyl/moduleMesh2DCyl.f90 | 2 +- src/modules/mesh/moduleMesh.f90 | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/modules/mesh/2DCyl/moduleMesh2DCyl.f90 b/src/modules/mesh/2DCyl/moduleMesh2DCyl.f90 index f6f2b26..f8e41b3 100644 --- a/src/modules/mesh/2DCyl/moduleMesh2DCyl.f90 +++ b/src/modules/mesh/2DCyl/moduleMesh2DCyl.f90 @@ -524,7 +524,7 @@ MODULE moduleMesh2DCyl conv = 1.D0 XiO = 0.D0 - DO WHILE(conv > 1.D-2) + DO WHILE(conv > 1.D-4) dPsi = self%dPsi(XiO, 4) pDer = self%partialDer(4, dPsi) detJ = self%detJac(pDer) diff --git a/src/modules/mesh/moduleMesh.f90 b/src/modules/mesh/moduleMesh.f90 index cb252e8..0804059 100644 --- a/src/modules/mesh/moduleMesh.f90 +++ b/src/modules/mesh/moduleMesh.f90 @@ -639,8 +639,8 @@ MODULE moduleMesh CLASS(meshCell), INTENT(inout):: self CLASS(particle), INTENT(inout), TARGET:: part CLASS(meshCell), OPTIONAL, INTENT(in):: oldCell - REAL(8):: Xi(1:3) - CLASS(meshElement), POINTER:: neighbourElement + REAL(8):: Xi(1:3) = 0.D0 + CLASS(meshElement), POINTER:: neighbourElement => NULL() INTEGER:: sp Xi = self%phy2log(part%r)