From f9a375689ebdafa62627f884a63af9284ac1bd9b Mon Sep 17 00:00:00 2001 From: Fanny CHOPOT <fanny.chopot.ocre@cea.fr> Date: Tue, 22 May 2018 09:30:41 +0200 Subject: [PATCH] nettoyage code --- src/main.cpp | 8 ++++---- src/mesh/Mesh.hpp | 4 +++- src/scheme/FiniteVolumesDiffusion.hpp | 3 +-- 3 files changed, 8 insertions(+), 7 deletions(-) diff --git a/src/main.cpp b/src/main.cpp index 810579823..3392a599b 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -196,7 +196,7 @@ int main(int argc, char *argv[]) } std::cout << "diff : " << t_diff << std::endl; } - + // DIFFUSION PURE @@ -260,7 +260,7 @@ int main(int argc, char *argv[]) { // gnuplot output for density const Kokkos::View<const Rd*> xj = mesh_data.xj(); const Kokkos::View<const Rd*> uj = unknowns.uj(); - std::ofstream fout("rho euler"); + std::ofstream fout("rho"); fout.precision(15); for (size_t j=0; j<mesh.numberOfCells(); ++j) { fout << xj[j][0] << ' ' << rhoj[j] << '\n'; @@ -271,7 +271,7 @@ int main(int argc, char *argv[]) const Kokkos::View<const Rd*> xj = mesh_data.xj(); const Kokkos::View<const Rd*> uj = unknowns.uj(); //double pi = 4.*std::atan(1.); - std::ofstream fout("u euler"); + std::ofstream fout("u"); fout.precision(15); for (size_t j=0; j<mesh.numberOfCells(); ++j) { //fout << xj[j][0] << ' ' << uj[j][0] << ' ' << std::sin(pi*xj[j][0])*std::exp(-2.*pi*pi*0.2) <<'\n'; //cas k constant @@ -284,7 +284,7 @@ int main(int argc, char *argv[]) const Kokkos::View<const Rd*> xj = mesh_data.xj(); const Kokkos::View<const double*> Ej = unknowns.Ej(); //double pi = 4.*std::atan(1.); - std::ofstream fout("E euler"); + std::ofstream fout("E"); fout.precision(15); for (size_t j=0; j<mesh.numberOfCells(); ++j) { //fout << xj[j][0] << ' ' << Ej[j] << ' ' << (-(std::cos(pi*xj[j][0])*std::cos(pi*xj[j][0]))+(std::sin(pi*xj[j][0])*std::sin(pi*xj[j][0])))*0.5*(std::exp(-4.*pi*pi*0.2)-1.) + 2. <<'\n'; // cas k constant diff --git a/src/mesh/Mesh.hpp b/src/mesh/Mesh.hpp index f1c38049b..88d07408a 100644 --- a/src/mesh/Mesh.hpp +++ b/src/mesh/Mesh.hpp @@ -64,7 +64,7 @@ public: // pas non constant - /* + /* Mesh(const Connectivity& connectivity) : m_connectivity(connectivity), m_xr("xr", connectivity.numberOfNodes()) @@ -85,7 +85,9 @@ public: } }); } + */ + ~Mesh() { ; diff --git a/src/scheme/FiniteVolumesDiffusion.hpp b/src/scheme/FiniteVolumesDiffusion.hpp index fee4ed8d6..b4a794d0f 100644 --- a/src/scheme/FiniteVolumesDiffusion.hpp +++ b/src/scheme/FiniteVolumesDiffusion.hpp @@ -418,8 +418,7 @@ public: return sum; } - - + // Verifie la conservativite de quantite de mvt double conservatif_mvt(UnknownsType& unknowns) { -- GitLab