From 23077fd58c13f8f584a8e8ff30b6b5fa212ab1ce Mon Sep 17 00:00:00 2001 From: Martin Diehl Date: Wed, 21 Jul 2021 19:42:53 +0200 Subject: [PATCH] testing coordinates I don't understand why this pattern exists (with w(2) = 3, w(3) = 2), but it exists --- src/mesh/FEM_quadrature.f90 | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/src/mesh/FEM_quadrature.f90 b/src/mesh/FEM_quadrature.f90 index e76e9849f..53aadbe6f 100644 --- a/src/mesh/FEM_quadrature.f90 +++ b/src/mesh/FEM_quadrature.f90 @@ -373,12 +373,21 @@ end function permutationStar1111 !-------------------------------------------------------------------------------------------------- subroutine selfTest - integer :: o, d - + integer :: o, d, n + real(pReal), dimension(2:3), parameter :: w = [3.0_pReal,2.0_pReal] do d = lbound(FEM_quadrature_weights,1), ubound(FEM_quadrature_weights,1) do o = lbound(FEM_quadrature_weights(d,:),1), ubound(FEM_quadrature_weights(d,:),1) - if (dNeq(sum(FEM_quadrature_weights(d,o)%p),1.0_pReal,5e-15_pReal)) error stop 'quadrature weights' + if (dNeq(sum(FEM_quadrature_weights(d,o)%p),1.0_pReal,5e-15_pReal)) & + error stop 'quadrature weights' + enddo + enddo + + do d = lbound(FEM_quadrature_points,1), ubound(FEM_quadrature_points,1) + do o = lbound(FEM_quadrature_points(d,:),1), ubound(FEM_quadrature_points(d,:),1) + n = size(FEM_quadrature_points(d,o)%p,1)/d + if (any(dNeq(sum(reshape(FEM_quadrature_points(d,o)%p,[d,n]),2),-real(n,pReal)/w(d),1.e-14_pReal))) & + error stop 'quadrature points' enddo enddo