From: ndjinga Date: Mon, 21 Sep 2020 12:28:14 +0000 (+0200) Subject: Corrected execution of tests X-Git-Tag: V9_6_0~50 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=adb8c67e7d5360c91a45c111dcb2fa9a92e59427;p=tools%2Fsolverlab.git Corrected execution of tests --- diff --git a/CDMATH/tests/examples/Poisson1DEF/FiniteElements1DPoisson.py b/CDMATH/tests/examples/Poisson1DEF/FiniteElements1DPoisson.py index d0cdae6..ff8baf5 100755 --- a/CDMATH/tests/examples/Poisson1DEF/FiniteElements1DPoisson.py +++ b/CDMATH/tests/examples/Poisson1DEF/FiniteElements1DPoisson.py @@ -139,7 +139,7 @@ plt.legend() plt.xlabel('Position') plt.ylabel('Value') plt.title('1D finite elements \n for Laplace operator') -plt.savefig('FiniteElements1DPoisson_ResultField_'+str(nbNodes) + '_nodes'+'.png') +plt.savefig("FiniteElements1DPoisson_ResultField_"+str(nbNodes) + '_nodes'+".png") print("Numerical solution of the 1D Poisson equation using finite elements done") diff --git a/CDMATH/tests/examples/Poisson1DVF/FiniteVolumes1DPoisson.py b/CDMATH/tests/examples/Poisson1DVF/FiniteVolumes1DPoisson.py index 8143b5c..db077ed 100755 --- a/CDMATH/tests/examples/Poisson1DVF/FiniteVolumes1DPoisson.py +++ b/CDMATH/tests/examples/Poisson1DVF/FiniteVolumes1DPoisson.py @@ -69,7 +69,7 @@ for i in range(nbCells): Ck=my_mesh.getCell(k) distance=Ci.getBarryCenter().distance(Ck.getBarryCenter()) coeff=Fj.getMeasure()/Ci.getMeasure()/distance - Rigidite.addValue(i,k,-coeff) # terme extradiagonal + Rigidite.setValue(i,k,-coeff) # terme extradiagonal else: coeff=Fj.getMeasure()/Ci.getMeasure()/Ci.getBarryCenter().distance(Fj.getBarryCenter()) #For the particular case where the mesh boundary does not coincide with the domain boundary diff --git a/CDMATH/tests/examples/Poisson3DVF/FiniteVolumes3DPoisson_CUBE.py b/CDMATH/tests/examples/Poisson3DVF/FiniteVolumes3DPoisson_CUBE.py old mode 100644 new mode 100755 index 14f6f8c..41c3ab0 --- a/CDMATH/tests/examples/Poisson3DVF/FiniteVolumes3DPoisson_CUBE.py +++ b/CDMATH/tests/examples/Poisson3DVF/FiniteVolumes3DPoisson_CUBE.py @@ -85,7 +85,7 @@ for i in range(nbCells): Ck=my_mesh.getCell(k) distance=Ci.getBarryCenter().distance(Ck.getBarryCenter()) coeff=Fj.getMeasure()/Ci.getMeasure()/distance - Rigidite.setValue(i,k,-coeff) # terme extradiagonal + Rigidite.addValue(i,k,-coeff) # terme extradiagonal else: coeff=Fj.getMeasure()/Ci.getMeasure()/Ci.getBarryCenter().distance(Fj.getBarryCenter()) Rigidite.addValue(i,i,coeff) # terme diagonal diff --git a/CDMATH/tests/ressources/CMakeLists.txt b/CDMATH/tests/ressources/CMakeLists.txt index f9387fc..acf794c 100755 --- a/CDMATH/tests/ressources/CMakeLists.txt +++ b/CDMATH/tests/ressources/CMakeLists.txt @@ -2,7 +2,7 @@ SET(MESH_MED2 ../ressources/ ) -file(COPY ${MESH_MED2} DESTINATION ${CMAKE_BINARY_DIR}/tests/ressources) +file(COPY ${MESH_MED2} DESTINATION ${CMAKE_BINARY_DIR}/CDMATH/tests/ressources) install(DIRECTORY ${MESH_MED2} DESTINATION share/meshes)