From 463bd6f0ff70c96835c6e5c1ada8bbcfab86805f Mon Sep 17 00:00:00 2001
From: Emilie Marchandise <emilie.marchandise@uclouvain.be>
Date: Tue, 6 Apr 2010 19:42:31 +0000
Subject: [PATCH] Added Aorta.lua and bcs for blood flow

---
 Geo/GFaceCompound.cpp        | 4 ++--
 Solver/function.cpp          | 6 ++++++
 Solver/multiscaleLaplace.cpp | 7 +++----
 3 files changed, 11 insertions(+), 6 deletions(-)

diff --git a/Geo/GFaceCompound.cpp b/Geo/GFaceCompound.cpp
index 14d50896f1..5dab88d033 100644
--- a/Geo/GFaceCompound.cpp
+++ b/Geo/GFaceCompound.cpp
@@ -513,8 +513,8 @@ bool GFaceCompound::parametrize() const
   else if (_mapping == CONFORMAL){
     Msg::Debug("Parametrizing surface %d with 'conformal map'", tag());
     fillNeumannBCS();
-    //bool withoutFolding = parametrize_conformal_spectral() ;
-    bool withoutFolding = parametrize_conformal();
+    bool withoutFolding = parametrize_conformal_spectral() ;
+    //bool withoutFolding = parametrize_conformal();
     if ( withoutFolding == false ){
       //printStuff(); exit(1);
       Msg::Warning("$$$ Parametrization switched to harmonic map");
diff --git a/Solver/function.cpp b/Solver/function.cpp
index 2769248eea..9b0ca8199d 100644
--- a/Solver/function.cpp
+++ b/Solver/function.cpp
@@ -400,6 +400,12 @@ void function::registerBindings(binding *b){
   mb->setDescription("return the unique instance of this class");
   cb->setParentClass<function>();
 
+  cb = b->addClass<functionSolution>("functionNormals");
+  cb->setDescription("A function to access the face normals. This is a single-instance class, use the 'get' member to access the instance.");
+  mb = cb->addMethod("get",&functionNormals::get);
+  mb->setDescription("return the unique instance of this class");
+  cb->setParentClass<function>();
+
   cb = b->addClass<functionSolutionGradient>("functionSolutionGradient");
   cb->setDescription("A function to access the gradient of the solution. This is a single-instance class, use the 'get' member to access the instance.");
   mb = cb->addMethod("get",&functionCoordinates::get);
diff --git a/Solver/multiscaleLaplace.cpp b/Solver/multiscaleLaplace.cpp
index 1da275c77e..4bb7d9b9d6 100644
--- a/Solver/multiscaleLaplace.cpp
+++ b/Solver/multiscaleLaplace.cpp
@@ -653,8 +653,7 @@ static void printLevel(const char* fn,
       if (dx)fprintf(fp, "%d %22.15E %22.15E 0\n", (*it)->getIndex(), dx[2]*(p.x()-dx[0]), dx[2]*(p.y()-dx[1]));
       else   fprintf(fp, "%d %22.15E %22.15E 0\n", (*it)->getIndex(), p.x(), p.y());
     }
-    else fprintf(fp, "%d %g %g %g\n", (*it)->getIndex(),
-                 (*it)->x(), (*it)->y(), (*it)->z());
+    else fprintf(fp, "%d %g %g %g\n", (*it)->getIndex(),(*it)->x(), (*it)->y(), (*it)->z());
   }
   fprintf(fp, "$EndNodes\n");
   
@@ -984,7 +983,7 @@ void multiscaleLaplace::parametrize (multiscaleLaplaceLevel & level){
     MElement *e = level.elements[i];
     std::vector<SPoint2> localCoord;
     double local_size = localSize(e,solution);
-    if (local_size < 1.e-5*global_size) //1.e-5
+    if (local_size < 1.e-6*global_size) //1.e-5
       tooSmall.push_back(e);
     else  goodSize.push_back(e);
   }
@@ -1033,7 +1032,7 @@ void multiscaleLaplace::parametrize (multiscaleLaplaceLevel & level){
 //       double area = fabs(triangle_area(q0, q1, q2));   
 //       totArea  += area;
       double local_size = localSize(e,solution);
-      if (local_size < 1.e-7 * global_size) //1.e-7
+      if (local_size < 1.e-8 * global_size) //1.e-7
         really_small_elements = true;
     }
     //center *= (1./regions_[i].size());
-- 
GitLab