Browse Source

Examples now build for FEM and install to installdir/share

iss2
Trevor Irons 9 years ago
parent
commit
7171c5b069

+ 6
- 0
CMakeLists.txt View File

@@ -5,3 +5,9 @@ add_subdirectory("src")
5 5
 
6 6
 add_library( fem4ellipticpde ${FEMSOURCE} )  
7 7
 target_link_libraries(fem4ellipticpde "lemmacore")
8
+
9
+install ( TARGETS fem4ellipticpde DESTINATION ${CMAKE_INSTALL_PREFIX}/lib )
10
+
11
+if (LEMMABUILDEXAMPLES)
12
+	add_subdirectory(examples)
13
+endif()

+ 33
- 0
examples/CMakeLists.txt View File

@@ -0,0 +1,33 @@
1
+add_executable( FEM4EllipticPDE_bhmag FEM4EllipticPDE_bhmag.cpp  )
2
+target_link_libraries(  FEM4EllipticPDE_bhmag  "lemmacore" "fem4ellipticpde")
3
+
4
+add_executable( FEM4EllipticPDE FEM4EllipticPDE.cpp  )
5
+target_link_libraries(  FEM4EllipticPDE  "lemmacore" "fem4ellipticpde")
6
+
7
+add_executable( merge merge.cpp  )
8
+target_link_libraries(  merge  "lemmacore" "fem4ellipticpde")
9
+
10
+add_executable( VTKDC VTKDC.cpp  )
11
+target_link_libraries( VTKDC  "lemmacore" "fem4ellipticpde")
12
+
13
+add_executable( VTKEdgeG VTKEdgeG.cpp  )
14
+target_link_libraries( VTKEdgeG  "lemmacore" "fem4ellipticpde")
15
+
16
+add_executable( VTKEdgeGsphere VTKEdgeGsphere.cpp  )
17
+target_link_libraries( VTKEdgeGsphere  "lemmacore" "fem4ellipticpde")
18
+
19
+#INSTALL_TARGETS( "${CMAKE_INSTALL_PREFIX}/share/FEM4EllipticPDE/"
20
+INSTALL_TARGETS( "/share/FEM4EllipticPDE/"
21
+	FEM4EllipticPDE_bhmag FEM4EllipticPDE merge VTKDC VTKEdgeG VTKEdgeGsphere
22
+)
23
+
24
+install( DIRECTORY "borehole"
25
+	DESTINATION "${CMAKE_INSTALL_PREFIX}/share/FEM4EllipticPDE/"
26
+	PATTERN .svn EXCLUDE
27
+)
28
+
29
+install( DIRECTORY "DC"
30
+	DESTINATION "${CMAKE_INSTALL_PREFIX}/share/FEM4EllipticPDE/"
31
+	PATTERN .svn EXCLUDE
32
+)
33
+

+ 126
- 0
examples/DC/DC.yaml View File

@@ -0,0 +1,126 @@
1
+!<DCSurvey>
2
+NumberOfElectrodes: 9
3
+Injections:
4
+  J-0:
5
+    A: !<DCIPElectrode> &1
6
+      Node_ID: -1
7
+      Label: L0-E0
8
+      Location: !<Vector3r>
9
+        -
10
+          - 13.23
11
+          - 18.1
12
+          - -25
13
+    B: !<DCIPElectrode> &2
14
+      Location: !<Vector3r>
15
+        -
16
+          - 13.23
17
+          - 18.1
18
+          - -25
19
+      Node_ID: -1
20
+      Label: L0-E1
21
+    J: 1
22
+    Measurements:
23
+      Number: 4
24
+      V-0:
25
+        M: !<DCIPElectrode> &3
26
+          Location: !<Vector3r>
27
+            -
28
+              - 13.23
29
+              - 18.1
30
+              - -25
31
+          Node_ID: -1
32
+          Label: L0-E2
33
+        N: !<DCIPElectrode> &4
34
+          Location: !<Vector3r>
35
+            -
36
+              - 13.23
37
+              - 18.1
38
+              - -25
39
+          Node_ID: -1
40
+          Label: L0-E3
41
+      V-1:
42
+        M: !<DCIPElectrode> &5
43
+          Location: !<Vector3r>
44
+            -
45
+              - 13.23
46
+              - 18.1
47
+              - -25
48
+          Node_ID: -1
49
+          Label: L0-E4
50
+        N: !<DCIPElectrode> &6
51
+          Location: !<Vector3r>
52
+            -
53
+              - 13.23
54
+              - 18.1
55
+              - -25
56
+          Node_ID: -1
57
+          Label: L0-E5
58
+      V-2:
59
+        M: *6
60
+        N: !<DCIPElectrode> &7
61
+          Location: !<Vector3r>
62
+            -
63
+              - 13.23
64
+              - 18.1
65
+              - -25
66
+          Node_ID: -1
67
+          Label: L0-E6
68
+      V-3:
69
+        M: !<DCIPElectrode> &8
70
+          Location: !<Vector3r>
71
+            -
72
+              - 13.23
73
+              - 18.1
74
+              - -25
75
+          Node_ID: -1
76
+          Label: L0-E7
77
+        N: !<DCIPElectrode> &9
78
+          Location: !<Vector3r>
79
+            -
80
+              - 13.23
81
+              - 18.1
82
+              - -25
83
+          Node_ID: -1
84
+          Label: L0-E8
85
+  J-1:
86
+    A: *2
87
+    B: *3
88
+    J: 1
89
+    Measurements:
90
+      Number: 3
91
+      V-0:
92
+        M: *3
93
+        N: *4
94
+      V-1:
95
+        M: *5
96
+        N: *6
97
+      V-2:
98
+        M: *6
99
+        N: *7
100
+  J-2:
101
+    A: *3
102
+    B: *4
103
+    J: 1
104
+    Measurements:
105
+      Number: 3
106
+      V-0:
107
+        M: *3
108
+        N: *4
109
+      V-1:
110
+        M: *5
111
+        N: *6
112
+      V-2:
113
+        M: *6
114
+        N: *7
115
+Electrodes:
116
+  L0-E2: *3
117
+  L0-E3: *4
118
+  L0-E4: *5
119
+  L0-E5: *6
120
+  L0-E6: *7
121
+  L0-E7: *8
122
+  L0-E8: *9
123
+  L0-E0: *1
124
+  L0-E1: *2
125
+---
126
+

+ 198
- 0
examples/DC/tunnel.geo View File

@@ -0,0 +1,198 @@
1
+/* This file is part of Lemma, a geophysical modelling and inversion API.
2
+ * More information is available at http://lemmasoftware.org
3
+ */
4
+
5
+/* This Source Code Form is subject to the terms of the Mozilla Public
6
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
7
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8
+ */
9
+
10
+/**
11
+ * @file
12
+ * @date      10/31/2014 10:44:16 AM
13
+ * @version   $Id$
14
+ * @author    Trevor Irons (ti)
15
+ * @email     Trevor.Irons@xri-geo.com
16
+ * @copyright Copyright (c) 2014, XRI Geophysics, LLC
17
+ * @copyright Copyright (c) 2014, Trevor Irons
18
+ */
19
+
20
+/*********************************************************************
21
+ *  Starting model was
22
+ *  Gmsh tutorial 4, modified to give tunnel model with simple topography
23
+ *
24
+ *  Built-in functions, holes, strings, mesh color
25
+ *
26
+ *********************************************************************/
27
+
28
+// As usual, we start by defining some variables:
29
+
30
+_m = 1; // _m characteristic length thingy change to m if probably
31
+
32
+// Distance
33
+e1 = 50. * _m;        // Northing length of the whole model (twice this number)
34
+e2 = 5. * _m ;        // Width of first dip
35
+
36
+h1 = 15.5 * _m;        // height of Low wall
37
+h2 = 50 * _m;         // Height of the Low wall
38
+h5 = 2 * _m;          // Height of the Dip
39
+
40
+h3 = -8 * _m;         // Depth of tunnel
41
+h4 = 2 * _m;          // Height of tunnel
42
+
43
+he = 100*_m;           // Extrusion lengths
44
+sy = -he/2.;
45
+
46
+R1 = 1 * _m;         //  Dip, extremely fragile!
47
+R2 = 1. * _m;        //  Tunnel width
48
+
49
+// Define Electrode grid
50
+NE = 2;  // Num easting
51
+NN = 40;  // Num northing
52
+SE = -10;
53
+SN = -20;
54
+de = 1;
55
+dn = 1;
56
+
57
+Lc1 = 5.5 * _m;       // Characteristic length of thingies
58
+Lc2 = 5.5 * _m;
59
+//Lc3 = 5.5 * _m;
60
+Lc4 = 0.15*de * _m;       // Electrode sensitivity, 1/4 electrode spacing is good
61
+//Lc4 = 5.5*de * _m;       // Electrode sensitivity, 1/4 electrode spacing is good
62
+
63
+// We can use all the usual mathematical functions (note the
64
+// capitalized first letters), plus some useful functions like
65
+// Hypot(a, b) := Sqrt(a^2 + b^2):
66
+
67
+ccos = (-h5*R1 + e2 * Hypot(h5, Hypot(e2, R1))) / (h5^2 + e2^2);
68
+ssin = Sqrt(1 - ccos^2);
69
+
70
+p1 = newp;
71
+
72
+// Then we define some points and some lines using these variables:
73
+Point(p1  ) = {-e1-e2, sy, 0    ,    Lc1};
74
+Point(p1+1) = {-e1-e2, sy, h1+h2,    Lc1};
75
+Point(p1+2) = {e1+e2 , sy, h1+h2,    Lc1};
76
+Point(p1+3) = { e1+e2, sy, h1   ,    Lc1};
77
+
78
+// Defines the dip
79
+Point(p1+4)= { R1 / ssin, sy, h5+R1*ccos,  Lc2};  // p5
80
+Point(p1+5)= {-R1 / ssin, sy, h5+R1*ccos,  Lc2};  // p6
81
+
82
+// Defines something else
83
+Point(p1+6)  = {-e2 , sy, 0.0,          Lc2};
84
+
85
+/* Tunnel */ /*
86
+Point(p1+7)  = {-R2 , sy, h1+h3   ,     Lc2};
87
+Point(p1+8)  = {-R2 , sy, h1+h3+h4,     Lc2};
88
+Point(p1+9)  = { 0  , sy, h1+h3+h4,     Lc2};
89
+Point(p1+10) = { R2 , sy, h1+h3+h4,     Lc2};
90
+Point(p1+11) = { R2 , sy, h1+h3   ,     Lc2};
91
+Point(p1+12) = { 0  , sy, h1+h3   ,     Lc2};
92
+Point(p1+13) = { 0  , sy, h1+h3+h4+R2,  Lc2};
93
+Point(p1+14) = { 0  , sy, h1+h3-R2,     Lc2};
94
+*/
95
+
96
+L = newl;
97
+Line(L  ) = {p1  , p1+6};
98
+Line(L+1) = {p1+6, p1+5};
99
+Line(L+2) = {p1+5, p1+4};
100
+
101
+Line(L+3) = {p1+4, p1+3};
102
+Line(L+4) = {p1+3, p1+2};          // MAYBE SHOULD BE 11,6??
103
+Line(L+5) = {p1+2, p1+1};
104
+Line(L+6) = {p1+1, p1  };
105
+
106
+/*
107
+Line(L+7) = {p1+8, p1+7};          // TUNNEL
108
+Line(L+8) = {p1+11, p1+10};
109
+
110
+C = newc;
111
+Circle(C  ) = {p1+10,  p1+9,  p1+13};
112
+Circle(C+1) = {p1+13,  p1+9,  p1+8 };
113
+Circle(C+2) = {p1+7,   p1+12, p1+14};
114
+Circle(C+3) = {p1+14,  p1+12, p1+11};
115
+*/
116
+
117
+LL = newll;
118
+//Line Loop(LL) = {C+1, L+7, C+2, C+3, L+8, C};  // THIS IS THE TUNNEL
119
+Line Loop(LL+1) = { L, L+1, L+2, L+3, L+4, L+5, L+6 };
120
+s1 = news;
121
+//Plane Surface(s1) = {LL+1, LL};
122
+Plane Surface(s1) = {LL+1};
123
+
124
+// Extrude
125
+out[] = Extrude {0,he,0} {
126
+  Surface{s1};
127
+};
128
+
129
+//////////////////////////////////////////////////////////
130
+// Dirichlet Boundary
131
+// We don't want these to be physical surfaces, BUT, we can use them to embed point into...
132
+// Current workflow requires meshing twice, once with this and then saving .stl file then again as a vtk without.
133
+Physical Surface(2) = {s1, out[0], out[6], out[7], out[8] }; //
134
+
135
+// Mesh Volume
136
+Physical Volume(1) = {out[1]};
137
+
138
+ep = newp;
139
+Printf("%YAML 1.2") > "electrodes.yaml";
140
+Printf("---") >> "electrodes.yaml";
141
+Printf("Electrodes:") >> "electrodes.yaml";
142
+ii = 0;
143
+
144
+For iie In {0:NE-1}
145
+  For iin In {0:NN-1}
146
+      yy = SE+de*iie;   // easting
147
+      xx = SN+dn*iin;   // northing
148
+      zz = 0;
149
+      If (xx < -e2)   // Point on top shelf
150
+        Point(ep+ii) = {xx , yy, 0.0, Lc4};
151
+        Point{ep+ii} In Surface{ out[2] }; // out[2] is top shelf
152
+      EndIf
153
+      If ( xx>-e2 && xx < -R1 / ssin )
154
+        zz = (xx+e2) * (  (h5+R1*ccos) / ((e2) - (R1/ssin)) );
155
+        Point(ep+ii) = {xx, yy, zz, Lc4};
156
+        Point{ep+ii} In Surface{ out[3] }; // out[3] is next shelf
157
+      EndIf
158
+      If( xx> -R1 / ssin && xx< R1/ssin)
159
+        zz = h5+R1*ccos;
160
+        Point(ep+ii) = {xx , yy, zz, Lc4};
161
+        Point{ep+ii} In Surface{ out[4] }; // out[4] is next shelf
162
+      EndIf
163
+      If( xx>R1/ssin )
164
+        zz = h5+R1*ccos +  ( (xx-(R1/ssin)) * (  (h1-(h5+R1*ccos)) / ((e1+e2) - (R1/ssin)) ));
165
+        Point(ep+ii) = {xx , yy, zz, Lc4};
166
+        Point{ep+ii} In Surface{ out[5] }; // out[5] is next shelf
167
+      EndIf
168
+      // TODO 26 is a magic number for this file. Seems to work but check
169
+      Printf("  L%g-%g: !<DCIPElectrode> &L%g-%g", iie, iin, iie, iin) >> "electrodes.yaml";
170
+      Printf("    Node_ID: %g", 26+ii) >> "electrodes.yaml";
171
+      Printf("    Location: !<Vector3r>") >> "electrodes.yaml";
172
+      Printf("      -") >> "electrodes.yaml";
173
+      Printf("        - %f", xx) >> "electrodes.yaml";
174
+      Printf("        - %f", yy) >> "electrodes.yaml";
175
+      Printf("        - %f", zz) >> "electrodes.yaml";
176
+      //Physical Point(ii) = {ep+ii};
177
+      ii += 1;
178
+  EndFor
179
+EndFor
180
+
181
+///////////////////////////////////////////////
182
+// Attractor Field
183
+
184
+Field[1] = Attractor;
185
+Field[1].NodesList = {ep:ep+NE*NN}; //0, p0+1, p0+2, p0+3, p0+4, p, p+1, p+2, p+3, p+4};
186
+
187
+Field[2] = Threshold;
188
+Field[2].IField = 1;
189
+Field[2].LcMin = Lc4;
190
+Field[2].LcMax = Lc1;
191
+Field[2].DistMin = .1;
192
+Field[2].DistMax = 20;
193
+
194
+// Use minimum of all the fields as the background field
195
+Field[3] = Min;
196
+Field[3].FieldsList = {2};
197
+Background Field = 3;
198
+

examples/utFEM4EllipticPDE.cpp → examples/FEM4EllipticPDE.cpp View File


examples/utFEM4EllipticPDE_bhmag.cpp → examples/FEM4EllipticPDE_bhmag.cpp View File


examples/utVTKDC.cpp → examples/VTKDC.cpp View File


examples/utVTKEdgeG.cpp → examples/VTKEdgeG.cpp View File


examples/utVTKEdgeGsphere.cpp → examples/VTKEdgeGsphere.cpp View File


+ 27
- 0
examples/borehole/Makefile View File

@@ -0,0 +1,27 @@
1
+
2
+sphereG.vtu : sphere.geo
3
+	#gmsh  -3 -format vtk -o sphere.vtk  sphere.geo
4
+	../utVTKEdgeGsphere sphere.vtk .25 gravity  sphereG.vtu
5
+	#../utVTKEdgeGsphere sphere.vtk .25 magnet  sphereG.vtu
6
+
7
+sphereOut: 
8
+	../utFEM4EllipticPDE_bhmag  sphereG.vtu  sphereG.vtu   sphereOut.vtu 
9
+	#paraview --state=sliceSphere.pvsm
10
+
11
+all : sphereG.vtu sphereOut
12
+
13
+# --data=sphereOut.vtu
14
+
15
+# even finer meshing
16
+# radius = 4, u = \pm .9              analytic = \pm 1.33
17
+
18
+# Finer meshing
19
+# radius = 5, u = \pm 1.65            analytic = \pm 1.67
20
+# radius = 4, u = \pm 1.09            analytic = \pm 1.33
21
+
22
+# radius = 5, u = \pm 2.5             analytic = \pm 1.67
23
+# radius = 4, u = \pm 1.66            analytic = \pm 1.33
24
+# radius = 3, u= \pm .926 -.985       analytic = \pm 1
25
+# radius = 2, u = \pm.42              analytic = \pm .667
26
+# for radius=1,  u = \pm .111         analytic = \pm .333 
27
+# for radius=.5, u = \pm .0477 -.0462 analytic = \pm .167

+ 31
- 0
examples/borehole/Notes.txt View File

@@ -0,0 +1,31 @@
1
+Gmsh does not seem to import the group into exported VTK dataset. Therefore the following workflow seems to be 
2
+needed.
3
+
4
+In Gmsh, make a seperate .geo file for each body. Then export the grid for each physical volume into VTK format.
5
+Then you load all of these in Paraview, Use Calculator to assign values, and then use AppendDatasets. Then you 
6
+can save as a .vtu file. 
7
+
8
+For just the grid, you can save the whole Gmsh grid as a VTK grid. 
9
+
10
+=================================================================================================================
11
+
12
+Since we only want \nabla \cdot M on the calculation mesh do the following:
13
+
14
+	I.
15
+		1: In Gmsh make .vtk files for Grid_merge 
16
+		2: In Gmsh make .vtk files for BoreholeMagnetPlus (2D grid!) 
17
+			When doing this make sure you save all in the GUI. Or else no cells are exported.     
18
+ 
19
+	II. In Paraview
20
+		1. Open Grid_merge.vtk file
21
+		2. Open BoreholeMagnetPlus.vtk file
22
+			->Use Calculator assign 0 to everything
23
+			->Clip with normal
24
+				Use Calculator to assign -1
25
+			-> Clip with -normal 
26
+				Use Calculator to assign 1
27
+			-> Clip of ends. 
28
+		3. cntrl-click the three Calculator datasets. And use AppendDatasets Filter.
29
+		4. Save Data (Select Appended) as .vtu
30
+		5. Disco  		
31
+

+ 100
- 0
examples/borehole/boreholeMagnet.geo View File

@@ -0,0 +1,100 @@
1
+/**
2
+ *  Trevor P. Irons, XRI Geophysics, LLC
3
+ *  Test of Coloumbic Magnetic Potential
4
+ */
5
+
6
+lc =   .01;   // Target element size
7
+R =    .25;   // Magnet Radius
8
+D0 = 10;      // Top of magnet
9
+D1 = 11;      // Bottom of magnet
10
+
11
+// Total Solution Space
12
+X0 = -1.;
13
+X1 =  1.;
14
+Y0 = -1.;
15
+Y1 =  1.;
16
+Z0 =  9.5;
17
+Z1 = 11.5;
18
+
19
+////////////////////////////////////
20
+// North Pole
21
+p = newp;
22
+dd = 5;
23
+d = lc/(1*dd);
24
+Point(p) =   { 0,  0, D0, lc/dd};
25
+Point(p+1) = { R,  d, D0, lc/dd};
26
+Point(p+2) = { R, -d, D0, lc/dd};
27
+Point(p+3) = {-R,  d, D0, lc/dd};
28
+Point(p+4) = {-R, -d, D0, lc/dd};
29
+
30
+// Connect up the points
31
+c = newc;
32
+Circle(c)  = {p+3, p, p+1};
33
+
34
+c2 = newc;
35
+Circle(c2)  = {p+4, p, p+2};
36
+
37
+ss = news;
38
+ss = Extrude {0, 0, D1-D0} { Line{c}; };
39
+
40
+ss2 = news;
41
+ss2 = Extrude {0, 0, D1-D0} { Line{c2}; };
42
+
43
+
44
+//Symmetry { 1.0, 1.0, 1.0, 0.0 }{Duplicata{Surface{ss[1]};}}
45
+//lcs = newl;
46
+//lcs = Symmetry { 0.0, 0.0,.0001, 0.0 }{Duplicata{Line{c};}};
47
+//lcs =
48
+//Symmetry { 0.0, 1.0, 0.0, 0.0 }{Duplicata{Line{c};}}
49
+
50
+//Symmetry {0, 0, 120, 0} {
51
+// Duplicata{Surface{ss[1]};}
52
+//}
53
+
54
+
55
+
56
+
57
+//ss2 = news;
58
+//ss = Extrude {0, 0, D1-D0} { Line{c, lcs}; };
59
+//ss2 = Extrude {0, 0, D1-D0} { Line{l, lcs}; };
60
+
61
+//Symmetry {1,0,0,0}{ Duplicata{Surface{ss[1]};}};
62
+//Symmetry{ expression-list }{ transform-list }:
63
+
64
+//ss2 = news;
65
+//ss2 = Extrude {0, 0, D1-D0} { Line{c2, l2}; };
66
+
67
+/////////////////////////////////////
68
+// Large Bounding box
69
+pp = newp;
70
+Point(pp)    = {X0, Y0, Z0, lc};
71
+Point(pp+1)  = {X1, Y0, Z0, lc};
72
+Point(pp+2)  = {X1, Y1, Z0, lc};
73
+Point(pp+3)  = {X0, Y1, Z0, lc};
74
+
75
+
76
+lv = newl;
77
+Line(lv) = {pp,pp+1};
78
+Line(lv+1) = {pp+1,pp+2};
79
+Line(lv+2) = {pp+2,pp+3};
80
+Line(lv+3) = {pp+3,pp};
81
+Line Loop(lv+4) = {lv, lv+1, lv+2, lv+3};
82
+
83
+// Hard coded doom
84
+Plane Surface(125) = {lv+4};
85
+
86
+//v = newv;
87
+v[] = Extrude {0, 0, Z1-Z0} { Surface{125}; };
88
+
89
+Surface{ss[1]} In Volume{v[1]};
90
+Surface{ss2[1]} In Volume{v[1]};
91
+
92
+Physical Volume(1) = {v[1]};
93
+
94
+//Physical Volume("minus") = {1};
95
+//Physical Volume("background") = {3};
96
+//Coherence;
97
+
98
+//Coherence;
99
+
100
+//Mesh.RecombineAll = 1;

+ 120
- 0
examples/borehole/boreholeMagnetGrid.geo View File

@@ -0,0 +1,120 @@
1
+/**
2
+ *  Trevor P. Irons, XRI Geophysics, LLC
3
+ *  Test of Coloumbic Magnetic Potential
4
+ */
5
+
6
+lc = 1e-2;   // Target element size
7
+R =  .05;    // Magnet Radius
8
+D0 = 9.5;    // Top of mesh
9
+D1 = 11.5;   // Bottom of mesh
10
+
11
+// Total Solution Space
12
+X0 = -2.;
13
+X1 =  2.;
14
+Y0 = -2.;
15
+Y1 =  2.;
16
+//Z0 =  9.5;
17
+//Z1 = 11.5;
18
+
19
+////////////////////////////////////
20
+// North Pole
21
+
22
+Function Ring
23
+    X *= 1.2;
24
+    // North Pole
25
+    p0 = newp; Point(p0) = {   0,   0, D0, lc};
26
+    p1 = newp; Point(p1) = { X*R,   0, D0, lc};
27
+    p2 = newp; Point(p2) = {   0, X*R, D0, lc};
28
+    p3 = newp; Point(p3) = {-X*R,   0, D0, lc};
29
+
30
+    c1 = newc; Circle(c1) = {p1, p0, p3};
31
+    l1 = newl; Line(l1) = {p3,p1};
32
+    l2 = newl; Line Loop(l2) = {c1, l1};
33
+    s1 = news; Plane Surface(s1) = {l2};
34
+    Extrude {0, 0, D1-D0} { Surface{s1};  }
35
+
36
+    // South Pole
37
+    p4 = newp; Point(p4)  = {   0,  -0.0001, D0, lc}; //  8
38
+    p5 = newp; Point(p5)  = { X*R,  -0.0001, D0, lc}; //  9
39
+    p6 = newp; Point(p6)  = {   0,  -X*R,    D0, lc}; // 10
40
+    p7 = newp; Point(p7)  = {-X*R,  -0.0001, D0, lc}; // 11
41
+
42
+    c2 = newc; Circle(c2) = {p7, p4, p5};
43
+    l3 = newl; Line(l3) = {p5,p7};
44
+    l4 = newl; Line Loop(l4) = {c2, l3};
45
+    s2 = news; Plane Surface(s2) = {l4};
46
+    Extrude {0, 0, D1-D0} { Surface{s2};  }
47
+
48
+    //Compound Volume(4) = {vol2[1], vol3[1]};
49
+
50
+//Circle(12) = {11, 8, 9};
51
+//Line(13) = {9, 11};
52
+//Line Loop(14) = {12, 13};
53
+//Plane Surface(15) = {14};
54
+
55
+Return
56
+
57
+X = 1.;
58
+For r In {1:10}
59
+  Call Ring;
60
+EndFor
61
+
62
+/*
63
+
64
+Point(0) = { 0, 0, D0, lc};
65
+Point(1) = { R, 0, D0, lc};
66
+Point(2) = { 0, R, D0, lc};
67
+Point(3) = {-R, 0, D0, lc};
68
+
69
+// Connect up the points
70
+Circle(4) = {1, 0, 3};
71
+Line(5) = {3,1};
72
+Line Loop(6) = {4,5};
73
+Plane Surface(7) = {6};
74
+
75
+////////////////////////////////////
76
+// South Pole
77
+
78
+Point(8)  = { 0,  -0.0001, D0, lc};
79
+Point(9)  = { R,  -0.0001, D0, lc};
80
+Point(10) = { 0, -R, D0, lc};
81
+Point(11) = {-R,  -0.0001, D0, lc};
82
+
83
+// Connect up the points
84
+Circle(12) = {11, 8, 9};
85
+Line(13) = {9, 11};
86
+Line Loop(14) = {12, 13};
87
+Plane Surface(15) = {14};
88
+
89
+//////////////////////////////////////
90
+// Extrude magnet
91
+Extrude {0, 0, D1-D0} { Surface{7};  }
92
+Extrude {0, 0, D1-D0} { Surface{15}; }
93
+
94
+/////////////////////////////////////
95
+// Large Bounding box
96
+Point(116)  = {X0, Y0, Z0};
97
+Point(117)  = {X1, Y0, Z0};
98
+Point(118)  = {X1, Y1, Z0};
99
+Point(119)  = {X0, Y1, Z0};
100
+Line(120) = {116,117};
101
+Line(121) = {117,118};
102
+Line(122) = {118,119};
103
+Line(123) = {119,116};
104
+Line Loop(124) = {120, 121, 122, 123};
105
+Plane Surface(125) = {124};
106
+Extrude {0, 0, Z1-Z0} { Surface{125}; }
107
+
108
+//////////////////////////////////////
109
+// Rings of sensitivity calculation
110
+//Circle(222) = {2.*1, 0, 2.*2};
111
+
112
+
113
+//////////////////////////////////////
114
+// Volumes
115
+
116
+Physical Volume("plus") = {2};
117
+Physical Volume("minus") = {1};
118
+Physical Volume("background") = {3};
119
+Coherence;
120
+*/

+ 85
- 0
examples/borehole/boreholeMagnetGrid_merge.geo View File

@@ -0,0 +1,85 @@
1
+/**
2
+ *  Trevor P. Irons, XRI Geophysics, LLC
3
+ *  Test of Coloumbic Magnetic Potential
4
+ */
5
+
6
+lc = 1e-2;     // Target element size
7
+R  =  .11;     // Minimum Radius
8
+R2 =  .175;    // Minimum Radius
9
+D0 = 9.75;     // Top of mesh
10
+D1 = 11.25;    // Bottom of mesh
11
+
12
+////////////////////////////////////
13
+// North Pole
14
+
15
+Function Ring
16
+
17
+    // centre
18
+    p0 = newp; Point(p0) = {   0,    0, D0, lc};
19
+
20
+    // Points defining outer ring
21
+    p1 = newp; Point(p1) = { R,  0, D0, lc};
22
+    p2 = newp; Point(p2) = { 0,  R, D0, lc};
23
+    p3 = newp; Point(p3) = {-R,  0, D0, lc};
24
+    p4 = newp; Point(p4) = { 0, -R, D0, lc};
25
+
26
+    c1 = newc; Circle(c1) = {p1, p0, p2};
27
+    c2 = newc; Circle(c2) = {p2, p0, p3};
28
+    c3 = newc; Circle(c3) = {p3, p0, p4};
29
+    c4 = newc; Circle(c4) = {p4, p0, p1};
30
+
31
+    // Inner ring
32
+    p5 = newp; Point(p5) = { R2,   0, D0, lc};
33
+    p6 = newp; Point(p6) = {  0,  R2, D0, lc};
34
+    p7 = newp; Point(p7) = {-R2,   0, D0, lc};
35
+    p8 = newp; Point(p8) = {  0, -R2, D0, lc};
36
+
37
+    c5 = newc; Circle(c5) = {p5, p0, p6};
38
+    c6 = newc; Circle(c6) = {p6, p0, p7};
39
+    c7 = newc; Circle(c7) = {p7, p0, p8};
40
+    c8 = newc; Circle(c8) = {p8, p0, p5};
41
+
42
+    l1 = newl; Line Loop(l1) = {c1, c2, c3, c4, c5, c6, c7, c8};
43
+
44
+    s1 = news; Plane Surface(s1) = {l1};
45
+    Extrude {0,0,D1-D0} {
46
+      Surface{s1};
47
+    }
48
+
49
+Return
50
+
51
+Function Cyl
52
+
53
+    // centre
54
+    p0 = newp; Point(p0) = {   0,    0, D0, lc};
55
+
56
+    // Points defining outer ring
57
+    p1 = newp; Point(p1) = { R2,   0, D0, lc};
58
+    p2 = newp; Point(p2) = {  0,  R2, D0, lc};
59
+    p3 = newp; Point(p3) = {-R2,   0, D0, lc};
60
+    p4 = newp; Point(p4) = {  0, -R2, D0, lc};
61
+
62
+    c1 = newc; Circle(c1) = {p1, p0, p2};
63
+    c2 = newc; Circle(c2) = {p2, p0, p3};
64
+    c3 = newc; Circle(c3) = {p3, p0, p4};
65
+    c4 = newc; Circle(c4) = {p4, p0, p1};
66
+
67
+    l1 = newl; Line Loop(l1) = {c1, c2, c3, c4};
68
+
69
+    s1 = news; Plane Surface(s1) = {l1};
70
+    Extrude {0,0,D1-D0} {
71
+      Surface{s1};
72
+    }
73
+
74
+Return
75
+
76
+
77
+Call Cyl;
78
+/*
79
+For r In {1:12}
80
+  Call Ring;
81
+  R2 = R;
82
+  R *= 1.2;
83
+  lc *= 1.1;
84
+EndFor
85
+*/

+ 75
- 0
examples/borehole/boreholeMagnetMinus.geo View File

@@ -0,0 +1,75 @@
1
+/**
2
+ *  Trevor P. Irons, XRI Geophysics, LLC
3
+ *  Test of Coloumbic Magnetic Potential
4
+ */
5
+
6
+lc = 1e-2;   // Target element size
7
+R = .05;   // Magnet Radius
8
+D0 = 10;   // Top of magnet
9
+D1 = 11;   // Bottom of magnet
10
+
11
+// Total Solution Space
12
+X0 = -2.;
13
+X1 =  2.;
14
+Y0 = -2.;
15
+Y1 =  2.;
16
+Z0 =  9.;
17
+Z1 = 12.;
18
+
19
+////////////////////////////////////
20
+// North Pole
21
+/*
22
+Point(0) = { 0, 0, D0, lc};
23
+Point(1) = { R, 0, D0, lc};
24
+Point(2) = { 0, R, D0, lc};
25
+Point(3) = {-R, 0, D0, lc};
26
+
27
+// Connect up the points
28
+Circle(4) = {1, 0, 3};
29
+Line(5) = {3,1};
30
+Line Loop(6) = {4,5};
31
+Plane Surface(7) = {6};
32
+*/
33
+
34
+
35
+////////////////////////////////////
36
+// South Pole
37
+
38
+Point(8)  = { 0,  -0.0001, D0, lc};
39
+Point(9)  = { R,  -0.0001, D0, lc};
40
+Point(10) = { 0, -R, D0, lc};
41
+Point(11) = {-R,  -0.0001, D0, lc};
42
+
43
+// Connect up the points
44
+Circle(12) = {11, 8, 9};
45
+Line(13) = {9, 11};
46
+Line Loop(14) = {12, 13};
47
+Plane Surface(15) = {14};
48
+
49
+
50
+//////////////////////////////////////
51
+// Extrude magnet
52
+//Extrude {0, 0, D1-D0} { Surface{7};  }
53
+Extrude {0, 0, D1-D0} { Surface{15}; }
54
+
55
+/*
56
+// Large Bounding box
57
+Point(116)  = {X0, Y0, Z0};
58
+Point(117)  = {X1, Y0, Z0};
59
+Point(118)  = {X1, Y1, Z0};
60
+Point(119)  = {X0, Y1, Z0};
61
+Line(120) = {116,117};
62
+Line(121) = {117,118};
63
+Line(122) = {118,119};
64
+Line(123) = {119,116};
65
+Line Loop(124) = {120, 121, 122, 123}; 
66
+Plane Surface(125) = {124};
67
+Extrude {0, 0, Z1-Z0} { Surface{125}; }
68
+*/
69
+
70
+//////////////////////////////////////
71
+// Volumes
72
+
73
+Physical Volume("plus") = {2};
74
+Physical Volume("minus") = {1};
75
+//Physical Volume("background") = {3};

+ 175
- 0
examples/borehole/boreholeMagnetPlus.geo View File

@@ -0,0 +1,175 @@
1
+/**
2
+ *  Trevor P. Irons, XRI Geophysics, LLC
3
+ *  Test of Coloumbic Magnetic Potential
4
+ */
5
+
6
+
7
+Function Cyl
8
+    // centre
9
+    pp0 = newp; Point(pp0) = {   0,    0, D0, lc2};
10
+
11
+    // Points defining outer ring
12
+    pp1 = newp; Point(pp1) = { R2,   0, D0, lc2};
13
+    pp2 = newp; Point(pp2) = {  0,  R2, D0, lc2};
14
+    pp3 = newp; Point(pp3) = {-R2,   0, D0, lc2};
15
+    pp4 = newp; Point(pp4) = {  0, -R2, D0, lc2};
16
+
17
+    cc1 = newc; Circle(cc1) = {pp1, pp0, pp2};
18
+    cc2 = newc; Circle(cc2) = {pp2, pp0, pp3};
19
+    cc3 = newc; Circle(cc3) = {pp3, pp0, pp4};
20
+    cc4 = newc; Circle(cc4) = {pp4, pp0, pp1};
21
+
22
+    ll1 = newl; Line Loop(ll1) = {cc1, cc2, cc3, cc4};
23
+
24
+    ss1 = news; Plane Surface(ss1) = {ll1};
25
+    //v1 = newv; v1 =
26
+    //newv vol2;
27
+    vol2[] = Extrude {0, 0, D1-D0} { Surface{ss1}; };
28
+
29
+Return
30
+
31
+lc = 5e-2;   // Target element size
32
+R = .05;   // Magnet Radius
33
+D0 = 10;   // Top of magnet
34
+D1 = 11;   // Bottom of magnet
35
+
36
+
37
+p0 = newp; Point(p0) = { 0, 0, D0, lc};
38
+p1 = newp; Point(p1) = { R, 0, D0, lc};
39
+p2 = newp; Point(p2) = { 0, R, D0, lc};
40
+p3 = newp; Point(p3) = {-R, 0, D0, lc};
41
+p4 = newp; Point(p4) = { 0,-R, D0, lc};
42
+
43
+c1 = newc; Circle(c1) = {p1, p0, p2};
44
+c2 = newc; Circle(c2) = {p2, p0, p3};
45
+c3 = newc; Circle(c3) = {p3, p0, p4};
46
+c4 = newc; Circle(c4) = {p4, p0, p1};
47
+
48
+
49
+ll0 = newl; Line Loop(ll0) = {1,2,3,4};
50
+Plane Surface(6) = {5};
51
+vol2[] = Extrude {0,0,D1-D0} {
52
+  Surface{6};
53
+};
54
+
55
+
56
+/*
57
+vol1[] = Extrude {0, 0, D1-D0} { Line{c1:c4}; };
58
+*/
59
+////////////////////////////////////////////////////
60
+// Big Cylinder
61
+////////////////////////////////////////////////////
62
+/*
63
+lc2 = 1e-2;    // Target element size
64
+R2 =  .175;    // Minimum Radius
65
+D0 = 9.75;     // Top of mesh
66
+D1 = 11.25;    // Bottom of mesh
67
+
68
+Call Cyl;
69
+
70
+//newv vol3;
71
+//Compound Volume(vol3) = {vol1[1], vol2[1]};
72
+
73
+
74
+Field[1] = Attractor;
75
+Field[1].NodesList = {p0,p1,p2,p3,p4};
76
+
77
+Field[2] = Threshold;
78
+Field[2].IField = 1;
79
+Field[2].LcMin = lc / 5;
80
+Field[2].LcMax = lc;
81
+Field[2].DistMin = 0.05;
82
+Field[2].DistMax = 0.5;
83
+
84
+// Use minimum of all the fields as the background field
85
+Field[3] = Min;
86
+Field[3].FieldsList = {2};
87
+Background Field = 2;
88
+
89
+// Don't extend the elements sizes from the boundary inside the domain
90
+Mesh.CharacteristicLengthExtendFromBoundary = 0;
91
+Mesh.CharacteristicLengthFromPoints = 1 ;
92
+*/
93
+Mesh 3;
94
+
95
+/*
96
+Delete { Volume{vol1[1]}; }
97
+Delete { Volume{vol2[1]}; }
98
+
99
+Delete { Point{p0}; }
100
+Delete { Point{p1}; }
101
+Delete { Point{p2}; }
102
+Delete { Point{p3}; }
103
+Delete { Point{p4}; }
104
+
105
+Delete { Line{c1}; }
106
+Delete { Line{c2}; }
107
+Delete { Line{c3}; }
108
+Delete { Line{c4}; }
109
+*/
110
+//Delete { Line{ll0}; }
111
+//Delete { Volume{vol2}; }
112
+
113
+
114
+
115
+
116
+
117
+
118
+/*
119
+////////////////////////////////////
120
+// South Pole
121
+
122
+Point(8)  = { 0,  -0.0001, D0, lc};
123
+Point(9)  = { R,  -0.0001, D0, lc};
124
+Point(10) = { 0, -R, D0, lc};
125
+Point(11) = {-R,  -0.0001, D0, lc};
126
+
127
+// Connect up the points
128
+Circle(12) = {11, 8, 9};
129
+Line(13) = {9, 11};
130
+Line Loop(14) = {12, 13};
131
+Plane Surface(15) = {14};
132
+*/
133
+
134
+//////////////////////////////////////
135
+// Extrude magnet
136
+//Extrude {0, 0, D1-D0} { Surface{7};  }
137
+//Extrude {0, 0, D1-D0} { Surface{15}; }
138
+
139
+/*
140
+// Large Bounding box
141
+Point(116)  = {X0, Y0, Z0};
142
+Point(117)  = {X1, Y0, Z0};
143
+Point(118)  = {X1, Y1, Z0};
144
+Point(119)  = {X0, Y1, Z0};
145
+Line(120) = {116,117};
146
+Line(121) = {117,118};
147
+Line(122) = {118,119};
148
+Line(123) = {119,116};
149
+Line Loop(124) = {120, 121, 122, 123};
150
+Plane Surface(125) = {124};
151
+Extrude {0, 0, Z1-Z0} { Surface{125}; }
152
+*/
153
+
154
+//////////////////////////////////////
155
+// Volumes
156
+
157
+//Physical Volume("plus") = {2};
158
+//Physical Volume("minus") = {1};
159
+//Physical Volume("background") = {3};
160
+/*
161
+Delete {
162
+  Surface{9};
163
+}
164
+Delete {
165
+  Surface{13};
166
+}
167
+Delete {
168
+  Surface{17};
169
+}
170
+Delete {
171
+  Surface{21};
172
+}
173
+*/
174
+Compound Volume(49) = {1};
175
+Compound Volume(50) = {49, 1};

+ 146
- 0
examples/borehole/sphere.geo View File

@@ -0,0 +1,146 @@
1
+/* This file is part of Lemma, a geophysical modelling and inversion API.
2
+ * More information is available at http://lemmasoftware.org
3
+ */
4
+
5
+/* This Source Code Form is subject to the terms of the Mozilla Public
6
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
7
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8
+ */
9
+
10
+/**
11
+ * @file
12
+ * @date      08/08/2014 12:19:20 PM
13
+ * @version   $Id$
14
+ * @author    Trevor Irons (ti)
15
+ * @email     Trevor.Irons@xri-geo.com
16
+ * @copyright Copyright (c) 2014, XRI Geophysics, LLC
17
+ * @copyright Copyright (c) 2014, Trevor Irons
18
+ */
19
+
20
+
21
+D0 = 10;          // Top of magnet
22
+D1 = 11;          // Bottom of magnet
23
+radius = 2.25;     // Radius of the damn thing
24
+
25
+lc = radius*10;   //  0.25;   // Target element size
26
+
27
+// Total Solution Space
28
+Box = 10*radius; // The down side of potential
29
+X0 = -Box;
30
+X1 =  Box;
31
+Y0 = -Box;
32
+Y1 =  Box;
33
+Z0 = -Box;
34
+Z1 =  Box;
35
+
36
+cellSize=lc; //300;
37
+dd = 0 ; //  1e-5; //cellSize; // .01;
38
+pio2=Pi/2;
39
+
40
+// Calculate offset effect
41
+theta = Asin(dd/radius);
42
+rr = radius * Cos(theta);
43
+
44
+///////////////////////////////////
45
+// Positive half sphere
46
+// create inner 1/8 shell
47
+p0 = newp;
48
+Point(p0)   = {      0,   0,       0, cellSize}; // origin
49
+Point(p0+1) = {    -rr,   0,      dd, cellSize};
50
+Point(p0+2) = {      0,  rr,      dd, cellSize};
51
+Point(p0+3) = {      0,   0,  radius, cellSize};
52
+Point(p0+4) = {      0,   0,      dd, cellSize}; // origin
53
+
54
+c0 = newc;
55
+Circle(c0  ) = {p0+1, p0+4, p0+2};       // Tricky, This one needs to be offset!
56
+Circle(c0+1) = {p0+3, p0, p0+1};
57
+Circle(c0+2) = {p0+3, p0, p0+2};
58
+
59
+Line Loop(10) = {c0, -(c0+2), c0+1} ;
60
+Ruled Surface (60) = {10};
61
+
62
+////////////////////////////////////////////////////////////
63
+// Negative half sphere
64
+p = newp;
65
+Point(  p) = {      0,      0,            0, cellSize};
66
+Point(p+1) = {    -rr,      0,          -dd, cellSize};
67
+Point(p+2) = {      0,     rr,          -dd, cellSize};
68
+Point(p+3) = {      0,      0,      -radius, cellSize};
69
+Point(p+4) = {      0,      0,          -dd, cellSize};
70
+
71
+cc = newc;
72
+Circle(cc  ) = {p+1, p+4, p+2};
73
+Circle(cc+1) = {p+3, p,   p+1};
74
+Circle(cc+2) = {p+3, p,   p+2};
75
+
76
+Circle(cc+3) = {p+3, p, p+2};
77
+Circle(cc+4) = {p+3, p, p+2};
78
+Circle(cc+5) = {p+3, p, p+2};
79
+
80
+ccl = newl;
81
+Line(ccl) = { p0+3, p+3 };
82
+
83
+Line Loop(11) = {cc, -(cc+2), cc+1} ;
84
+Ruled Surface (61) = {11};
85
+
86
+// create remaining 7/8 inner shells
87
+t1[] = Rotate {{0,0,1},{0,0,0},pio2  } {Duplicata{Surface{60};}};
88
+t2[] = Rotate {{0,0,1},{0,0,0},pio2*2} {Duplicata{Surface{60};}};
89
+t3[] = Rotate {{0,0,1},{0,0,0},pio2*3} {Duplicata{Surface{60};}};
90
+//
91
+t4[] = Rotate {{0,0,1},{0,0,0},pio2  } {Duplicata{Surface{61};}};
92
+t5[] = Rotate {{0,0,1},{0,0,0},pio2*2} {Duplicata{Surface{61};}};
93
+t6[] = Rotate {{0,0,1},{0,0,0},pio2*3} {Duplicata{Surface{61};}};
94
+
95
+/////////////////////////////////////
96
+// Large Bounding box
97
+pp = newp;
98
+Point(pp)    = {X0, Y0, Z0, lc};
99
+Point(pp+1)  = {X1, Y0, Z0, lc};
100
+Point(pp+2)  = {X1, Y1, Z0, lc};
101
+Point(pp+3)  = {X0, Y1, Z0, lc};
102
+
103
+
104
+lv = newl;
105
+Line(lv) = {pp,pp+1};
106
+Line(lv+1) = {pp+1,pp+2};
107
+Line(lv+2) = {pp+2,pp+3};
108
+Line(lv+3) = {pp+3,pp};
109
+Line Loop(lv+4) = {lv, lv+1, lv+2, lv+3};
110
+
111
+// Hard coded doom
112
+Plane Surface(125) = {lv+4};
113
+
114
+//v = newv;
115
+v[] = Extrude {0, 0, Z1-Z0} { Surface{125}; };
116
+
117
+/* This is GOOD */
118
+Surface{60} In Volume{v[1]};
119
+Surface{t1[0]} In Volume{v[1]};
120
+Surface{t2[0]} In Volume{v[1]};
121
+Surface{t3[0]} In Volume{v[1]};
122
+
123
+Surface{61} In Volume{v[1]};
124
+Surface{t4[0]} In Volume{v[1]};
125
+Surface{t5[0]} In Volume{v[1]};
126
+Surface{t6[0]} In Volume{v[1]};
127
+
128
+///////////////////////////////////////////////
129
+// Attractor Field
130
+
131
+Field[1] = Attractor;
132
+Field[1].NodesList = {p}; //0, p0+1, p0+2, p0+3, p0+4, p, p+1, p+2, p+3, p+4};
133
+
134
+Field[2] = MathEval;
135
+//Field[2].F = Sprintf("(.25 - F1)^2 + %g", cellSize );  // WORKS
136
+Field[2].F = Sprintf("(%g - F1)^2 + %g", radius, cellSize/2. );
137
+Background Field = 2;
138
+
139
+// Don't extend the elements sizes from the boundary inside the domain
140
+//Mesh.CharacteristicLengthExtendFromBoundary = 0;
141
+
142
+Physical Volume(1) = {v[1]};
143
+
144
+// To create the mesh run
145
+// gmsh sphere.gmsh -2 -v 0 -format msh -o sphere.msh
146
+//gmsh -3 -format msh1 -o outfile.msh sphere.geo

+ 26
- 0
examples/borehole/sphere.sh View File

@@ -0,0 +1,26 @@
1
+
2
+#gmsh -3 -format vtk -o sphere.vtk  sphere.geo
3
+#../utVTKEdgeGsphere sphere.vtk .25 magnet  sphereG.vtu
4
+#../utFEM4EllipticPDE_bhmag  sphereG.vtu  sphereG.vtu   sphereOut.vtu 
5
+
6
+# Gravity problem
7
+../utVTKEdgeGsphere sphere.vtk .25 gravity  sphereGrav.vtu
8
+../utFEM4EllipticPDE_bhmag  sphereGrav.vtu  sphereGrav.vtu   sphereOutGrav.vtu 
9
+#paraview --state=sliceSphere.pvsm
10
+
11
+
12
+# --data=sphereOut.vtu
13
+
14
+# even finer meshing
15
+# radius = 4, u = \pm .9              analytic = \pm 1.33
16
+
17
+# Finer meshing
18
+# radius = 5, u = \pm 1.65            analytic = \pm 1.67
19
+# radius = 4, u = \pm 1.09            analytic = \pm 1.33
20
+
21
+# radius = 5, u = \pm 2.5             analytic = \pm 1.67
22
+# radius = 4, u = \pm 1.66            analytic = \pm 1.33
23
+# radius = 3, u= \pm .926 -.985       analytic = \pm 1
24
+# radius = 2, u = \pm.42              analytic = \pm .667
25
+# for radius=1,  u = \pm .111         analytic = \pm .333 
26
+# for radius=.5, u = \pm .0477 -.0462 analytic = \pm .167

+ 1
- 0
examples/borehole/untitled.geo View File

@@ -0,0 +1 @@
1
+Point(1) = {-0.25, 0, 10, 1.0};

examples/utmerge.cpp → examples/merge.cpp View File


Loading…
Cancel
Save