From e08ebfc6bd3e094c891a2be35d431a6bac0ccaf7 Mon Sep 17 00:00:00 2001
From: Christophe Geuzaine <cgeuzaine@uliege.be>
Date: Fri, 30 Aug 2024 10:22:18 +0200
Subject: [PATCH] use ValueOnly for OnPoint PostOperations when sending the
 value to the GUI with SendToServer

---
 Elasticity/wrench2D.pro                 | 5 ++---
 Magnetostatics/electromagnet_common.pro | 2 +-
 PotentialFlow/magnus.pro                | 4 ++--
 3 files changed, 5 insertions(+), 6 deletions(-)

diff --git a/Elasticity/wrench2D.pro b/Elasticity/wrench2D.pro
index c09f02b..de785cb 100644
--- a/Elasticity/wrench2D.pro
+++ b/Elasticity/wrench2D.pro
@@ -41,8 +41,7 @@ Poisson = DefineNumber[ 0.3, Name "Material/Poisson coefficient []"];
 AppliedForce = DefineNumber[ 100, Name "Material/Applied force [N]"];
 
 // Approximation of the maximum deflection by an analytical model:
-// Deflection = PL^3/(3EI) with I = Width^3*Thickness/12
-Deflection = DefineNumber[4*AppliedForce*((LLength-0.018)/Width)^3/(Young*Thickness)*1e3,
+Deflection = DefineNumber[-4*AppliedForce*((LLength-0.018)/Width)^3/(Young*Thickness)*1e3,
                           Name "Solution/Deflection (analytical) [mm]", ReadOnly 1];
 
 Group {
@@ -346,7 +345,7 @@ PostOperation {
       //Print[ sig_yy, OnElementsOf Wrench, File "sigyy.pos" ];
       //Print[ sig_xy, OnElementsOf Wrench, File "sigxy.pos" ];
       Print[ uy, OnPoint{probe_x, probe_y, 0},
-	     File > "deflection.pos", Format TimeTable,
+	     File > "deflection.pos", Format ValueOnly,
 	     SendToServer "Solution/Deflection (computed) [mm]", Color "AliceBlue" ];
     }
   }
diff --git a/Magnetostatics/electromagnet_common.pro b/Magnetostatics/electromagnet_common.pro
index 56879cd..3ea48db 100644
--- a/Magnetostatics/electromagnet_common.pro
+++ b/Magnetostatics/electromagnet_common.pro
@@ -1,4 +1,4 @@
 // Parameters shared by Gmsh and GetDP
 
-rInt   = 200.e-3; 
+rInt   = 200.e-3;
 rExt   = 250.e-3;
diff --git a/PotentialFlow/magnus.pro b/PotentialFlow/magnus.pro
index 75c41f0..6c38a10 100644
--- a/PotentialFlow/magnus.pro
+++ b/PotentialFlow/magnus.pro
@@ -415,11 +415,11 @@ PostOperation{ // for the Airfoil model
        // P_edge = {1.0001,0,0}
 	Print[phi, OnPoint {1.0001,0,0}, File > "KJiter.txt", Color "Ivory",
 	      StoreInVariable $phiTrailing,
-	      Format Table, SendToServer "Output/PhiTrailing"];
+	      Format ValueOnly, SendToServer "Output/PhiTrailing"];
 
         Print[Angle, OnPoint{1.0001,0,0}, File > "KJiter.txt", Color "Ivory",
 	      StoreInVariable $argV,
-	      Format Table, SendToServer "Output/argVTrailing"];
+	      Format ValueOnly, SendToServer "Output/argVTrailing"];
     }
   }
 }
-- 
GitLab