From 01be4024a8a954cf9ccc371567fcdbfb0ecdcb7d Mon Sep 17 00:00:00 2001
From: Klaus <klaus.boehnlein@tu-dresden.de>
Date: Thu, 9 Sep 2021 14:04:36 +0200
Subject: [PATCH] rename dune-microstructure.cc to Cell-Problem.cc

---
 src/CMakeLists.txt                            | 20 +++++++++++++++++--
 ...dune-microstructure.cc => Cell-Problem.cc} |  9 ++++++---
 2 files changed, 24 insertions(+), 5 deletions(-)
 rename src/{dune-microstructure.cc => Cell-Problem.cc} (99%)

diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index 79295656..402c96f0 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -1,3 +1,19 @@
-add_executable("dune-microstructure" dune-microstructure.cc)
-target_link_dune_default_libraries("dune-microstructure")
+#add_executable("dune-microstructure" dune-microstructure.cc)
+#target_link_dune_default_libraries("dune-microstructure")
+#set(CMAKE_BUILD_TYPE Debug)#
+
+
+set(programs Cell-Problem
+             )
+
+
+foreach(_program ${programs})
+  add_executable(${_program} ${_program}.cc)
+  target_link_dune_default_libraries(${_program})
+  #add_dune_pythonlibs_flags(${_program})
+  #target_link_libraries(${_program} tinyxml2)
+#  target_compile_options(${_program} PRIVATE "-fpermissive")
+endforeach()
+
+
 set(CMAKE_BUILD_TYPE Debug)
diff --git a/src/dune-microstructure.cc b/src/Cell-Problem.cc
similarity index 99%
rename from src/dune-microstructure.cc
rename to src/Cell-Problem.cc
index d820b453..21f0e885 100644
--- a/src/dune-microstructure.cc
+++ b/src/Cell-Problem.cc
@@ -1453,6 +1453,9 @@ int main(int argc, char *argv[])
     log << "b2_hat: " << B_hat[1] << std::endl;
     log << "b3_hat: " << B_hat[2] << std::endl;
     log << "mu_gamma=" << q3 << std::endl;           // added for Python-Script
+ 
+    log << std::fixed << std::setprecision(6) << "q_onetwo=" << Q[0][1] << std::endl;
+//     log << "q_onetwo=" << Q[0][1] << std::endl;           // added for Python-Script
 
     //////////////////////////////////////////////////////////////
     // Define Analytic Solutions
@@ -1595,15 +1598,15 @@ int main(int argc, char *argv[])
   vtkWriter.addVertexData(
     correctorFunction_3,
     VTK::FieldInfo("Corrector phi_3 level"+ std::to_string(level) , VTK::FieldInfo::Type::vector, dim));
-//   vtkWriter.write( VTKOutputName  + "-level"+ std::to_string(level));
-  vtkWriter.pwrite( VTKOutputName  + "-level"+ std::to_string(level), outputPath, "");
+  vtkWriter.write( VTKOutputName  + "-level"+ std::to_string(level));
+//     vtkWriter.pwrite( VTKOutputName  + "-level"+ std::to_string(level), outputPath, "");   // TEST Write to folder "/outputs" 
+//   vtkWriter.pwrite( VTKOutputName  + "-level"+ std::to_string(level), outputPath, "", VTK::OutputType::ascii, 0, 0 );
   std::cout << "wrote data to file: " + VTKOutputName + "-level" + std::to_string(level) << std::endl;      
 
   
   
    if (write_materialFunctions)
    {
-    
         using VTKGridType = YaspGrid<dim, EquidistantOffsetCoordinates<double, dim> >;
         VTKGridType grid_VTK({-1.0/2.0, -1.0/2.0, -1.0/2.0},{1.0/2.0, 1.0/2.0, 1.0/2.0},{80,80,80});
         using GridViewVTK = VTKGridType::LeafGridView;
-- 
GitLab