diff --git a/src/main.cpp b/src/main.cpp index e122cb5b90fe82c950cc5495f085b833d344d5b8..e4df1a5e7b9ff2932613f39133a43c5abc28df8c 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -180,10 +180,11 @@ int main(int argc, char *argv[]) { // gnuplot output for density const Kokkos::View<const Rd*> xj = mesh_data.xj(); - const Kokkos::View<const double*> rhoj = unknowns.rhoj(); - std::ofstream fout("rho"); + const Kokkos::View<const Rd*> uj = unknowns.uj(); + double pi = 4.*std::atan(1.); + std::ofstream fout("comparaison u"); for (size_t j=0; j<mesh.numberOfCells(); ++j) { - fout << xj[j][0] << ' ' << rhoj[j] << '\n'; + fout << xj[j][0] << ' ' << uj[j][0] << ' ' << std::sin(pi*xj[j][0])*std::exp(-pi*pi*0.2) <<'\n'; } } diff --git a/src/scheme/FiniteVolumesDiffusion.hpp b/src/scheme/FiniteVolumesDiffusion.hpp index 93440138cd94977100025b5a76d1ba7457de3298..74e59d14f8d4dd0d471f8b0a0d12b439b0bdddc0 100644 --- a/src/scheme/FiniteVolumesDiffusion.hpp +++ b/src/scheme/FiniteVolumesDiffusion.hpp @@ -102,7 +102,7 @@ private: // k = 1 - m_Fl(l)= (1./(2*Vl(l)))*sum; + m_Fl(l)= (1./Vl(l))*sum; });