/[escript]/trunk/finley/test/python/run_visualization_interface.py
ViewVC logotype

Contents of /trunk/finley/test/python/run_visualization_interface.py

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1866 - (show annotations)
Thu Oct 9 04:01:06 2008 UTC (12 years, 8 months ago) by ksteube
File MIME type: text/x-python
File size: 195116 byte(s)
Repair to saveVTK similar to revision 1677 (there we got the number of offsets correct
and in this revision we got the number of types correct).
In case of MPI > 1 do not run saveDX tests since saveDX is not MPI parallel.

1
2 ########################################################
3 #
4 # Copyright (c) 2003-2008 by University of Queensland
5 # Earth Systems Science Computational Center (ESSCC)
6 # http://www.uq.edu.au/esscc
7 #
8 # Primary Business: Queensland, Australia
9 # Licensed under the Open Software License version 3.0
10 # http://www.opensource.org/licenses/osl-3.0.php
11 #
12 ########################################################
13
14 __copyright__="""Copyright (c) 2003-2008 by University of Queensland
15 Earth Systems Science Computational Center (ESSCC)
16 http://www.uq.edu.au/esscc
17 Primary Business: Queensland, Australia"""
18 __license__="""Licensed under the Open Software License version 3.0
19 http://www.opensource.org/licenses/osl-3.0.php"""
20 __url__="http://www.uq.edu.au/esscc/escript-finley"
21
22 import sys
23 import unittest
24 from esys.escript import *
25 from esys.finley import ReadMesh
26
27 try:
28 FINLEY_TEST_DATA=os.environ['FINLEY_TEST_DATA']
29 except KeyError:
30 FINLEY_TEST_DATA='.'
31
32 try:
33 FINLEY_WORKDIR=os.environ['FINLEY_WORKDIR']
34 except KeyError:
35 FINLEY_WORKDIR='.'
36
37 FINLEY_TEST_MESH_PATH=FINLEY_TEST_DATA+"/data_meshes/"
38 # if os.name == "nt":
39 # FINLEY_TEST_MESH_PATH = FINLEY_TEST_MESH_PATH+"win32/"
40 FINLEY_WORKDIR_PATH=FINLEY_WORKDIR+"/"
41
42 class Test_VisualizationInterface(unittest.TestCase):
43 def check_vtk(self,f,reference_f):
44 # if reference_f.startswith("tet_"): os.link(os.path.join(FINLEY_WORKDIR_PATH,f),os.path.join(FINLEY_TEST_MESH_PATH,reference_f))
45 out_string=open(os.path.join(FINLEY_WORKDIR_PATH,f)).read().splitlines()
46 ref_string=open(os.path.join(FINLEY_TEST_MESH_PATH,reference_f)).read().splitlines()
47 c=0
48 for l in range(0,len(ref_string)):
49 if not ref_string[l].strip()[:2]=="<!":
50 line=out_string[c].strip()
51 if os.name == "nt":
52 line=line.replace("e+00","e+0").replace("e-00","e-0")
53 # line=line.replace("e-00","e+00").replace("-0.000000e+00","0.000000e+00")
54 line=line.replace(".000000e-00",".000000e+00").replace("-0.000000e+00","0.000000e+00")
55 self.failUnlessEqual(line,ref_string[l].strip(),"line %d (%s) in vtk files does not match reference (%s)"%(c,line,ref_string[l].strip()))
56 c+=1
57
58 def check_dx(self,f,reference_f):
59 out_string=open(FINLEY_WORKDIR_PATH+f).read().splitlines()
60 ref_string=open(FINLEY_TEST_MESH_PATH+reference_f).read().splitlines()
61 c=0
62 for l in range(0,len(ref_string)):
63 if not ref_string[l].strip()[0]=="#":
64 line=out_string[c].strip()
65 if os.name == "nt":
66 line=line.replace("e+00","e+0").replace("e-00","e-0")
67 line=line.replace("e-00","e+00").replace("-0.000000e+00","0.000000e+00")
68 self.failUnlessEqual(line,ref_string[l].strip(),"line %d (%s) in dx file does not match reference (%s)"%(c,line,ref_string[l].strip()))
69 c+=1
70
71 class Test_VTKFiles(Test_VisualizationInterface):
72 # ======================================================================================================================
73 def test_hex_2D_order2_vtk(self):
74 reference="hex_2D_o2.xml"
75 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_2D_order2.msh",optimize=False)
76 saveVTK(FINLEY_WORKDIR_PATH+"hex_2D_order2.xml",domain=dom)
77 self.check_vtk("hex_2D_order2.xml",reference)
78
79 def test_hex_2D_order2_AllPoints_Scalar_vtk(self):
80 reference="hex_2D_o1_node_3xs.xml"
81 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_2D_order2.msh",optimize=False)
82 x=Solution(dom).getX()
83 x_r=ReducedSolution(dom).getX()
84 x_n=ContinuousFunction(dom).getX()
85 saveVTK(FINLEY_WORKDIR_PATH+"hex_2D_order2_AllPoints_Scalar.xml",data_r=x_r[0],data_n=x_n[0],data=x[0])
86 self.check_vtk("hex_2D_order2_AllPoints_Scalar.xml",reference)
87 def test_hex_2D_order2_02Points_Scalar_vtk(self):
88 reference="hex_2D_o2_node_2xs.xml"
89 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_2D_order2.msh",optimize=False)
90 x=Solution(dom).getX()
91 x_n=ContinuousFunction(dom).getX()
92 saveVTK(FINLEY_WORKDIR_PATH+"hex_2D_order2_O2Points_Scalar.xml",data_n=x_n[0],data=x[0])
93 self.check_vtk("hex_2D_order2_O2Points_Scalar.xml",reference)
94 def test_hex_2D_order2_2Cells_Scalar_vtk(self):
95 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_2D_order2.msh",optimize=False)
96 x=Function(dom).getX()
97 x_b=FunctionOnBoundary(dom).getX()
98 try:
99 saveVTK(FINLEY_WORKDIR_PATH+"hex_2D_order2_2Cells_Scalar.xml",data=x[0],data_b=x_b[0])
100 self.fail("non-matching data not detected.")
101 except StandardError:
102 pass
103 def test_hex_2D_order2_BoundaryPoint_Scalar_vtk(self):
104 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_2D_order2.msh",optimize=False)
105 x=ContinuousFunction(dom).getX()
106 x_b=FunctionOnBoundary(dom).getX()
107 try:
108 saveVTK(FINLEY_WORKDIR_PATH+"hex_2D_order2_BoundaryPoint_Scalar.xml",data=x[0],data_b=x_b[0])
109 self.fail("non-matching data not detected.")
110 except StandardError:
111 pass
112 def test_hex_2D_order2_Cells_AllData_vtk(self):
113 reference="hex_2D_o2_cell_all.xml"
114 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_2D_order2.msh",optimize=False)
115 x=Function(dom).getX()
116 saveVTK(FINLEY_WORKDIR_PATH+"hex_2D_order2_Cells_AllData.xml",data_s=x[0],data_v=x[0]*[1.,2.],data_t=x[0]*[[11.,12.],[21.,22.]],data_t2=x[0]*[[-11.,-12.],[-21.,-22.]])
117 self.check_vtk("hex_2D_order2_Cells_AllData.xml",reference)
118
119 def test_hex_2D_order2_CellsPoints_AllData_vtk(self):
120 reference="hex_2D_o2_cellnode_all.xml"
121 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_2D_order2.msh",optimize=False)
122 x_c=Function(dom).getX()
123 x_p=ContinuousFunction(dom).getX()
124 saveVTK(FINLEY_WORKDIR_PATH+"hex_2D_order2_CellsPoints_AllData.xml",data_sp=x_p[0],
125 data_vp=x_p[0]*[1.,2.],
126 data_tp=x_p[0]*[[11.,12.],[21.,22.]],
127 data_sc=x_c[0],
128 data_vc=x_c[0]*[1.,2.],
129 data_tc=x_c[0]*[[11.,12.],[21.,22.]])
130 self.check_vtk("hex_2D_order2_CellsPoints_AllData.xml",reference)
131 def test_hex_2D_order2p_vtk(self):
132 reference="hex_2D_o2p.xml"
133 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_2D_order2p.msh",optimize=False)
134 saveVTK(FINLEY_WORKDIR_PATH+"hex_2D_order2.xml",domain=dom)
135 self.check_vtk("hex_2D_order2.xml",reference)
136
137 def test_hex_2D_order2p_AllPoints_Scalar_vtk(self):
138 reference="hex_2D_o1_node_3xs.xml"
139 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_2D_order2p.msh",optimize=False)
140 x=Solution(dom).getX()
141 x_r=ReducedSolution(dom).getX()
142 x_n=ContinuousFunction(dom).getX()
143 saveVTK(FINLEY_WORKDIR_PATH+"hex_2D_order2_AllPoints_Scalar.xml",data_r=x_r[0],data_n=x_n[0],data=x[0])
144 self.check_vtk("hex_2D_order2_AllPoints_Scalar.xml",reference)
145 def test_hex_2D_order2p_02Points_Scalar_vtk(self):
146 reference="hex_2D_o2p_node_2xs.xml"
147 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_2D_order2p.msh",optimize=False)
148 x=Solution(dom).getX()
149 x_n=ContinuousFunction(dom).getX()
150 saveVTK(FINLEY_WORKDIR_PATH+"hex_2D_order2_O2Points_Scalar.xml",data_n=x_n[0],data=x[0])
151 self.check_vtk("hex_2D_order2_O2Points_Scalar.xml",reference)
152 def test_hex_2D_order2p_2Cells_Scalar_vtk(self):
153 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_2D_order2p.msh",optimize=False)
154 x=Function(dom).getX()
155 x_b=FunctionOnBoundary(dom).getX()
156 try:
157 saveVTK(FINLEY_WORKDIR_PATH+"hex_2D_order2_2Cells_Scalar.xml",data=x[0],data_b=x_b[0])
158 self.fail("non-matching data not detected.")
159 except StandardError:
160 pass
161 def test_hex_2D_order2p_BoundaryPoint_Scalar_vtk(self):
162 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_2D_order2p.msh",optimize=False)
163 x=ContinuousFunction(dom).getX()
164 x_b=FunctionOnBoundary(dom).getX()
165 try:
166 saveVTK(FINLEY_WORKDIR_PATH+"hex_2D_order2_BoundaryPoint_Scalar.xml",data=x[0],data_b=x_b[0])
167 self.fail("non-matching data not detected.")
168 except StandardError:
169 pass
170 def test_hex_2D_order2p_Cells_AllData_vtk(self):
171 reference="hex_2D_o2p_cell_all.xml"
172 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_2D_order2p.msh",optimize=False)
173 x=Function(dom).getX()
174 saveVTK(FINLEY_WORKDIR_PATH+"hex_2D_order2_Cells_AllData.xml",data_s=x[0],data_v=x[0]*[1.,2.],data_t=x[0]*[[11.,12.],[21.,22.]],data_t2=x[0]*[[-11.,-12.],[-21.,-22.]])
175 self.check_vtk("hex_2D_order2_Cells_AllData.xml",reference)
176
177 def test_hex_2D_order2p_CellsPoints_AllData_vtk(self):
178 reference="hex_2D_o2p_cellnode_all.xml"
179 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_2D_order2p.msh",optimize=False)
180 x_c=Function(dom).getX()
181 x_p=ContinuousFunction(dom).getX()
182 saveVTK(FINLEY_WORKDIR_PATH+"hex_2D_order2_CellsPoints_AllData.xml",data_sp=x_p[0],
183 data_vp=x_p[0]*[1.,2.],
184 data_tp=x_p[0]*[[11.,12.],[21.,22.]],
185 data_sc=x_c[0],
186 data_vc=x_c[0]*[1.,2.],
187 data_tc=x_c[0]*[[11.,12.],[21.,22.]])
188 self.check_vtk("hex_2D_order2_CellsPoints_AllData.xml",reference)
189 # ======================================================================================================================
190 def test_hex_contact_2D_order1_ContinuousFunction_Scalar_vtk(self):
191 reference="hex_2D_o1_node_s.xml"
192 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1.msh",optimize=False)
193 x=ContinuousFunction(dom).getX()
194 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_ContinuousFunction_Scalar.xml",data=x[0])
195 self.check_vtk("hex_contact_2D_order1_ContinuousFunction_Scalar.xml",reference)
196 def test_hex_contact_2D_order1_ContinuousFunction_Vector_vtk(self):
197 reference="hex_2D_o1_node_v.xml"
198 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1.msh",optimize=False)
199 x=ContinuousFunction(dom).getX()
200 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_ContinuousFunction_Vector.xml",data=x[0]*[1.,2.])
201 self.check_vtk("hex_contact_2D_order1_ContinuousFunction_Vector.xml",reference)
202 def test_hex_contact_2D_order1_ContinuousFunction_Tensor_vtk(self):
203 reference="hex_2D_o1_node_t.xml"
204 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1.msh",optimize=False)
205 x=ContinuousFunction(dom).getX()
206 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_ContinuousFunction_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
207 self.check_vtk("hex_contact_2D_order1_ContinuousFunction_Tensor.xml",reference)
208 def test_hex_contact_2D_order1_Solution_Scalar_vtk(self):
209 reference="hex_2D_o1_node_s.xml"
210 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1.msh",optimize=False)
211 x=Solution(dom).getX()
212 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_Solution_Scalar.xml",data=x[0])
213 self.check_vtk("hex_contact_2D_order1_Solution_Scalar.xml",reference)
214 def test_hex_contact_2D_order1_Solution_Vector_vtk(self):
215 reference="hex_2D_o1_node_v.xml"
216 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1.msh",optimize=False)
217 x=Solution(dom).getX()
218 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_Solution_Vector.xml",data=x[0]*[1.,2.])
219 self.check_vtk("hex_contact_2D_order1_Solution_Vector.xml",reference)
220 def test_hex_contact_2D_order1_Solution_Tensor_vtk(self):
221 reference="hex_2D_o1_node_t.xml"
222 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1.msh",optimize=False)
223 x=Solution(dom).getX()
224 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_Solution_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
225 self.check_vtk("hex_contact_2D_order1_Solution_Tensor.xml",reference)
226 def test_hex_contact_2D_order1_ReducedSolution_Scalar_vtk(self):
227 reference="hex_2D_o1_node_s.xml"
228 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1.msh",optimize=False)
229 x=ReducedSolution(dom).getX()
230 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_ReducedSolution_Scalar.xml",data=x[0])
231 self.check_vtk("hex_contact_2D_order1_ReducedSolution_Scalar.xml",reference)
232 def test_hex_contact_2D_order1_ReducedSolution_Vector_vtk(self):
233 reference="hex_2D_o1_node_v.xml"
234 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1.msh",optimize=False)
235 x=ReducedSolution(dom).getX()
236 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_ReducedSolution_Vector.xml",data=x[0]*[1.,2.])
237 self.check_vtk("hex_contact_2D_order1_ReducedSolution_Vector.xml",reference)
238 def test_hex_contact_2D_order1_ReducedSolution_Tensor_vtk(self):
239 reference="hex_2D_o1_node_t.xml"
240 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1.msh",optimize=False)
241 x=ReducedSolution(dom).getX()
242 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_ReducedSolution_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
243 self.check_vtk("hex_contact_2D_order1_ReducedSolution_Tensor.xml",reference)
244 def test_hex_contact_2D_order1_Function_Scalar_vtk(self):
245 reference="hex_2D_o1_cell_s.xml"
246 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1.msh",optimize=False)
247 x=Function(dom).getX()
248 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_Function_Scalar.xml",data=x[0])
249 self.check_vtk("hex_contact_2D_order1_Function_Scalar.xml",reference)
250 def test_hex_contact_2D_order1_Function_Vector_vtk(self):
251 reference="hex_2D_o1_cell_v.xml"
252 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1.msh",optimize=False)
253 x=Function(dom).getX()
254 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_Function_Vector.xml",data=x[0]*[1.,2.])
255 self.check_vtk("hex_contact_2D_order1_Function_Vector.xml",reference)
256 def test_hex_contact_2D_order1_Function_Tensor_vtk(self):
257 reference="hex_2D_o1_cell_t.xml"
258 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1.msh",optimize=False)
259 x=Function(dom).getX()
260 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_Function_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
261 self.check_vtk("hex_contact_2D_order1_Function_Tensor.xml",reference)
262 def test_hex_contact_2D_order1_ReducedFunction_Scalar_vtk(self):
263 reference="hex_2D_o1_cell_s.xml"
264 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1.msh",optimize=False)
265 x=ReducedFunction(dom).getX()
266 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_ReducedFunction_Scalar.xml",data=x[0])
267 self.check_vtk("hex_contact_2D_order1_ReducedFunction_Scalar.xml",reference)
268 def test_hex_contact_2D_order1_ReducedFunction_Vector_vtk(self):
269 reference="hex_2D_o1_cell_v.xml"
270 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1.msh",optimize=False)
271 x=ReducedFunction(dom).getX()
272 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_ReducedFunction_Vector.xml",data=x[0]*[1.,2.])
273 self.check_vtk("hex_contact_2D_order1_ReducedFunction_Vector.xml",reference)
274 def test_hex_contact_2D_order1_ReducedFunction_Tensor_vtk(self):
275 reference="hex_2D_o1_cell_t.xml"
276 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1.msh",optimize=False)
277 x=ReducedFunction(dom).getX()
278 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_ReducedFunction_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
279 self.check_vtk("hex_contact_2D_order1_ReducedFunction_Tensor.xml",reference)
280 def test_hex_contact_2D_order1_FunctionOnBoundary_Scalar_vtk(self):
281 reference="hex_2D_o1_boundary_s.xml"
282 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1.msh",optimize=False)
283 x=FunctionOnBoundary(dom).getX()
284 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_FunctionOnBoundary_Scalar.xml",data=x[0])
285 self.check_vtk("hex_contact_2D_order1_FunctionOnBoundary_Scalar.xml",reference)
286 def test_hex_contact_2D_order1_FunctionOnBoundary_Vector_vtk(self):
287 reference="hex_2D_o1_boundary_v.xml"
288 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1.msh",optimize=False)
289 x=FunctionOnBoundary(dom).getX()
290 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_FunctionOnBoundary_Vector.xml",data=x[0]*[1.,2.])
291 self.check_vtk("hex_contact_2D_order1_FunctionOnBoundary_Vector.xml",reference)
292 def test_hex_contact_2D_order1_FunctionOnBoundary_Tensor_vtk(self):
293 reference="hex_2D_o1_boundary_t.xml"
294 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1.msh",optimize=False)
295 x=FunctionOnBoundary(dom).getX()
296 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_FunctionOnBoundary_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
297 self.check_vtk("hex_contact_2D_order1_FunctionOnBoundary_Tensor.xml",reference)
298 def test_hex_contact_2D_order1_ReducedFunctionOnBoundary_Scalar_vtk(self):
299 reference="hex_2D_o1_boundary_s.xml"
300 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1.msh",optimize=False)
301 x=ReducedFunctionOnBoundary(dom).getX()
302 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_ReducedFunctionOnBoundary_Scalar.xml",data=x[0])
303 self.check_vtk("hex_contact_2D_order1_ReducedFunctionOnBoundary_Scalar.xml",reference)
304 def test_hex_contact_2D_order1_ReducedFunctionOnBoundary_Vector_vtk(self):
305 reference="hex_2D_o1_boundary_v.xml"
306 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1.msh",optimize=False)
307 x=ReducedFunctionOnBoundary(dom).getX()
308 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_ReducedFunctionOnBoundary_Vector.xml",data=x[0]*[1.,2.])
309 self.check_vtk("hex_contact_2D_order1_ReducedFunctionOnBoundary_Vector.xml",reference)
310 def test_hex_contact_2D_order1_ReducedFunctionOnBoundary_Tensor_vtk(self):
311 reference="hex_2D_o1_boundary_t.xml"
312 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1.msh",optimize=False)
313 x=ReducedFunctionOnBoundary(dom).getX()
314 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_ReducedFunctionOnBoundary_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
315 self.check_vtk("hex_contact_2D_order1_ReducedFunctionOnBoundary_Tensor.xml",reference)
316 def test_hex_contact_2D_order1_onFace_FunctionOnBoundary_Scalar_vtk(self):
317 reference="hex_2D_o1_f_boundary_s.xml"
318 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1_onFace.msh",optimize=False)
319 x=FunctionOnBoundary(dom).getX()
320 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_onFace_FunctionOnBoundary_Scalar.xml",data=x[0])
321 self.check_vtk("hex_contact_2D_order1_onFace_FunctionOnBoundary_Scalar.xml",reference)
322 def test_hex_contact_2D_order1_onFace_FunctionOnBoundary_Vector_vtk(self):
323 reference="hex_2D_o1_f_boundary_v.xml"
324 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1_onFace.msh",optimize=False)
325 x=FunctionOnBoundary(dom).getX()
326 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_onFace_FunctionOnBoundary_Vector.xml",data=x[0]*[1.,2.])
327 self.check_vtk("hex_contact_2D_order1_onFace_FunctionOnBoundary_Vector.xml",reference)
328 def test_hex_contact_2D_order1_onFace_FunctionOnBoundary_Tensor_vtk(self):
329 reference="hex_2D_o1_f_boundary_t.xml"
330 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1_onFace.msh",optimize=False)
331 x=FunctionOnBoundary(dom).getX()
332 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_onFace_FunctionOnBoundary_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
333 self.check_vtk("hex_contact_2D_order1_onFace_FunctionOnBoundary_Tensor.xml",reference)
334 def test_hex_contact_2D_order1_onFace_ReducedFunctionOnBoundary_Scalar_vtk(self):
335 reference="hex_2D_o1_f_boundary_s.xml"
336 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1_onFace.msh",optimize=False)
337 x=ReducedFunctionOnBoundary(dom).getX()
338 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_onFace_ReducedFunctionOnBoundary_Scalar.xml",data=x[0])
339 self.check_vtk("hex_contact_2D_order1_onFace_ReducedFunctionOnBoundary_Scalar.xml",reference)
340 def test_hex_contact_2D_order1_onFace_ReducedFunctionOnBoundary_Vector_vtk(self):
341 reference="hex_2D_o1_f_boundary_v.xml"
342 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1_onFace.msh",optimize=False)
343 x=ReducedFunctionOnBoundary(dom).getX()
344 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_onFace_ReducedFunctionOnBoundary_Vector.xml",data=x[0]*[1.,2.])
345 self.check_vtk("hex_contact_2D_order1_onFace_ReducedFunctionOnBoundary_Vector.xml",reference)
346 def test_hex_contact_2D_order1_onFace_ReducedFunctionOnBoundary_Tensor_vtk(self):
347 reference="hex_2D_o1_f_boundary_t.xml"
348 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1_onFace.msh",optimize=False)
349 x=ReducedFunctionOnBoundary(dom).getX()
350 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_onFace_ReducedFunctionOnBoundary_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
351 self.check_vtk("hex_contact_2D_order1_onFace_ReducedFunctionOnBoundary_Tensor.xml",reference)
352 def test_hex_contact_2D_order1_FunctionOnContactZero_Scalar_vtk(self):
353 reference="hex_2D_o1_contact_s.xml"
354 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1.msh",optimize=False)
355 x=FunctionOnContactZero(dom).getX()
356 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_FunctionOnContactZero_Scalar.xml",data=x[0])
357 self.check_vtk("hex_contact_2D_order1_FunctionOnContactZero_Scalar.xml",reference)
358 def test_hex_contact_2D_order1_FunctionOnContactZero_Vector_vtk(self):
359 reference="hex_2D_o1_contact_v.xml"
360 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1.msh",optimize=False)
361 x=FunctionOnContactZero(dom).getX()
362 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_FunctionOnContactZero_Vector.xml",data=x[0]*[1.,2.])
363 self.check_vtk("hex_contact_2D_order1_FunctionOnContactZero_Vector.xml",reference)
364 def test_hex_contact_2D_order1_FunctionOnContactZero_Tensor_vtk(self):
365 reference="hex_2D_o1_contact_t.xml"
366 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1.msh",optimize=False)
367 x=FunctionOnContactZero(dom).getX()
368 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_FunctionOnContactZero_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
369 self.check_vtk("hex_contact_2D_order1_FunctionOnContactZero_Tensor.xml",reference)
370 def test_hex_contact_2D_order1_ReducedFunctionOnContactZero_Scalar_vtk(self):
371 reference="hex_2D_o1_contact_s.xml"
372 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1.msh",optimize=False)
373 x=ReducedFunctionOnContactZero(dom).getX()
374 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_ReducedFunctionOnContactZero_Scalar.xml",data=x[0])
375 self.check_vtk("hex_contact_2D_order1_ReducedFunctionOnContactZero_Scalar.xml",reference)
376 def test_hex_contact_2D_order1_ReducedFunctionOnContactZero_Vector_vtk(self):
377 reference="hex_2D_o1_contact_v.xml"
378 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1.msh",optimize=False)
379 x=ReducedFunctionOnContactZero(dom).getX()
380 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_ReducedFunctionOnContactZero_Vector.xml",data=x[0]*[1.,2.])
381 self.check_vtk("hex_contact_2D_order1_ReducedFunctionOnContactZero_Vector.xml",reference)
382 def test_hex_contact_2D_order1_ReducedFunctionOnContactZero_Tensor_vtk(self):
383 reference="hex_2D_o1_contact_t.xml"
384 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1.msh",optimize=False)
385 x=ReducedFunctionOnContactZero(dom).getX()
386 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_ReducedFunctionOnContactZero_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
387 self.check_vtk("hex_contact_2D_order1_ReducedFunctionOnContactZero_Tensor.xml",reference)
388 def test_hex_contact_2D_order1_onFace_FunctionOnContactZero_Scalar_vtk(self):
389 reference="hex_2D_o1_contact_s.xml"
390 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1_onFace.msh",optimize=False)
391 x=FunctionOnContactZero(dom).getX()
392 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_onFace_FunctionOnContactZero_Scalar.xml",data=x[0])
393 self.check_vtk("hex_contact_2D_order1_onFace_FunctionOnContactZero_Scalar.xml",reference)
394 def test_hex_contact_2D_order1_onFace_FunctionOnContactZero_Vector_vtk(self):
395 reference="hex_2D_o1_contact_v.xml"
396 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1_onFace.msh",optimize=False)
397 x=FunctionOnContactZero(dom).getX()
398 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_onFace_FunctionOnContactZero_Vector.xml",data=x[0]*[1.,2.])
399 self.check_vtk("hex_contact_2D_order1_onFace_FunctionOnContactZero_Vector.xml",reference)
400 def test_hex_contact_2D_order1_onFace_FunctionOnContactZero_Tensor_vtk(self):
401 reference="hex_2D_o1_contact_t.xml"
402 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1_onFace.msh",optimize=False)
403 x=FunctionOnContactZero(dom).getX()
404 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_onFace_FunctionOnContactZero_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
405 self.check_vtk("hex_contact_2D_order1_onFace_FunctionOnContactZero_Tensor.xml",reference)
406 def test_hex_contact_2D_order1_onFace_ReducedFunctionOnContactZero_Scalar_vtk(self):
407 reference="hex_2D_o1_contact_s.xml"
408 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1_onFace.msh",optimize=False)
409 x=ReducedFunctionOnContactZero(dom).getX()
410 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_onFace_ReducedFunctionOnContactZero_Scalar.xml",data=x[0])
411 self.check_vtk("hex_contact_2D_order1_onFace_ReducedFunctionOnContactZero_Scalar.xml",reference)
412 def test_hex_contact_2D_order1_onFace_ReducedFunctionOnContactZero_Vector_vtk(self):
413 reference="hex_2D_o1_contact_v.xml"
414 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1_onFace.msh",optimize=False)
415 x=ReducedFunctionOnContactZero(dom).getX()
416 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_onFace_ReducedFunctionOnContactZero_Vector.xml",data=x[0]*[1.,2.])
417 self.check_vtk("hex_contact_2D_order1_onFace_ReducedFunctionOnContactZero_Vector.xml",reference)
418 def test_hex_contact_2D_order1_onFace_ReducedFunctionOnContactZero_Tensor_vtk(self):
419 reference="hex_2D_o1_contact_t.xml"
420 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1_onFace.msh",optimize=False)
421 x=ReducedFunctionOnContactZero(dom).getX()
422 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_onFace_ReducedFunctionOnContactZero_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
423 self.check_vtk("hex_contact_2D_order1_onFace_ReducedFunctionOnContactZero_Tensor.xml",reference)
424 def test_hex_contact_2D_order1_FunctionOnContactOne_Scalar_vtk(self):
425 reference="hex_2D_o1_contact_s.xml"
426 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1.msh",optimize=False)
427 x=FunctionOnContactOne(dom).getX()
428 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_FunctionOnContactOne_Scalar.xml",data=x[0])
429 self.check_vtk("hex_contact_2D_order1_FunctionOnContactOne_Scalar.xml",reference)
430 def test_hex_contact_2D_order1_FunctionOnContactOne_Vector_vtk(self):
431 reference="hex_2D_o1_contact_v.xml"
432 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1.msh",optimize=False)
433 x=FunctionOnContactOne(dom).getX()
434 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_FunctionOnContactOne_Vector.xml",data=x[0]*[1.,2.])
435 self.check_vtk("hex_contact_2D_order1_FunctionOnContactOne_Vector.xml",reference)
436 def test_hex_contact_2D_order1_FunctionOnContactOne_Tensor_vtk(self):
437 reference="hex_2D_o1_contact_t.xml"
438 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1.msh",optimize=False)
439 x=FunctionOnContactOne(dom).getX()
440 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_FunctionOnContactOne_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
441 self.check_vtk("hex_contact_2D_order1_FunctionOnContactOne_Tensor.xml",reference)
442 def test_hex_contact_2D_order1_ReducedFunctionOnContactOne_Scalar_vtk(self):
443 reference="hex_2D_o1_contact_s.xml"
444 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1.msh",optimize=False)
445 x=ReducedFunctionOnContactOne(dom).getX()
446 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_ReducedFunctionOnContactOne_Scalar.xml",data=x[0])
447 self.check_vtk("hex_contact_2D_order1_ReducedFunctionOnContactOne_Scalar.xml",reference)
448 def test_hex_contact_2D_order1_ReducedFunctionOnContactOne_Vector_vtk(self):
449 reference="hex_2D_o1_contact_v.xml"
450 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1.msh",optimize=False)
451 x=ReducedFunctionOnContactOne(dom).getX()
452 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_ReducedFunctionOnContactOne_Vector.xml",data=x[0]*[1.,2.])
453 self.check_vtk("hex_contact_2D_order1_ReducedFunctionOnContactOne_Vector.xml",reference)
454 def test_hex_contact_2D_order1_ReducedFunctionOnContactOne_Tensor_vtk(self):
455 reference="hex_2D_o1_contact_t.xml"
456 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1.msh",optimize=False)
457 x=ReducedFunctionOnContactOne(dom).getX()
458 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_ReducedFunctionOnContactOne_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
459 self.check_vtk("hex_contact_2D_order1_ReducedFunctionOnContactOne_Tensor.xml",reference)
460 def test_hex_contact_2D_order1_onFace_FunctionOnContactOne_Scalar_vtk(self):
461 reference="hex_2D_o1_contact_s.xml"
462 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1_onFace.msh",optimize=False)
463 x=FunctionOnContactOne(dom).getX()
464 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_onFace_FunctionOnContactOne_Scalar.xml",data=x[0])
465 self.check_vtk("hex_contact_2D_order1_onFace_FunctionOnContactOne_Scalar.xml",reference)
466 def test_hex_contact_2D_order1_onFace_FunctionOnContactOne_Vector_vtk(self):
467 reference="hex_2D_o1_contact_v.xml"
468 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1_onFace.msh",optimize=False)
469 x=FunctionOnContactOne(dom).getX()
470 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_onFace_FunctionOnContactOne_Vector.xml",data=x[0]*[1.,2.])
471 self.check_vtk("hex_contact_2D_order1_onFace_FunctionOnContactOne_Vector.xml",reference)
472 def test_hex_contact_2D_order1_onFace_FunctionOnContactOne_Tensor_vtk(self):
473 reference="hex_2D_o1_contact_t.xml"
474 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1_onFace.msh",optimize=False)
475 x=FunctionOnContactOne(dom).getX()
476 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_onFace_FunctionOnContactOne_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
477 self.check_vtk("hex_contact_2D_order1_onFace_FunctionOnContactOne_Tensor.xml",reference)
478 def test_hex_contact_2D_order1_onFace_ReducedFunctionOnContactOne_Scalar_vtk(self):
479 reference="hex_2D_o1_contact_s.xml"
480 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1_onFace.msh",optimize=False)
481 x=ReducedFunctionOnContactOne(dom).getX()
482 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_onFace_ReducedFunctionOnContactOne_Scalar.xml",data=x[0])
483 self.check_vtk("hex_contact_2D_order1_onFace_ReducedFunctionOnContactOne_Scalar.xml",reference)
484 def test_hex_contact_2D_order1_onFace_ReducedFunctionOnContactOne_Vector_vtk(self):
485 reference="hex_2D_o1_contact_v.xml"
486 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1_onFace.msh",optimize=False)
487 x=ReducedFunctionOnContactOne(dom).getX()
488 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_onFace_ReducedFunctionOnContactOne_Vector.xml",data=x[0]*[1.,2.])
489 self.check_vtk("hex_contact_2D_order1_onFace_ReducedFunctionOnContactOne_Vector.xml",reference)
490 def test_hex_contact_2D_order1_onFace_ReducedFunctionOnContactOne_Tensor_vtk(self):
491 reference="hex_2D_o1_contact_t.xml"
492 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order1_onFace.msh",optimize=False)
493 x=ReducedFunctionOnContactOne(dom).getX()
494 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order1_onFace_ReducedFunctionOnContactOne_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
495 self.check_vtk("hex_contact_2D_order1_onFace_ReducedFunctionOnContactOne_Tensor.xml",reference)
496 # ======================================================================================================================
497 def test_hex_contact_2D_order2_ContinuousFunction_Scalar_vtk(self):
498 reference="hex_2D_o2_node_s.xml"
499 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2.msh",optimize=False)
500 x=ContinuousFunction(dom).getX()
501 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_ContinuousFunction_Scalar.xml",data=x[0])
502 self.check_vtk("hex_contact_2D_order2_ContinuousFunction_Scalar.xml",reference)
503 def test_hex_contact_2D_order2_ContinuousFunction_Vector_vtk(self):
504 reference="hex_2D_o2_node_v.xml"
505 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2.msh",optimize=False)
506 x=ContinuousFunction(dom).getX()
507 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_ContinuousFunction_Vector.xml",data=x[0]*[1.,2.])
508 self.check_vtk("hex_contact_2D_order2_ContinuousFunction_Vector.xml",reference)
509 def test_hex_contact_2D_order2_ContinuousFunction_Tensor_vtk(self):
510 reference="hex_2D_o2_node_t.xml"
511 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2.msh",optimize=False)
512 x=ContinuousFunction(dom).getX()
513 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_ContinuousFunction_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
514 self.check_vtk("hex_contact_2D_order2_ContinuousFunction_Tensor.xml",reference)
515 def test_hex_contact_2D_order2_Solution_Scalar_vtk(self):
516 reference="hex_2D_o2_node_s.xml"
517 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2.msh",optimize=False)
518 x=Solution(dom).getX()
519 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_Solution_Scalar.xml",data=x[0])
520 self.check_vtk("hex_contact_2D_order2_Solution_Scalar.xml",reference)
521 def test_hex_contact_2D_order2_Solution_Vector_vtk(self):
522 reference="hex_2D_o2_node_v.xml"
523 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2.msh",optimize=False)
524 x=Solution(dom).getX()
525 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_Solution_Vector.xml",data=x[0]*[1.,2.])
526 self.check_vtk("hex_contact_2D_order2_Solution_Vector.xml",reference)
527 def test_hex_contact_2D_order2_Solution_Tensor_vtk(self):
528 reference="hex_2D_o2_node_t.xml"
529 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2.msh",optimize=False)
530 x=Solution(dom).getX()
531 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_Solution_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
532 self.check_vtk("hex_contact_2D_order2_Solution_Tensor.xml",reference)
533 def test_hex_contact_2D_order2_ReducedSolution_Scalar_vtk(self):
534 reference="hex_2D_o1_node_s.xml"
535 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2.msh",optimize=False)
536 x=ReducedSolution(dom).getX()
537 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_ReducedSolution_Scalar.xml",data=x[0])
538 self.check_vtk("hex_contact_2D_order2_ReducedSolution_Scalar.xml",reference)
539 def test_hex_contact_2D_order2_ReducedSolution_Vector_vtk(self):
540 reference="hex_2D_o1_node_v.xml"
541 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2.msh",optimize=False)
542 x=ReducedSolution(dom).getX()
543 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_ReducedSolution_Vector.xml",data=x[0]*[1.,2.])
544 self.check_vtk("hex_contact_2D_order2_ReducedSolution_Vector.xml",reference)
545 def test_hex_contact_2D_order2_ReducedSolution_Tensor_vtk(self):
546 reference="hex_2D_o1_node_t.xml"
547 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2.msh",optimize=False)
548 x=ReducedSolution(dom).getX()
549 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_ReducedSolution_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
550 self.check_vtk("hex_contact_2D_order2_ReducedSolution_Tensor.xml",reference)
551 def test_hex_contact_2D_order2_Function_Scalar_vtk(self):
552 reference="hex_2D_o2_cell_s.xml"
553 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2.msh",optimize=False)
554 x=Function(dom).getX()
555 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_Function_Scalar.xml",data=x[0])
556 self.check_vtk("hex_contact_2D_order2_Function_Scalar.xml",reference)
557 def test_hex_contact_2D_order2_Function_Vector_vtk(self):
558 reference="hex_2D_o2_cell_v.xml"
559 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2.msh",optimize=False)
560 x=Function(dom).getX()
561 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_Function_Vector.xml",data=x[0]*[1.,2.])
562 self.check_vtk("hex_contact_2D_order2_Function_Vector.xml",reference)
563 def test_hex_contact_2D_order2_Function_Tensor_vtk(self):
564 reference="hex_2D_o2_cell_t.xml"
565 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2.msh",optimize=False)
566 x=Function(dom).getX()
567 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_Function_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
568 self.check_vtk("hex_contact_2D_order2_Function_Tensor.xml",reference)
569 def test_hex_contact_2D_order2_ReducedFunction_Scalar_vtk(self):
570 reference="hex_2D_o2_cell_s.xml"
571 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2.msh",optimize=False)
572 x=ReducedFunction(dom).getX()
573 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_ReducedFunction_Scalar.xml",data=x[0])
574 self.check_vtk("hex_contact_2D_order2_ReducedFunction_Scalar.xml",reference)
575 def test_hex_contact_2D_order2_ReducedFunction_Vector_vtk(self):
576 reference="hex_2D_o2_cell_v.xml"
577 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2.msh",optimize=False)
578 x=ReducedFunction(dom).getX()
579 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_ReducedFunction_Vector.xml",data=x[0]*[1.,2.])
580 self.check_vtk("hex_contact_2D_order2_ReducedFunction_Vector.xml",reference)
581 def test_hex_contact_2D_order2_ReducedFunction_Tensor_vtk(self):
582 reference="hex_2D_o2_cell_t.xml"
583 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2.msh",optimize=False)
584 x=ReducedFunction(dom).getX()
585 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_ReducedFunction_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
586 self.check_vtk("hex_contact_2D_order2_ReducedFunction_Tensor.xml",reference)
587 def test_hex_contact_2D_order2_FunctionOnBoundary_Scalar_vtk(self):
588 reference="hex_2D_o2_boundary_s.xml"
589 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2.msh",optimize=False)
590 x=FunctionOnBoundary(dom).getX()
591 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_FunctionOnBoundary_Scalar.xml",data=x[0])
592 self.check_vtk("hex_contact_2D_order2_FunctionOnBoundary_Scalar.xml",reference)
593 def test_hex_contact_2D_order2_FunctionOnBoundary_Vector_vtk(self):
594 reference="hex_2D_o2_boundary_v.xml"
595 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2.msh",optimize=False)
596 x=FunctionOnBoundary(dom).getX()
597 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_FunctionOnBoundary_Vector.xml",data=x[0]*[1.,2.])
598 self.check_vtk("hex_contact_2D_order2_FunctionOnBoundary_Vector.xml",reference)
599 def test_hex_contact_2D_order2_FunctionOnBoundary_Tensor_vtk(self):
600 reference="hex_2D_o2_boundary_t.xml"
601 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2.msh",optimize=False)
602 x=FunctionOnBoundary(dom).getX()
603 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_FunctionOnBoundary_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
604 self.check_vtk("hex_contact_2D_order2_FunctionOnBoundary_Tensor.xml",reference)
605 def test_hex_contact_2D_order2_ReducedFunctionOnBoundary_Scalar_vtk(self):
606 reference="hex_2D_o2_boundary_s.xml"
607 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2.msh",optimize=False)
608 x=ReducedFunctionOnBoundary(dom).getX()
609 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_ReducedFunctionOnBoundary_Scalar.xml",data=x[0])
610 self.check_vtk("hex_contact_2D_order2_ReducedFunctionOnBoundary_Scalar.xml",reference)
611 def test_hex_contact_2D_order2_ReducedFunctionOnBoundary_Vector_vtk(self):
612 reference="hex_2D_o2_boundary_v.xml"
613 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2.msh",optimize=False)
614 x=ReducedFunctionOnBoundary(dom).getX()
615 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_ReducedFunctionOnBoundary_Vector.xml",data=x[0]*[1.,2.])
616 self.check_vtk("hex_contact_2D_order2_ReducedFunctionOnBoundary_Vector.xml",reference)
617 def test_hex_contact_2D_order2_ReducedFunctionOnBoundary_Tensor_vtk(self):
618 reference="hex_2D_o2_boundary_t.xml"
619 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2.msh",optimize=False)
620 x=ReducedFunctionOnBoundary(dom).getX()
621 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_ReducedFunctionOnBoundary_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
622 self.check_vtk("hex_contact_2D_order2_ReducedFunctionOnBoundary_Tensor.xml",reference)
623 def test_hex_contact_2D_order2_onFace_FunctionOnBoundary_Scalar_vtk(self):
624 reference="hex_2D_o2_f_boundary_s.xml"
625 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2_onFace.msh",optimize=False)
626 x=FunctionOnBoundary(dom).getX()
627 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_onFace_FunctionOnBoundary_Scalar.xml",data=x[0])
628 self.check_vtk("hex_contact_2D_order2_onFace_FunctionOnBoundary_Scalar.xml",reference)
629 def test_hex_contact_2D_order2_onFace_FunctionOnBoundary_Vector_vtk(self):
630 reference="hex_2D_o2_f_boundary_v.xml"
631 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2_onFace.msh",optimize=False)
632 x=FunctionOnBoundary(dom).getX()
633 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_onFace_FunctionOnBoundary_Vector.xml",data=x[0]*[1.,2.])
634 self.check_vtk("hex_contact_2D_order2_onFace_FunctionOnBoundary_Vector.xml",reference)
635 def test_hex_contact_2D_order2_onFace_FunctionOnBoundary_Tensor_vtk(self):
636 reference="hex_2D_o2_f_boundary_t.xml"
637 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2_onFace.msh",optimize=False)
638 x=FunctionOnBoundary(dom).getX()
639 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_onFace_FunctionOnBoundary_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
640 self.check_vtk("hex_contact_2D_order2_onFace_FunctionOnBoundary_Tensor.xml",reference)
641 def test_hex_contact_2D_order2_onFace_ReducedFunctionOnBoundary_Scalar_vtk(self):
642 reference="hex_2D_o2_f_boundary_s.xml"
643 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2_onFace.msh",optimize=False)
644 x=ReducedFunctionOnBoundary(dom).getX()
645 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_onFace_ReducedFunctionOnBoundary_Scalar.xml",data=x[0])
646 self.check_vtk("hex_contact_2D_order2_onFace_ReducedFunctionOnBoundary_Scalar.xml",reference)
647 def test_hex_contact_2D_order2_onFace_ReducedFunctionOnBoundary_Vector_vtk(self):
648 reference="hex_2D_o2_f_boundary_v.xml"
649 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2_onFace.msh",optimize=False)
650 x=ReducedFunctionOnBoundary(dom).getX()
651 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_onFace_ReducedFunctionOnBoundary_Vector.xml",data=x[0]*[1.,2.])
652 self.check_vtk("hex_contact_2D_order2_onFace_ReducedFunctionOnBoundary_Vector.xml",reference)
653 def test_hex_contact_2D_order2_onFace_ReducedFunctionOnBoundary_Tensor_vtk(self):
654 reference="hex_2D_o2_f_boundary_t.xml"
655 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2_onFace.msh",optimize=False)
656 x=ReducedFunctionOnBoundary(dom).getX()
657 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_onFace_ReducedFunctionOnBoundary_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
658 self.check_vtk("hex_contact_2D_order2_onFace_ReducedFunctionOnBoundary_Tensor.xml",reference)
659 def test_hex_contact_2D_order2_FunctionOnContactZero_Scalar_vtk(self):
660 reference="hex_2D_o2_contact_s.xml"
661 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2.msh",optimize=False)
662 x=FunctionOnContactZero(dom).getX()
663 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_FunctionOnContactZero_Scalar.xml",data=x[0])
664 self.check_vtk("hex_contact_2D_order2_FunctionOnContactZero_Scalar.xml",reference)
665 def test_hex_contact_2D_order2_FunctionOnContactZero_Vector_vtk(self):
666 reference="hex_2D_o2_contact_v.xml"
667 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2.msh",optimize=False)
668 x=FunctionOnContactZero(dom).getX()
669 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_FunctionOnContactZero_Vector.xml",data=x[0]*[1.,2.])
670 self.check_vtk("hex_contact_2D_order2_FunctionOnContactZero_Vector.xml",reference)
671 def test_hex_contact_2D_order2_FunctionOnContactZero_Tensor_vtk(self):
672 reference="hex_2D_o2_contact_t.xml"
673 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2.msh",optimize=False)
674 x=FunctionOnContactZero(dom).getX()
675 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_FunctionOnContactZero_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
676 self.check_vtk("hex_contact_2D_order2_FunctionOnContactZero_Tensor.xml",reference)
677 def test_hex_contact_2D_order2_ReducedFunctionOnContactZero_Scalar_vtk(self):
678 reference="hex_2D_o2_contact_s.xml"
679 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2.msh",optimize=False)
680 x=ReducedFunctionOnContactZero(dom).getX()
681 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_ReducedFunctionOnContactZero_Scalar.xml",data=x[0])
682 self.check_vtk("hex_contact_2D_order2_ReducedFunctionOnContactZero_Scalar.xml",reference)
683 def test_hex_contact_2D_order2_ReducedFunctionOnContactZero_Vector_vtk(self):
684 reference="hex_2D_o2_contact_v.xml"
685 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2.msh",optimize=False)
686 x=ReducedFunctionOnContactZero(dom).getX()
687 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_ReducedFunctionOnContactZero_Vector.xml",data=x[0]*[1.,2.])
688 self.check_vtk("hex_contact_2D_order2_ReducedFunctionOnContactZero_Vector.xml",reference)
689 def test_hex_contact_2D_order2_ReducedFunctionOnContactZero_Tensor_vtk(self):
690 reference="hex_2D_o2_contact_t.xml"
691 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2.msh",optimize=False)
692 x=ReducedFunctionOnContactZero(dom).getX()
693 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_ReducedFunctionOnContactZero_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
694 self.check_vtk("hex_contact_2D_order2_ReducedFunctionOnContactZero_Tensor.xml",reference)
695 def test_hex_contact_2D_order2_onFace_FunctionOnContactZero_Scalar_vtk(self):
696 reference="hex_2D_o2_contact_s.xml"
697 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2_onFace.msh",optimize=False)
698 x=FunctionOnContactZero(dom).getX()
699 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_onFace_FunctionOnContactZero_Scalar.xml",data=x[0])
700 self.check_vtk("hex_contact_2D_order2_onFace_FunctionOnContactZero_Scalar.xml",reference)
701 def test_hex_contact_2D_order2_onFace_FunctionOnContactZero_Vector_vtk(self):
702 reference="hex_2D_o2_contact_v.xml"
703 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2_onFace.msh",optimize=False)
704 x=FunctionOnContactZero(dom).getX()
705 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_onFace_FunctionOnContactZero_Vector.xml",data=x[0]*[1.,2.])
706 self.check_vtk("hex_contact_2D_order2_onFace_FunctionOnContactZero_Vector.xml",reference)
707 def test_hex_contact_2D_order2_onFace_FunctionOnContactZero_Tensor_vtk(self):
708 reference="hex_2D_o2_contact_t.xml"
709 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2_onFace.msh",optimize=False)
710 x=FunctionOnContactZero(dom).getX()
711 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_onFace_FunctionOnContactZero_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
712 self.check_vtk("hex_contact_2D_order2_onFace_FunctionOnContactZero_Tensor.xml",reference)
713 def test_hex_contact_2D_order2_onFace_ReducedFunctionOnContactZero_Scalar_vtk(self):
714 reference="hex_2D_o2_contact_s.xml"
715 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2_onFace.msh",optimize=False)
716 x=ReducedFunctionOnContactZero(dom).getX()
717 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_onFace_ReducedFunctionOnContactZero_Scalar.xml",data=x[0])
718 self.check_vtk("hex_contact_2D_order2_onFace_ReducedFunctionOnContactZero_Scalar.xml",reference)
719 def test_hex_contact_2D_order2_onFace_ReducedFunctionOnContactZero_Vector_vtk(self):
720 reference="hex_2D_o2_contact_v.xml"
721 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2_onFace.msh",optimize=False)
722 x=ReducedFunctionOnContactZero(dom).getX()
723 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_onFace_ReducedFunctionOnContactZero_Vector.xml",data=x[0]*[1.,2.])
724 self.check_vtk("hex_contact_2D_order2_onFace_ReducedFunctionOnContactZero_Vector.xml",reference)
725 def test_hex_contact_2D_order2_onFace_ReducedFunctionOnContactZero_Tensor_vtk(self):
726 reference="hex_2D_o2_contact_t.xml"
727 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2_onFace.msh",optimize=False)
728 x=ReducedFunctionOnContactZero(dom).getX()
729 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_onFace_ReducedFunctionOnContactZero_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
730 self.check_vtk("hex_contact_2D_order2_onFace_ReducedFunctionOnContactZero_Tensor.xml",reference)
731 def test_hex_contact_2D_order2_FunctionOnContactOne_Scalar_vtk(self):
732 reference="hex_2D_o2_contact_s.xml"
733 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2.msh",optimize=False)
734 x=FunctionOnContactOne(dom).getX()
735 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_FunctionOnContactOne_Scalar.xml",data=x[0])
736 self.check_vtk("hex_contact_2D_order2_FunctionOnContactOne_Scalar.xml",reference)
737 def test_hex_contact_2D_order2_FunctionOnContactOne_Vector_vtk(self):
738 reference="hex_2D_o2_contact_v.xml"
739 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2.msh",optimize=False)
740 x=FunctionOnContactOne(dom).getX()
741 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_FunctionOnContactOne_Vector.xml",data=x[0]*[1.,2.])
742 self.check_vtk("hex_contact_2D_order2_FunctionOnContactOne_Vector.xml",reference)
743 def test_hex_contact_2D_order2_FunctionOnContactOne_Tensor_vtk(self):
744 reference="hex_2D_o2_contact_t.xml"
745 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2.msh",optimize=False)
746 x=FunctionOnContactOne(dom).getX()
747 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_FunctionOnContactOne_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
748 self.check_vtk("hex_contact_2D_order2_FunctionOnContactOne_Tensor.xml",reference)
749 def test_hex_contact_2D_order2_ReducedFunctionOnContactOne_Scalar_vtk(self):
750 reference="hex_2D_o2_contact_s.xml"
751 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2.msh",optimize=False)
752 x=ReducedFunctionOnContactOne(dom).getX()
753 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_ReducedFunctionOnContactOne_Scalar.xml",data=x[0])
754 self.check_vtk("hex_contact_2D_order2_ReducedFunctionOnContactOne_Scalar.xml",reference)
755 def test_hex_contact_2D_order2_ReducedFunctionOnContactOne_Vector_vtk(self):
756 reference="hex_2D_o2_contact_v.xml"
757 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2.msh",optimize=False)
758 x=ReducedFunctionOnContactOne(dom).getX()
759 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_ReducedFunctionOnContactOne_Vector.xml",data=x[0]*[1.,2.])
760 self.check_vtk("hex_contact_2D_order2_ReducedFunctionOnContactOne_Vector.xml",reference)
761 def test_hex_contact_2D_order2_ReducedFunctionOnContactOne_Tensor_vtk(self):
762 reference="hex_2D_o2_contact_t.xml"
763 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2.msh",optimize=False)
764 x=ReducedFunctionOnContactOne(dom).getX()
765 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_ReducedFunctionOnContactOne_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
766 self.check_vtk("hex_contact_2D_order2_ReducedFunctionOnContactOne_Tensor.xml",reference)
767 def test_hex_contact_2D_order2_onFace_ReducedFunctionOnContactOne_Scalar_vtk(self):
768 reference="hex_2D_o2_contact_s.xml"
769 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2_onFace.msh",optimize=False)
770 x=FunctionOnContactOne(dom).getX()
771 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_onFace_FunctionOnContactOne_Scalar.xml",data=x[0])
772 self.check_vtk("hex_contact_2D_order2_onFace_FunctionOnContactOne_Scalar.xml",reference)
773 def test_hex_contact_2D_order2_onFace_FunctionOnContactOne_Vector_vtk(self):
774 reference="hex_2D_o2_contact_v.xml"
775 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2_onFace.msh",optimize=False)
776 x=FunctionOnContactOne(dom).getX()
777 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_onFace_FunctionOnContactOne_Vector.xml",data=x[0]*[1.,2.])
778 self.check_vtk("hex_contact_2D_order2_onFace_FunctionOnContactOne_Vector.xml",reference)
779 def test_hex_contact_2D_order2_onFace_FunctionOnContactOne_Tensor_vtk(self):
780 reference="hex_2D_o2_contact_t.xml"
781 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2_onFace.msh",optimize=False)
782 x=FunctionOnContactOne(dom).getX()
783 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_onFace_FunctionOnContactOne_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
784 self.check_vtk("hex_contact_2D_order2_onFace_FunctionOnContactOne_Tensor.xml",reference)
785
786 def test_hex_contact_2D_order2_onFace_ReducedReducedFunctionOnContactOne_Scalar_vtk(self):
787 reference="hex_2D_o2_contact_s.xml"
788 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2_onFace.msh",optimize=False)
789 x=ReducedFunctionOnContactOne(dom).getX()
790 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_onFace_ReducedFunctionOnContactOne_Scalar.xml",data=x[0])
791 self.check_vtk("hex_contact_2D_order2_onFace_ReducedFunctionOnContactOne_Scalar.xml",reference)
792 def test_hex_contact_2D_order2_onFace_ReducedFunctionOnContactOne_Vector_vtk(self):
793 reference="hex_2D_o2_contact_v.xml"
794 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2_onFace.msh",optimize=False)
795 x=ReducedFunctionOnContactOne(dom).getX()
796 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_onFace_ReducedFunctionOnContactOne_Vector.xml",data=x[0]*[1.,2.])
797 self.check_vtk("hex_contact_2D_order2_onFace_ReducedFunctionOnContactOne_Vector.xml",reference)
798 def test_hex_contact_2D_order2_onFace_ReducedFunctionOnContactOne_Tensor_vtk(self):
799 reference="hex_2D_o2_contact_t.xml"
800 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_2D_order2_onFace.msh",optimize=False)
801 x=ReducedFunctionOnContactOne(dom).getX()
802 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_2D_order2_onFace_ReducedFunctionOnContactOne_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
803 self.check_vtk("hex_contact_2D_order2_onFace_ReducedFunctionOnContactOne_Tensor.xml",reference)
804 # ======================================================================================================================
805 def test_hex_2D_order2p_ContinuousFunction_Scalar_vtk(self):
806 reference="hex_2D_o2p_node_s.xml"
807 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_2D_order2p.msh",optimize=False)
808 x=ContinuousFunction(dom).getX()
809 saveVTK(FINLEY_WORKDIR_PATH+"hex_2D_order2p_ContinuousFunction_Scalar.xml",data=x[0])
810 self.check_vtk("hex_2D_order2p_ContinuousFunction_Scalar.xml",reference)
811 def test_hex_2D_order2p_ContinuousFunction_Vector_vtk(self):
812 reference="hex_2D_o2p_node_v.xml"
813 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_2D_order2p.msh",optimize=False)
814 x=ContinuousFunction(dom).getX()
815 saveVTK(FINLEY_WORKDIR_PATH+"hex_2D_order2p_ContinuousFunction_Vector.xml",data=x[0]*[1.,2.])
816 self.check_vtk("hex_2D_order2p_ContinuousFunction_Vector.xml",reference)
817 def test_hex_2D_order2p_ContinuousFunction_Tensor_vtk(self):
818 reference="hex_2D_o2p_node_t.xml"
819 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_2D_order2p.msh",optimize=False)
820 x=ContinuousFunction(dom).getX()
821 saveVTK(FINLEY_WORKDIR_PATH+"hex_2D_order2p_ContinuousFunction_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
822 self.check_vtk("hex_2D_order2p_ContinuousFunction_Tensor.xml",reference)
823 def test_hex_2D_order2p_Solution_Scalar_vtk(self):
824 reference="hex_2D_o2p_node_s.xml"
825 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_2D_order2p.msh",optimize=False)
826 x=Solution(dom).getX()
827 saveVTK(FINLEY_WORKDIR_PATH+"hex_2D_order2p_Solution_Scalar.xml",data=x[0])
828 self.check_vtk("hex_2D_order2p_Solution_Scalar.xml",reference)
829 def test_hex_2D_order2p_Solution_Vector_vtk(self):
830 reference="hex_2D_o2p_node_v.xml"
831 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_2D_order2p.msh",optimize=False)
832 x=Solution(dom).getX()
833 saveVTK(FINLEY_WORKDIR_PATH+"hex_2D_order2p_Solution_Vector.xml",data=x[0]*[1.,2.])
834 self.check_vtk("hex_2D_order2p_Solution_Vector.xml",reference)
835 def test_hex_2D_order2p_Solution_Tensor_vtk(self):
836 reference="hex_2D_o2p_node_t.xml"
837 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_2D_order2p.msh",optimize=False)
838 x=Solution(dom).getX()
839 saveVTK(FINLEY_WORKDIR_PATH+"hex_2D_order2p_Solution_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
840 self.check_vtk("hex_2D_order2p_Solution_Tensor.xml",reference)
841 def test_hex_2D_order2p_ReducedSolution_Scalar_vtk(self):
842 reference="hex_2D_o2p_reduced_node_s.xml"
843 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_2D_order2p.msh",optimize=False)
844 x=ReducedSolution(dom).getX()
845 saveVTK(FINLEY_WORKDIR_PATH+"hex_2D_order2p_ReducedSolution_Scalar.xml",data=x[0])
846 self.check_vtk("hex_2D_order2p_ReducedSolution_Scalar.xml",reference)
847 def test_hex_2D_order2p_ReducedSolution_Vector_vtk(self):
848 reference="hex_2D_o2p_reduced_node_v.xml"
849 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_2D_order2p.msh",optimize=False)
850 x=ReducedSolution(dom).getX()
851 saveVTK(FINLEY_WORKDIR_PATH+"hex_2D_order2p_ReducedSolution_Vector.xml",data=x[0]*[1.,2.])
852 self.check_vtk("hex_2D_order2p_ReducedSolution_Vector.xml",reference)
853 def test_hex_2D_order2p_ReducedSolution_Tensor_vtk(self):
854 reference="hex_2D_o2p_reduced_node_t.xml"
855 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_2D_order2p.msh",optimize=False)
856 x=ReducedSolution(dom).getX()
857 saveVTK(FINLEY_WORKDIR_PATH+"hex_2D_order2p_ReducedSolution_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
858 self.check_vtk("hex_2D_order2p_ReducedSolution_Tensor.xml",reference)
859 def test_hex_2D_order2p_Function_Scalar_vtk(self):
860 reference="hex_2D_o2p_cell_s.xml"
861 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_2D_order2p.msh",optimize=False)
862 x=Function(dom).getX()
863 saveVTK(FINLEY_WORKDIR_PATH+"hex_2D_order2p_Function_Scalar.xml",data=x[0])
864 self.check_vtk("hex_2D_order2p_Function_Scalar.xml",reference)
865 def test_hex_2D_order2p_Function_Vector_vtk(self):
866 reference="hex_2D_o2p_cell_v.xml"
867 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_2D_order2p.msh",optimize=False)
868 x=Function(dom).getX()
869 saveVTK(FINLEY_WORKDIR_PATH+"hex_2D_order2p_Function_Vector.xml",data=x[0]*[1.,2.])
870 self.check_vtk("hex_2D_order2p_Function_Vector.xml",reference)
871 def test_hex_2D_order2p_Function_Tensor_vtk(self):
872 reference="hex_2D_o2p_cell_t.xml"
873 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_2D_order2p.msh",optimize=False)
874 x=Function(dom).getX()
875 saveVTK(FINLEY_WORKDIR_PATH+"hex_2D_order2p_Function_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
876 self.check_vtk("hex_2D_order2p_Function_Tensor.xml",reference)
877 def test_hex_2D_order2p_ReducedFunction_Scalar_vtk(self):
878 reference="hex_2D_o2p_cell_reduced_s.xml"
879 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_2D_order2p.msh",optimize=False)
880 x=ReducedFunction(dom).getX()
881 saveVTK(FINLEY_WORKDIR_PATH+"hex_2D_order2p_ReducedFunction_Scalar.xml",data=x[0])
882 self.check_vtk("hex_2D_order2p_ReducedFunction_Scalar.xml",reference)
883 def test_hex_2D_order2p_ReducedFunction_Vector_vtk(self):
884 reference="hex_2D_o2p_cell_reduced_v.xml"
885 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_2D_order2p.msh",optimize=False)
886 x=ReducedFunction(dom).getX()
887 saveVTK(FINLEY_WORKDIR_PATH+"hex_2D_order2p_ReducedFunction_Vector.xml",data=x[0]*[1.,2.])
888 self.check_vtk("hex_2D_order2p_ReducedFunction_Vector.xml",reference)
889 def test_hex_2D_order2p_ReducedFunction_Tensor_vtk(self):
890 reference="hex_2D_o2p_cell_reduced_t.xml"
891 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_2D_order2p.msh",optimize=False)
892 x=ReducedFunction(dom).getX()
893 saveVTK(FINLEY_WORKDIR_PATH+"hex_2D_order2p_ReducedFunction_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
894 self.check_vtk("hex_2D_order2p_ReducedFunction_Tensor.xml",reference)
895 def test_hex_2D_order2p_FunctionOnBoundary_Scalar_vtk(self):
896 reference="hex_2D_o2p_boundary_s.xml"
897 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_2D_order2p.msh",optimize=False)
898 x=FunctionOnBoundary(dom).getX()
899 saveVTK(FINLEY_WORKDIR_PATH+"hex_2D_order2p_FunctionOnBoundary_Scalar.xml",data=x[0])
900 self.check_vtk("hex_2D_order2p_FunctionOnBoundary_Scalar.xml",reference)
901 def test_hex_2D_order2p_FunctionOnBoundary_Vector_vtk(self):
902 reference="hex_2D_o2p_boundary_v.xml"
903 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_2D_order2p.msh",optimize=False)
904 x=FunctionOnBoundary(dom).getX()
905 saveVTK(FINLEY_WORKDIR_PATH+"hex_2D_order2p_FunctionOnBoundary_Vector.xml",data=x[0]*[1.,2.])
906 self.check_vtk("hex_2D_order2p_FunctionOnBoundary_Vector.xml",reference)
907 def test_hex_2D_order2p_FunctionOnBoundary_Tensor_vtk(self):
908 reference="hex_2D_o2p_boundary_t.xml"
909 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_2D_order2p.msh",optimize=False)
910 x=FunctionOnBoundary(dom).getX()
911 saveVTK(FINLEY_WORKDIR_PATH+"hex_2D_order2p_FunctionOnBoundary_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
912 self.check_vtk("hex_2D_order2p_FunctionOnBoundary_Tensor.xml",reference)
913 def test_hex_2D_order2p_ReducedFunctionOnBoundary_Scalar_vtk(self):
914 reference="hex_2D_o2p_boundary_reduced_s.xml"
915 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_2D_order2p.msh",optimize=False)
916 x=ReducedFunctionOnBoundary(dom).getX()
917 saveVTK(FINLEY_WORKDIR_PATH+"hex_2D_order2p_ReducedFunctionOnBoundary_Scalar.xml",data=x[0])
918 self.check_vtk("hex_2D_order2p_ReducedFunctionOnBoundary_Scalar.xml",reference)
919 def test_hex_2D_order2p_ReducedFunctionOnBoundary_Vector_vtk(self):
920 reference="hex_2D_o2p_boundary_reduced_v.xml"
921 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_2D_order2p.msh",optimize=False)
922 x=ReducedFunctionOnBoundary(dom).getX()
923 saveVTK(FINLEY_WORKDIR_PATH+"hex_2D_order2p_ReducedFunctionOnBoundary_Vector.xml",data=x[0]*[1.,2.])
924 self.check_vtk("hex_2D_order2p_ReducedFunctionOnBoundary_Vector.xml",reference)
925 def test_hex_2D_order2p_ReducedFunctionOnBoundary_Tensor_vtk(self):
926 reference="hex_2D_o2p_boundary_reduced_t.xml"
927 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_2D_order2p.msh",optimize=False)
928 x=ReducedFunctionOnBoundary(dom).getX()
929 saveVTK(FINLEY_WORKDIR_PATH+"hex_2D_order2p_ReducedFunctionOnBoundary_Tensor.xml",data=x[0]*[[11.,12.],[21.,22.]])
930 self.check_vtk("hex_2D_order2p_ReducedFunctionOnBoundary_Tensor.xml",reference)
931
932 # ======================================================================================================================
933 def test_hex_contact_3D_order1_ContinuousFunction_Scalar_vtk(self):
934 reference="hex_3D_o1_node_s.xml"
935 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1.msh",optimize=False)
936 x=ContinuousFunction(dom).getX()
937 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_ContinuousFunction_Scalar.xml",data=x[0])
938 self.check_vtk("hex_contact_3D_order1_ContinuousFunction_Scalar.xml",reference)
939 def test_hex_contact_3D_order1_ContinuousFunction_Vector_vtk(self):
940 reference="hex_3D_o1_node_v.xml"
941 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1.msh",optimize=False)
942 x=ContinuousFunction(dom).getX()
943 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_ContinuousFunction_Vector.xml",data=x[0]*[1.,2.,3.])
944 self.check_vtk("hex_contact_3D_order1_ContinuousFunction_Vector.xml",reference)
945 def test_hex_contact_3D_order1_ContinuousFunction_Tensor_vtk(self):
946 reference="hex_3D_o1_node_t.xml"
947 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1.msh",optimize=False)
948 x=ContinuousFunction(dom).getX()
949 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_ContinuousFunction_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
950 self.check_vtk("hex_contact_3D_order1_ContinuousFunction_Tensor.xml",reference)
951 def test_hex_contact_3D_order1_Solution_Scalar_vtk(self):
952 reference="hex_3D_o1_node_s.xml"
953 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1.msh",optimize=False)
954 x=Solution(dom).getX()
955 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_Solution_Scalar.xml",data=x[0])
956 self.check_vtk("hex_contact_3D_order1_Solution_Scalar.xml",reference)
957 def test_hex_contact_3D_order1_Solution_Vector_vtk(self):
958 reference="hex_3D_o1_node_v.xml"
959 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1.msh",optimize=False)
960 x=Solution(dom).getX()
961 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_Solution_Vector.xml",data=x[0]*[1.,2.,3.])
962 self.check_vtk("hex_contact_3D_order1_Solution_Vector.xml",reference)
963 def test_hex_contact_3D_order1_Solution_Tensor_vtk(self):
964 reference="hex_3D_o1_node_t.xml"
965 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1.msh",optimize=False)
966 x=Solution(dom).getX()
967 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_Solution_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
968 self.check_vtk("hex_contact_3D_order1_Solution_Tensor.xml",reference)
969 def test_hex_contact_3D_order1_ReducedSolution_Scalar_vtk(self):
970 reference="hex_3D_o1_node_s.xml"
971 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1.msh",optimize=False)
972 x=ReducedSolution(dom).getX()
973 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_ReducedSolution_Scalar.xml",data=x[0])
974 self.check_vtk("hex_contact_3D_order1_ReducedSolution_Scalar.xml",reference)
975 def test_hex_contact_3D_order1_ReducedSolution_Vector_vtk(self):
976 reference="hex_3D_o1_node_v.xml"
977 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1.msh",optimize=False)
978 x=ReducedSolution(dom).getX()
979 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_ReducedSolution_Vector.xml",data=x[0]*[1.,2.,3.])
980 self.check_vtk("hex_contact_3D_order1_ReducedSolution_Vector.xml",reference)
981 def test_hex_contact_3D_order1_ReducedSolution_Tensor_vtk(self):
982 reference="hex_3D_o1_node_t.xml"
983 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1.msh",optimize=False)
984 x=ReducedSolution(dom).getX()
985 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_ReducedSolution_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
986 self.check_vtk("hex_contact_3D_order1_ReducedSolution_Tensor.xml",reference)
987 def test_hex_contact_3D_order1_Function_Scalar_vtk(self):
988 reference="hex_3D_o1_cell_s.xml"
989 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1.msh",optimize=False)
990 x=Function(dom).getX()
991 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_Function_Scalar.xml",data=x[0])
992 self.check_vtk("hex_contact_3D_order1_Function_Scalar.xml",reference)
993 def test_hex_contact_3D_order1_Function_Vector_vtk(self):
994 reference="hex_3D_o1_cell_v.xml"
995 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1.msh",optimize=False)
996 x=Function(dom).getX()
997 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_Function_Vector.xml",data=x[0]*[1.,2.,3.])
998 self.check_vtk("hex_contact_3D_order1_Function_Vector.xml",reference)
999 def test_hex_contact_3D_order1_Function_Tensor_vtk(self):
1000 reference="hex_3D_o1_cell_t.xml"
1001 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1.msh",optimize=False)
1002 x=Function(dom).getX()
1003 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_Function_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1004 self.check_vtk("hex_contact_3D_order1_Function_Tensor.xml",reference)
1005 def test_hex_contact_3D_order1_ReducedFunction_Scalar_vtk(self):
1006 reference="hex_3D_o1_cell_s.xml"
1007 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1.msh",optimize=False)
1008 x=ReducedFunction(dom).getX()
1009 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_ReducedFunction_Scalar.xml",data=x[0])
1010 self.check_vtk("hex_contact_3D_order1_ReducedFunction_Scalar.xml",reference)
1011 def test_hex_contact_3D_order1_ReducedFunction_Vector_vtk(self):
1012 reference="hex_3D_o1_cell_v.xml"
1013 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1.msh",optimize=False)
1014 x=ReducedFunction(dom).getX()
1015 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_ReducedFunction_Vector.xml",data=x[0]*[1.,2.,3.])
1016 self.check_vtk("hex_contact_3D_order1_ReducedFunction_Vector.xml",reference)
1017 def test_hex_contact_3D_order1_ReducedFunction_Tensor_vtk(self):
1018 reference="hex_3D_o1_cell_t.xml"
1019 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1.msh",optimize=False)
1020 x=ReducedFunction(dom).getX()
1021 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_ReducedFunction_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1022 self.check_vtk("hex_contact_3D_order1_ReducedFunction_Tensor.xml",reference)
1023 def test_hex_contact_3D_order1_FunctionOnBoundary_Scalar_vtk(self):
1024 reference="hex_3D_o1_boundary_s.xml"
1025 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1.msh",optimize=False)
1026 x=FunctionOnBoundary(dom).getX()
1027 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_FunctionOnBoundary_Scalar.xml",data=x[0])
1028 self.check_vtk("hex_contact_3D_order1_FunctionOnBoundary_Scalar.xml",reference)
1029 def test_hex_contact_3D_order1_FunctionOnBoundary_Vector_vtk(self):
1030 reference="hex_3D_o1_boundary_v.xml"
1031 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1.msh",optimize=False)
1032 x=FunctionOnBoundary(dom).getX()
1033 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_FunctionOnBoundary_Vector.xml",data=x[0]*[1.,2.,3.])
1034 self.check_vtk("hex_contact_3D_order1_FunctionOnBoundary_Vector.xml",reference)
1035 def test_hex_contact_3D_order1_FunctionOnBoundary_Tensor_vtk(self):
1036 reference="hex_3D_o1_boundary_t.xml"
1037 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1.msh",optimize=False)
1038 x=FunctionOnBoundary(dom).getX()
1039 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_FunctionOnBoundary_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1040 self.check_vtk("hex_contact_3D_order1_FunctionOnBoundary_Tensor.xml",reference)
1041 def test_hex_contact_3D_order1_ReducedFunctionOnBoundary_Scalar_vtk(self):
1042 reference="hex_3D_o1_boundary_s.xml"
1043 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1.msh",optimize=False)
1044 x=ReducedFunctionOnBoundary(dom).getX()
1045 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_ReducedFunctionOnBoundary_Scalar.xml",data=x[0])
1046 self.check_vtk("hex_contact_3D_order1_ReducedFunctionOnBoundary_Scalar.xml",reference)
1047 def test_hex_contact_3D_order1_ReducedFunctionOnBoundary_Vector_vtk(self):
1048 reference="hex_3D_o1_boundary_v.xml"
1049 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1.msh",optimize=False)
1050 x=ReducedFunctionOnBoundary(dom).getX()
1051 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_ReducedFunctionOnBoundary_Vector.xml",data=x[0]*[1.,2.,3.])
1052 self.check_vtk("hex_contact_3D_order1_ReducedFunctionOnBoundary_Vector.xml",reference)
1053 def test_hex_contact_3D_order1_ReducedFunctionOnBoundary_Tensor_vtk(self):
1054 reference="hex_3D_o1_boundary_t.xml"
1055 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1.msh",optimize=False)
1056 x=ReducedFunctionOnBoundary(dom).getX()
1057 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_ReducedFunctionOnBoundary_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1058 self.check_vtk("hex_contact_3D_order1_ReducedFunctionOnBoundary_Tensor.xml",reference)
1059 def test_hex_contact_3D_order1_onFace_FunctionOnBoundary_Scalar_vtk(self):
1060 reference="hex_3D_o1_f_boundary_s.xml"
1061 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1_onFace.msh",optimize=False)
1062 x=FunctionOnBoundary(dom).getX()
1063 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_onFace_FunctionOnBoundary_Scalar.xml",data=x[0])
1064 self.check_vtk("hex_contact_3D_order1_onFace_FunctionOnBoundary_Scalar.xml",reference)
1065 def test_hex_contact_3D_order1_onFace_FunctionOnBoundary_Vector_vtk(self):
1066 reference="hex_3D_o1_f_boundary_v.xml"
1067 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1_onFace.msh",optimize=False)
1068 x=FunctionOnBoundary(dom).getX()
1069 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_onFace_FunctionOnBoundary_Vector.xml",data=x[0]*[1.,2.,3.])
1070 self.check_vtk("hex_contact_3D_order1_onFace_FunctionOnBoundary_Vector.xml",reference)
1071 def test_hex_contact_3D_order1_onFace_FunctionOnBoundary_Tensor_vtk(self):
1072 reference="hex_3D_o1_f_boundary_t.xml"
1073 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1_onFace.msh",optimize=False)
1074 x=FunctionOnBoundary(dom).getX()
1075 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_onFace_FunctionOnBoundary_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1076 self.check_vtk("hex_contact_3D_order1_onFace_FunctionOnBoundary_Tensor.xml",reference)
1077 def test_hex_contact_3D_order1_onFace_ReducedFunctionOnBoundary_Scalar_vtk(self):
1078 reference="hex_3D_o1_f_boundary_s.xml"
1079 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1_onFace.msh",optimize=False)
1080 x=ReducedFunctionOnBoundary(dom).getX()
1081 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_onFace_ReducedFunctionOnBoundary_Scalar.xml",data=x[0])
1082 self.check_vtk("hex_contact_3D_order1_onFace_ReducedFunctionOnBoundary_Scalar.xml",reference)
1083 def test_hex_contact_3D_order1_onFace_ReducedFunctionOnBoundary_Vector_vtk(self):
1084 reference="hex_3D_o1_f_boundary_v.xml"
1085 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1_onFace.msh",optimize=False)
1086 x=ReducedFunctionOnBoundary(dom).getX()
1087 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_onFace_ReducedFunctionOnBoundary_Vector.xml",data=x[0]*[1.,2.,3.])
1088 self.check_vtk("hex_contact_3D_order1_onFace_ReducedFunctionOnBoundary_Vector.xml",reference)
1089 def test_hex_contact_3D_order1_onFace_ReducedFunctionOnBoundary_Tensor_vtk(self):
1090 reference="hex_3D_o1_f_boundary_t.xml"
1091 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1_onFace.msh",optimize=False)
1092 x=ReducedFunctionOnBoundary(dom).getX()
1093 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_onFace_ReducedFunctionOnBoundary_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1094 self.check_vtk("hex_contact_3D_order1_onFace_ReducedFunctionOnBoundary_Tensor.xml",reference)
1095 def test_hex_contact_3D_order1_FunctionOnContactZero_Scalar_vtk(self):
1096 reference="hex_3D_o1_contact_s.xml"
1097 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1.msh",optimize=False)
1098 x=FunctionOnContactZero(dom).getX()
1099 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_FunctionOnContactZero_Scalar.xml",data=x[0])
1100 self.check_vtk("hex_contact_3D_order1_FunctionOnContactZero_Scalar.xml",reference)
1101 def test_hex_contact_3D_order1_FunctionOnContactZero_Vector_vtk(self):
1102 reference="hex_3D_o1_contact_v.xml"
1103 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1.msh",optimize=False)
1104 x=FunctionOnContactZero(dom).getX()
1105 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_FunctionOnContactZero_Vector.xml",data=x[0]*[1.,2.,3.])
1106 self.check_vtk("hex_contact_3D_order1_FunctionOnContactZero_Vector.xml",reference)
1107 def test_hex_contact_3D_order1_FunctionOnContactZero_Tensor_vtk(self):
1108 reference="hex_3D_o1_contact_t.xml"
1109 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1.msh",optimize=False)
1110 x=FunctionOnContactZero(dom).getX()
1111 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_FunctionOnContactZero_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1112 self.check_vtk("hex_contact_3D_order1_FunctionOnContactZero_Tensor.xml",reference)
1113 def test_hex_contact_3D_order1_ReducedFunctionOnContactZero_Scalar_vtk(self):
1114 reference="hex_3D_o1_contact_s.xml"
1115 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1.msh",optimize=False)
1116 x=ReducedFunctionOnContactZero(dom).getX()
1117 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_ReducedFunctionOnContactZero_Scalar.xml",data=x[0])
1118 self.check_vtk("hex_contact_3D_order1_ReducedFunctionOnContactZero_Scalar.xml",reference)
1119 def test_hex_contact_3D_order1_ReducedFunctionOnContactZero_Vector_vtk(self):
1120 reference="hex_3D_o1_contact_v.xml"
1121 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1.msh",optimize=False)
1122 x=ReducedFunctionOnContactZero(dom).getX()
1123 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_ReducedFunctionOnContactZero_Vector.xml",data=x[0]*[1.,2.,3.])
1124 self.check_vtk("hex_contact_3D_order1_ReducedFunctionOnContactZero_Vector.xml",reference)
1125 def test_hex_contact_3D_order1_ReducedFunctionOnContactZero_Tensor_vtk(self):
1126 reference="hex_3D_o1_contact_t.xml"
1127 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1.msh",optimize=False)
1128 x=ReducedFunctionOnContactZero(dom).getX()
1129 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_ReducedFunctionOnContactZero_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1130 self.check_vtk("hex_contact_3D_order1_ReducedFunctionOnContactZero_Tensor.xml",reference)
1131 def test_hex_contact_3D_order1_onFace_FunctionOnContactZero_Scalar_vtk(self):
1132 reference="hex_3D_o1_contact_s.xml"
1133 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1_onFace.msh",optimize=False)
1134 x=FunctionOnContactZero(dom).getX()
1135 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_onFace_FunctionOnContactZero_Scalar.xml",data=x[0])
1136 self.check_vtk("hex_contact_3D_order1_onFace_FunctionOnContactZero_Scalar.xml",reference)
1137 def test_hex_contact_3D_order1_onFace_FunctionOnContactZero_Vector_vtk(self):
1138 reference="hex_3D_o1_contact_v.xml"
1139 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1_onFace.msh",optimize=False)
1140 x=FunctionOnContactZero(dom).getX()
1141 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_onFace_FunctionOnContactZero_Vector.xml",data=x[0]*[1.,2.,3.])
1142 self.check_vtk("hex_contact_3D_order1_onFace_FunctionOnContactZero_Vector.xml",reference)
1143 def test_hex_contact_3D_order1_onFace_FunctionOnContactZero_Tensor_vtk(self):
1144 reference="hex_3D_o1_contact_t.xml"
1145 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1_onFace.msh",optimize=False)
1146 x=FunctionOnContactZero(dom).getX()
1147 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_onFace_FunctionOnContactZero_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1148 self.check_vtk("hex_contact_3D_order1_onFace_FunctionOnContactZero_Tensor.xml",reference)
1149 def test_hex_contact_3D_order1_onFace_ReducedFunctionOnContactZero_Scalar_vtk(self):
1150 reference="hex_3D_o1_contact_s.xml"
1151 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1_onFace.msh",optimize=False)
1152 x=ReducedFunctionOnContactZero(dom).getX()
1153 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_onFace_ReducedFunctionOnContactZero_Scalar.xml",data=x[0])
1154 self.check_vtk("hex_contact_3D_order1_onFace_ReducedFunctionOnContactZero_Scalar.xml",reference)
1155 def test_hex_contact_3D_order1_onFace_ReducedFunctionOnContactZero_Vector_vtk(self):
1156 reference="hex_3D_o1_contact_v.xml"
1157 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1_onFace.msh",optimize=False)
1158 x=ReducedFunctionOnContactZero(dom).getX()
1159 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_onFace_ReducedFunctionOnContactZero_Vector.xml",data=x[0]*[1.,2.,3.])
1160 self.check_vtk("hex_contact_3D_order1_onFace_ReducedFunctionOnContactZero_Vector.xml",reference)
1161 def test_hex_contact_3D_order1_onFace_ReducedFunctionOnContactZero_Tensor_vtk(self):
1162 reference="hex_3D_o1_contact_t.xml"
1163 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1_onFace.msh",optimize=False)
1164 x=ReducedFunctionOnContactZero(dom).getX()
1165 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_onFace_ReducedFunctionOnContactZero_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1166 self.check_vtk("hex_contact_3D_order1_onFace_ReducedFunctionOnContactZero_Tensor.xml",reference)
1167 def test_hex_contact_3D_order1_FunctionOnContactOne_Scalar_vtk(self):
1168 reference="hex_3D_o1_contact_s.xml"
1169 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1.msh",optimize=False)
1170 x=FunctionOnContactOne(dom).getX()
1171 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_FunctionOnContactOne_Scalar.xml",data=x[0])
1172 self.check_vtk("hex_contact_3D_order1_FunctionOnContactOne_Scalar.xml",reference)
1173 def test_hex_contact_3D_order1_FunctionOnContactOne_Vector_vtk(self):
1174 reference="hex_3D_o1_contact_v.xml"
1175 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1.msh",optimize=False)
1176 x=FunctionOnContactOne(dom).getX()
1177 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_FunctionOnContactOne_Vector.xml",data=x[0]*[1.,2.,3.])
1178 self.check_vtk("hex_contact_3D_order1_FunctionOnContactOne_Vector.xml",reference)
1179 def test_hex_contact_3D_order1_FunctionOnContactOne_Tensor_vtk(self):
1180 reference="hex_3D_o1_contact_t.xml"
1181 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1.msh",optimize=False)
1182 x=FunctionOnContactOne(dom).getX()
1183 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_FunctionOnContactOne_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1184 self.check_vtk("hex_contact_3D_order1_FunctionOnContactOne_Tensor.xml",reference)
1185 def test_hex_contact_3D_order1_ReducedFunctionOnContactOne_Scalar_vtk(self):
1186 reference="hex_3D_o1_contact_s.xml"
1187 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1.msh",optimize=False)
1188 x=ReducedFunctionOnContactOne(dom).getX()
1189 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_ReducedFunctionOnContactOne_Scalar.xml",data=x[0])
1190 self.check_vtk("hex_contact_3D_order1_ReducedFunctionOnContactOne_Scalar.xml",reference)
1191 def test_hex_contact_3D_order1_ReducedFunctionOnContactOne_Vector_vtk(self):
1192 reference="hex_3D_o1_contact_v.xml"
1193 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1.msh",optimize=False)
1194 x=ReducedFunctionOnContactOne(dom).getX()
1195 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_ReducedFunctionOnContactOne_Vector.xml",data=x[0]*[1.,2.,3.])
1196 self.check_vtk("hex_contact_3D_order1_ReducedFunctionOnContactOne_Vector.xml",reference)
1197 def test_hex_contact_3D_order1_ReducedFunctionOnContactOne_Tensor_vtk(self):
1198 reference="hex_3D_o1_contact_t.xml"
1199 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1.msh",optimize=False)
1200 x=ReducedFunctionOnContactOne(dom).getX()
1201 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_ReducedFunctionOnContactOne_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1202 self.check_vtk("hex_contact_3D_order1_ReducedFunctionOnContactOne_Tensor.xml",reference)
1203 def test_hex_contact_3D_order1_onFace_FunctionOnContactOne_Scalar_vtk(self):
1204 reference="hex_3D_o1_contact_s.xml"
1205 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1_onFace.msh",optimize=False)
1206 x=FunctionOnContactOne(dom).getX()
1207 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_onFace_FunctionOnContactOne_Scalar.xml",data=x[0])
1208 self.check_vtk("hex_contact_3D_order1_onFace_FunctionOnContactOne_Scalar.xml",reference)
1209 def test_hex_contact_3D_order1_onFace_FunctionOnContactOne_Vector_vtk(self):
1210 reference="hex_3D_o1_contact_v.xml"
1211 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1_onFace.msh",optimize=False)
1212 x=FunctionOnContactOne(dom).getX()
1213 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_onFace_FunctionOnContactOne_Vector.xml",data=x[0]*[1.,2.,3.])
1214 self.check_vtk("hex_contact_3D_order1_onFace_FunctionOnContactOne_Vector.xml",reference)
1215 def test_hex_contact_3D_order1_onFace_FunctionOnContactOne_Tensor_vtk(self):
1216 reference="hex_3D_o1_contact_t.xml"
1217 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1_onFace.msh",optimize=False)
1218 x=FunctionOnContactOne(dom).getX()
1219 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_onFace_FunctionOnContactOne_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1220 self.check_vtk("hex_contact_3D_order1_onFace_FunctionOnContactOne_Tensor.xml",reference)
1221 def test_hex_contact_3D_order1_onFace_ReducedFunctionOnContactOne_Scalar_vtk(self):
1222 reference="hex_3D_o1_contact_s.xml"
1223 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1_onFace.msh",optimize=False)
1224 x=ReducedFunctionOnContactOne(dom).getX()
1225 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_onFace_ReducedFunctionOnContactOne_Scalar.xml",data=x[0])
1226 self.check_vtk("hex_contact_3D_order1_onFace_ReducedFunctionOnContactOne_Scalar.xml",reference)
1227 def test_hex_contact_3D_order1_onFace_ReducedFunctionOnContactOne_Vector_vtk(self):
1228 reference="hex_3D_o1_contact_v.xml"
1229 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1_onFace.msh",optimize=False)
1230 x=ReducedFunctionOnContactOne(dom).getX()
1231 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_onFace_ReducedFunctionOnContactOne_Vector.xml",data=x[0]*[1.,2.,3.])
1232 self.check_vtk("hex_contact_3D_order1_onFace_ReducedFunctionOnContactOne_Vector.xml",reference)
1233 def test_hex_contact_3D_order1_onFace_ReducedFunctionOnContactOne_Tensor_vtk(self):
1234 reference="hex_3D_o1_contact_t.xml"
1235 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order1_onFace.msh",optimize=False)
1236 x=ReducedFunctionOnContactOne(dom).getX()
1237 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order1_onFace_ReducedFunctionOnContactOne_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1238 self.check_vtk("hex_contact_3D_order1_onFace_ReducedFunctionOnContactOne_Tensor.xml",reference)
1239 # ======================================================================================================================
1240 def test_hex_contact_3D_order2_ContinuousFunction_Scalar_vtk(self):
1241 reference="hex_3D_o2_node_s.xml"
1242 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2.msh",optimize=False)
1243 x=ContinuousFunction(dom).getX()
1244 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_ContinuousFunction_Scalar.xml",data=x[0])
1245 self.check_vtk("hex_contact_3D_order2_ContinuousFunction_Scalar.xml",reference)
1246 def test_hex_contact_3D_order2_ContinuousFunction_Vector_vtk(self):
1247 reference="hex_3D_o2_node_v.xml"
1248 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2.msh",optimize=False)
1249 x=ContinuousFunction(dom).getX()
1250 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_ContinuousFunction_Vector.xml",data=x[0]*[1.,2.,3.])
1251 self.check_vtk("hex_contact_3D_order2_ContinuousFunction_Vector.xml",reference)
1252 def test_hex_contact_3D_order2_ContinuousFunction_Tensor_vtk(self):
1253 reference="hex_3D_o2_node_t.xml"
1254 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2.msh",optimize=False)
1255 x=ContinuousFunction(dom).getX()
1256 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_ContinuousFunction_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1257 self.check_vtk("hex_contact_3D_order2_ContinuousFunction_Tensor.xml",reference)
1258 def test_hex_contact_3D_order2_Solution_Scalar_vtk(self):
1259 reference="hex_3D_o2_node_s.xml"
1260 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2.msh",optimize=False)
1261 x=Solution(dom).getX()
1262 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_Solution_Scalar.xml",data=x[0])
1263 self.check_vtk("hex_contact_3D_order2_Solution_Scalar.xml",reference)
1264 def test_hex_contact_3D_order2_Solution_Vector_vtk(self):
1265 reference="hex_3D_o2_node_v.xml"
1266 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2.msh",optimize=False)
1267 x=Solution(dom).getX()
1268 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_Solution_Vector.xml",data=x[0]*[1.,2.,3.])
1269 self.check_vtk("hex_contact_3D_order2_Solution_Vector.xml",reference)
1270 def test_hex_contact_3D_order2_Solution_Tensor_vtk(self):
1271 reference="hex_3D_o2_node_t.xml"
1272 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2.msh",optimize=False)
1273 x=Solution(dom).getX()
1274 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_Solution_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1275 self.check_vtk("hex_contact_3D_order2_Solution_Tensor.xml",reference)
1276 def test_hex_contact_3D_order2_ReducedSolution_Scalar_vtk(self):
1277 reference="hex_3D_o1_node_s.xml"
1278 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2.msh",optimize=False)
1279 x=ReducedSolution(dom).getX()
1280 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_ReducedSolution_Scalar.xml",data=x[0])
1281 self.check_vtk("hex_contact_3D_order2_ReducedSolution_Scalar.xml",reference)
1282 def test_hex_contact_3D_order2_ReducedSolution_Vector_vtk(self):
1283 reference="hex_3D_o1_node_v.xml"
1284 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2.msh",optimize=False)
1285 x=ReducedSolution(dom).getX()
1286 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_ReducedSolution_Vector.xml",data=x[0]*[1.,2.,3.])
1287 self.check_vtk("hex_contact_3D_order2_ReducedSolution_Vector.xml",reference)
1288 def test_hex_contact_3D_order2_ReducedSolution_Tensor_vtk(self):
1289 reference="hex_3D_o1_node_t.xml"
1290 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2.msh",optimize=False)
1291 x=ReducedSolution(dom).getX()
1292 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_ReducedSolution_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1293 self.check_vtk("hex_contact_3D_order2_ReducedSolution_Tensor.xml",reference)
1294 def test_hex_contact_3D_order2_Function_Scalar_vtk(self):
1295 reference="hex_3D_o2_cell_s.xml"
1296 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2.msh",optimize=False)
1297 x=Function(dom).getX()
1298 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_Function_Scalar.xml",data=x[0])
1299 self.check_vtk("hex_contact_3D_order2_Function_Scalar.xml",reference)
1300 def test_hex_contact_3D_order2_Function_Vector_vtk(self):
1301 reference="hex_3D_o2_cell_v.xml"
1302 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2.msh",optimize=False)
1303 x=Function(dom).getX()
1304 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_Function_Vector.xml",data=x[0]*[1.,2.,3.])
1305 self.check_vtk("hex_contact_3D_order2_Function_Vector.xml",reference)
1306 def test_hex_contact_3D_order2_Function_Tensor_vtk(self):
1307 reference="hex_3D_o2_cell_t.xml"
1308 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2.msh",optimize=False)
1309 x=Function(dom).getX()
1310 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_Function_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1311 self.check_vtk("hex_contact_3D_order2_Function_Tensor.xml",reference)
1312 def test_hex_contact_3D_order2_ReducedFunction_Scalar_vtk(self):
1313 reference="hex_3D_o2_cell_s.xml"
1314 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2.msh",optimize=False)
1315 x=ReducedFunction(dom).getX()
1316 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_ReducedFunction_Scalar.xml",data=x[0])
1317 self.check_vtk("hex_contact_3D_order2_ReducedFunction_Scalar.xml",reference)
1318 def test_hex_contact_3D_order2_ReducedFunction_Vector_vtk(self):
1319 reference="hex_3D_o2_cell_v.xml"
1320 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2.msh",optimize=False)
1321 x=ReducedFunction(dom).getX()
1322 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_ReducedFunction_Vector.xml",data=x[0]*[1.,2.,3.])
1323 self.check_vtk("hex_contact_3D_order2_ReducedFunction_Vector.xml",reference)
1324 def test_hex_contact_3D_order2_ReducedFunction_Tensor_vtk(self):
1325 reference="hex_3D_o2_cell_t.xml"
1326 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2.msh",optimize=False)
1327 x=ReducedFunction(dom).getX()
1328 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_ReducedFunction_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1329 self.check_vtk("hex_contact_3D_order2_ReducedFunction_Tensor.xml",reference)
1330 def test_hex_contact_3D_order2_FunctionOnBoundary_Scalar_vtk(self):
1331 reference="hex_3D_o2_boundary_s.xml"
1332 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2.msh",optimize=False)
1333 x=FunctionOnBoundary(dom).getX()
1334 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_FunctionOnBoundary_Scalar.xml",data=x[0])
1335 self.check_vtk("hex_contact_3D_order2_FunctionOnBoundary_Scalar.xml",reference)
1336 def test_hex_contact_3D_order2_FunctionOnBoundary_Vector_vtk(self):
1337 reference="hex_3D_o2_boundary_v.xml"
1338 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2.msh",optimize=False)
1339 x=FunctionOnBoundary(dom).getX()
1340 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_FunctionOnBoundary_Vector.xml",data=x[0]*[1.,2.,3.])
1341 self.check_vtk("hex_contact_3D_order2_FunctionOnBoundary_Vector.xml",reference)
1342 def test_hex_contact_3D_order2_FunctionOnBoundary_Tensor_vtk(self):
1343 reference="hex_3D_o2_boundary_t.xml"
1344 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2.msh",optimize=False)
1345 x=FunctionOnBoundary(dom).getX()
1346 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_FunctionOnBoundary_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1347 self.check_vtk("hex_contact_3D_order2_FunctionOnBoundary_Tensor.xml",reference)
1348 def test_hex_contact_3D_order2_ReducedFunctionOnBoundary_Scalar_vtk(self):
1349 reference="hex_3D_o2_boundary_s.xml"
1350 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2.msh",optimize=False)
1351 x=ReducedFunctionOnBoundary(dom).getX()
1352 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_ReducedFunctionOnBoundary_Scalar.xml",data=x[0])
1353 self.check_vtk("hex_contact_3D_order2_ReducedFunctionOnBoundary_Scalar.xml",reference)
1354 def test_hex_contact_3D_order2_ReducedFunctionOnBoundary_Vector_vtk(self):
1355 reference="hex_3D_o2_boundary_v.xml"
1356 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2.msh",optimize=False)
1357 x=ReducedFunctionOnBoundary(dom).getX()
1358 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_ReducedFunctionOnBoundary_Vector.xml",data=x[0]*[1.,2.,3.])
1359 self.check_vtk("hex_contact_3D_order2_ReducedFunctionOnBoundary_Vector.xml",reference)
1360 def test_hex_contact_3D_order2_ReducedFunctionOnBoundary_Tensor_vtk(self):
1361 reference="hex_3D_o2_boundary_t.xml"
1362 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2.msh",optimize=False)
1363 x=ReducedFunctionOnBoundary(dom).getX()
1364 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_ReducedFunctionOnBoundary_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1365 self.check_vtk("hex_contact_3D_order2_ReducedFunctionOnBoundary_Tensor.xml",reference)
1366 def test_hex_contact_3D_order2_onFace_FunctionOnBoundary_Scalar_vtk(self):
1367 reference="hex_3D_o2_f_boundary_s.xml"
1368 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2_onFace.msh",optimize=False)
1369 x=FunctionOnBoundary(dom).getX()
1370 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_onFace_FunctionOnBoundary_Scalar.xml",data=x[0])
1371 self.check_vtk("hex_contact_3D_order2_onFace_FunctionOnBoundary_Scalar.xml",reference)
1372 def test_hex_contact_3D_order2_onFace_FunctionOnBoundary_Vector_vtk(self):
1373 reference="hex_3D_o2_f_boundary_v.xml"
1374 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2_onFace.msh",optimize=False)
1375 x=FunctionOnBoundary(dom).getX()
1376 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_onFace_FunctionOnBoundary_Vector.xml",data=x[0]*[1.,2.,3.])
1377 self.check_vtk("hex_contact_3D_order2_onFace_FunctionOnBoundary_Vector.xml",reference)
1378 def test_hex_contact_3D_order2_onFace_FunctionOnBoundary_Tensor_vtk(self):
1379 reference="hex_3D_o2_f_boundary_t.xml"
1380 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2_onFace.msh",optimize=False)
1381 x=FunctionOnBoundary(dom).getX()
1382 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_onFace_FunctionOnBoundary_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1383 self.check_vtk("hex_contact_3D_order2_onFace_FunctionOnBoundary_Tensor.xml",reference)
1384 def test_hex_contact_3D_order2_onFace_ReducedFunctionOnBoundary_Scalar_vtk(self):
1385 reference="hex_3D_o2_f_boundary_s.xml"
1386 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2_onFace.msh",optimize=False)
1387 x=ReducedFunctionOnBoundary(dom).getX()
1388 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_onFace_ReducedFunctionOnBoundary_Scalar.xml",data=x[0])
1389 self.check_vtk("hex_contact_3D_order2_onFace_ReducedFunctionOnBoundary_Scalar.xml",reference)
1390 def test_hex_contact_3D_order2_onFace_ReducedFunctionOnBoundary_Vector_vtk(self):
1391 reference="hex_3D_o2_f_boundary_v.xml"
1392 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2_onFace.msh",optimize=False)
1393 x=ReducedFunctionOnBoundary(dom).getX()
1394 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_onFace_ReducedFunctionOnBoundary_Vector.xml",data=x[0]*[1.,2.,3.])
1395 self.check_vtk("hex_contact_3D_order2_onFace_ReducedFunctionOnBoundary_Vector.xml",reference)
1396 def test_hex_contact_3D_order2_onFace_ReducedFunctionOnBoundary_Tensor_vtk(self):
1397 reference="hex_3D_o2_f_boundary_t.xml"
1398 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2_onFace.msh",optimize=False)
1399 x=ReducedFunctionOnBoundary(dom).getX()
1400 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_onFace_ReducedFunctionOnBoundary_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1401 self.check_vtk("hex_contact_3D_order2_onFace_ReducedFunctionOnBoundary_Tensor.xml",reference)
1402 def test_hex_contact_3D_order2_FunctionOnContactZero_Scalar_vtk(self):
1403 reference="hex_3D_o2_contact_s.xml"
1404 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2.msh",optimize=False)
1405 x=FunctionOnContactZero(dom).getX()
1406 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_FunctionOnContactZero_Scalar.xml",data=x[0])
1407 self.check_vtk("hex_contact_3D_order2_FunctionOnContactZero_Scalar.xml",reference)
1408 def test_hex_contact_3D_order2_FunctionOnContactZero_Vector_vtk(self):
1409 reference="hex_3D_o2_contact_v.xml"
1410 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2.msh",optimize=False)
1411 x=FunctionOnContactZero(dom).getX()
1412 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_FunctionOnContactZero_Vector.xml",data=x[0]*[1.,2.,3.])
1413 self.check_vtk("hex_contact_3D_order2_FunctionOnContactZero_Vector.xml",reference)
1414 def test_hex_contact_3D_order2_FunctionOnContactZero_Tensor_vtk(self):
1415 reference="hex_3D_o2_contact_t.xml"
1416 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2.msh",optimize=False)
1417 x=FunctionOnContactZero(dom).getX()
1418 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_FunctionOnContactZero_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1419 self.check_vtk("hex_contact_3D_order2_FunctionOnContactZero_Tensor.xml",reference)
1420 def test_hex_contact_3D_order2_ReducedFunctionOnContactZero_Scalar_vtk(self):
1421 reference="hex_3D_o2_contact_s.xml"
1422 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2.msh",optimize=False)
1423 x=ReducedFunctionOnContactZero(dom).getX()
1424 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_ReducedFunctionOnContactZero_Scalar.xml",data=x[0])
1425 self.check_vtk("hex_contact_3D_order2_ReducedFunctionOnContactZero_Scalar.xml",reference)
1426 def test_hex_contact_3D_order2_ReducedFunctionOnContactZero_Vector_vtk(self):
1427 reference="hex_3D_o2_contact_v.xml"
1428 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2.msh",optimize=False)
1429 x=ReducedFunctionOnContactZero(dom).getX()
1430 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_ReducedFunctionOnContactZero_Vector.xml",data=x[0]*[1.,2.,3.])
1431 self.check_vtk("hex_contact_3D_order2_ReducedFunctionOnContactZero_Vector.xml",reference)
1432 def test_hex_contact_3D_order2_ReducedFunctionOnContactZero_Tensor_vtk(self):
1433 reference="hex_3D_o2_contact_t.xml"
1434 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2.msh",optimize=False)
1435 x=ReducedFunctionOnContactZero(dom).getX()
1436 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_ReducedFunctionOnContactZero_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1437 self.check_vtk("hex_contact_3D_order2_ReducedFunctionOnContactZero_Tensor.xml",reference)
1438 def test_hex_contact_3D_order2_onFace_FunctionOnContactZero_Scalar_vtk(self):
1439 reference="hex_3D_o2_contact_s.xml"
1440 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2_onFace.msh",optimize=False)
1441 x=FunctionOnContactZero(dom).getX()
1442 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_onFace_FunctionOnContactZero_Scalar.xml",data=x[0])
1443 self.check_vtk("hex_contact_3D_order2_onFace_FunctionOnContactZero_Scalar.xml",reference)
1444 def test_hex_contact_3D_order2_onFace_FunctionOnContactZero_Vector_vtk(self):
1445 reference="hex_3D_o2_contact_v.xml"
1446 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2_onFace.msh",optimize=False)
1447 x=FunctionOnContactZero(dom).getX()
1448 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_onFace_FunctionOnContactZero_Vector.xml",data=x[0]*[1.,2.,3.])
1449 self.check_vtk("hex_contact_3D_order2_onFace_FunctionOnContactZero_Vector.xml",reference)
1450 def test_hex_contact_3D_order2_onFace_FunctionOnContactZero_Tensor_vtk(self):
1451 reference="hex_3D_o2_contact_t.xml"
1452 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2_onFace.msh",optimize=False)
1453 x=FunctionOnContactZero(dom).getX()
1454 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_onFace_FunctionOnContactZero_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1455 self.check_vtk("hex_contact_3D_order2_onFace_FunctionOnContactZero_Tensor.xml",reference)
1456 def test_hex_contact_3D_order2_onFace_ReducedFunctionOnContactZero_Scalar_vtk(self):
1457 reference="hex_3D_o2_contact_s.xml"
1458 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2_onFace.msh",optimize=False)
1459 x=ReducedFunctionOnContactZero(dom).getX()
1460 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_onFace_ReducedFunctionOnContactZero_Scalar.xml",data=x[0])
1461 self.check_vtk("hex_contact_3D_order2_onFace_ReducedFunctionOnContactZero_Scalar.xml",reference)
1462 def test_hex_contact_3D_order2_onFace_ReducedFunctionOnContactZero_Vector_vtk(self):
1463 reference="hex_3D_o2_contact_v.xml"
1464 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2_onFace.msh",optimize=False)
1465 x=ReducedFunctionOnContactZero(dom).getX()
1466 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_onFace_ReducedFunctionOnContactZero_Vector.xml",data=x[0]*[1.,2.,3.])
1467 self.check_vtk("hex_contact_3D_order2_onFace_ReducedFunctionOnContactZero_Vector.xml",reference)
1468 def test_hex_contact_3D_order2_onFace_ReducedFunctionOnContactZero_Tensor_vtk(self):
1469 reference="hex_3D_o2_contact_t.xml"
1470 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2_onFace.msh",optimize=False)
1471 x=ReducedFunctionOnContactZero(dom).getX()
1472 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_onFace_ReducedFunctionOnContactZero_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1473 self.check_vtk("hex_contact_3D_order2_onFace_ReducedFunctionOnContactZero_Tensor.xml",reference)
1474 def test_hex_contact_3D_order2_FunctionOnContactOne_Scalar_vtk(self):
1475 reference="hex_3D_o2_contact_s.xml"
1476 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2.msh",optimize=False)
1477 x=FunctionOnContactOne(dom).getX()
1478 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_FunctionOnContactOne_Scalar.xml",data=x[0])
1479 self.check_vtk("hex_contact_3D_order2_FunctionOnContactOne_Scalar.xml",reference)
1480 def test_hex_contact_3D_order2_FunctionOnContactOne_Vector_vtk(self):
1481 reference="hex_3D_o2_contact_v.xml"
1482 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2.msh",optimize=False)
1483 x=FunctionOnContactOne(dom).getX()
1484 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_FunctionOnContactOne_Vector.xml",data=x[0]*[1.,2.,3.])
1485 self.check_vtk("hex_contact_3D_order2_FunctionOnContactOne_Vector.xml",reference)
1486 def test_hex_contact_3D_order2_FunctionOnContactOne_Tensor_vtk(self):
1487 reference="hex_3D_o2_contact_t.xml"
1488 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2.msh",optimize=False)
1489 x=FunctionOnContactOne(dom).getX()
1490 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_FunctionOnContactOne_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1491 self.check_vtk("hex_contact_3D_order2_FunctionOnContactOne_Tensor.xml",reference)
1492 def test_hex_contact_3D_order2_ReducedFunctionOnContactOne_Scalar_vtk(self):
1493 reference="hex_3D_o2_contact_s.xml"
1494 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2.msh",optimize=False)
1495 x=ReducedFunctionOnContactOne(dom).getX()
1496 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_ReducedFunctionOnContactOne_Scalar.xml",data=x[0])
1497 self.check_vtk("hex_contact_3D_order2_ReducedFunctionOnContactOne_Scalar.xml",reference)
1498 def test_hex_contact_3D_order2_ReducedFunctionOnContactOne_Vector_vtk(self):
1499 reference="hex_3D_o2_contact_v.xml"
1500 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2.msh",optimize=False)
1501 x=ReducedFunctionOnContactOne(dom).getX()
1502 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_ReducedFunctionOnContactOne_Vector.xml",data=x[0]*[1.,2.,3.])
1503 self.check_vtk("hex_contact_3D_order2_ReducedFunctionOnContactOne_Vector.xml",reference)
1504 def test_hex_contact_3D_order2_ReducedFunctionOnContactOne_Tensor_vtk(self):
1505 reference="hex_3D_o2_contact_t.xml"
1506 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2.msh",optimize=False)
1507 x=ReducedFunctionOnContactOne(dom).getX()
1508 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_ReducedFunctionOnContactOne_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1509 self.check_vtk("hex_contact_3D_order2_ReducedFunctionOnContactOne_Tensor.xml",reference)
1510 def test_hex_contact_3D_order2_onFace_FunctionOnContactOne_Scalar_vtk(self):
1511 reference="hex_3D_o2_contact_s.xml"
1512 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2_onFace.msh",optimize=False)
1513 x=FunctionOnContactOne(dom).getX()
1514 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_onFace_FunctionOnContactOne_Scalar.xml",data=x[0])
1515 self.check_vtk("hex_contact_3D_order2_onFace_FunctionOnContactOne_Scalar.xml",reference)
1516 def test_hex_contact_3D_order2_onFace_FunctionOnContactOne_Vector_vtk(self):
1517 reference="hex_3D_o2_contact_v.xml"
1518 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2_onFace.msh",optimize=False)
1519 x=FunctionOnContactOne(dom).getX()
1520 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_onFace_FunctionOnContactOne_Vector.xml",data=x[0]*[1.,2.,3.])
1521 self.check_vtk("hex_contact_3D_order2_onFace_FunctionOnContactOne_Vector.xml",reference)
1522 def test_hex_contact_3D_order2_onFace_FunctionOnContactOne_Tensor_vtk(self):
1523 reference="hex_3D_o2_contact_t.xml"
1524 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2_onFace.msh",optimize=False)
1525 x=FunctionOnContactOne(dom).getX()
1526 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_onFace_FunctionOnContactOne_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1527 self.check_vtk("hex_contact_3D_order2_onFace_FunctionOnContactOne_Tensor.xml",reference)
1528 def test_hex_contact_3D_order2_onFace_ReducedFunctionOnContactOne_Scalar_vtk(self):
1529 reference="hex_3D_o2_contact_s.xml"
1530 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2_onFace.msh",optimize=False)
1531 x=ReducedFunctionOnContactOne(dom).getX()
1532 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_onFace_ReducedFunctionOnContactOne_Scalar.xml",data=x[0])
1533 self.check_vtk("hex_contact_3D_order2_onFace_ReducedFunctionOnContactOne_Scalar.xml",reference)
1534 def test_hex_contact_3D_order2_onFace_ReducedFunctionOnContactOne_Vector_vtk(self):
1535 reference="hex_3D_o2_contact_v.xml"
1536 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2_onFace.msh",optimize=False)
1537 x=ReducedFunctionOnContactOne(dom).getX()
1538 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_onFace_ReducedFunctionOnContactOne_Vector.xml",data=x[0]*[1.,2.,3.])
1539 self.check_vtk("hex_contact_3D_order2_onFace_ReducedFunctionOnContactOne_Vector.xml",reference)
1540 def test_hex_contact_3D_order2_onFace_ReducedFunctionOnContactOne_Tensor_vtk(self):
1541 reference="hex_3D_o2_contact_t.xml"
1542 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_contact_3D_order2_onFace.msh",optimize=False)
1543 x=ReducedFunctionOnContactOne(dom).getX()
1544 saveVTK(FINLEY_WORKDIR_PATH+"hex_contact_3D_order2_onFace_ReducedFunctionOnContactOne_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1545 self.check_vtk("hex_contact_3D_order2_onFace_ReducedFunctionOnContactOne_Tensor.xml",reference)
1546 def test_hex_3D_order2p_ContinuousFunction_Scalar_vtk(self):
1547 reference="hex_3D_o2p_node_s.xml"
1548 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_3D_order2p.msh",optimize=False)
1549 x=ContinuousFunction(dom).getX()
1550 saveVTK(FINLEY_WORKDIR_PATH+"hex_3D_order2p_ContinuousFunction_Scalar.xml",data=x[0])
1551 self.check_vtk("hex_3D_order2p_ContinuousFunction_Scalar.xml",reference)
1552 def test_hex_3D_order2p_ContinuousFunction_Vector_vtk(self):
1553 reference="hex_3D_o2p_node_v.xml"
1554 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_3D_order2p.msh",optimize=False)
1555 x=ContinuousFunction(dom).getX()
1556 saveVTK(FINLEY_WORKDIR_PATH+"hex_3D_order2p_ContinuousFunction_Vector.xml",data=x[0]*[1.,2.,3.])
1557 self.check_vtk("hex_3D_order2p_ContinuousFunction_Vector.xml",reference)
1558 def test_hex_3D_order2p_ContinuousFunction_Tensor_vtk(self):
1559 reference="hex_3D_o2p_node_t.xml"
1560 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_3D_order2p.msh",optimize=False)
1561 x=ContinuousFunction(dom).getX()
1562 saveVTK(FINLEY_WORKDIR_PATH+"hex_3D_order2p_ContinuousFunction_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1563 self.check_vtk("hex_3D_order2p_ContinuousFunction_Tensor.xml",reference)
1564 def test_hex_3D_order2p_Solution_Scalar_vtk(self):
1565 reference="hex_3D_o2p_node_s.xml"
1566 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_3D_order2p.msh",optimize=False)
1567 x=Solution(dom).getX()
1568 saveVTK(FINLEY_WORKDIR_PATH+"hex_3D_order2p_Solution_Scalar.xml",data=x[0])
1569 self.check_vtk("hex_3D_order2p_Solution_Scalar.xml",reference)
1570 def test_hex_3D_order2p_Solution_Vector_vtk(self):
1571 reference="hex_3D_o2p_node_v.xml"
1572 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_3D_order2p.msh",optimize=False)
1573 x=Solution(dom).getX()
1574 saveVTK(FINLEY_WORKDIR_PATH+"hex_3D_order2p_Solution_Vector.xml",data=x[0]*[1.,2.,3.])
1575 self.check_vtk("hex_3D_order2p_Solution_Vector.xml",reference)
1576 def test_hex_3D_order2p_Solution_Tensor_vtk(self):
1577 reference="hex_3D_o2p_node_t.xml"
1578 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_3D_order2p.msh",optimize=False)
1579 x=Solution(dom).getX()
1580 saveVTK(FINLEY_WORKDIR_PATH+"hex_3D_order2p_Solution_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1581 self.check_vtk("hex_3D_order2p_Solution_Tensor.xml",reference)
1582 def test_hex_3D_order2p_ReducedSolution_Scalar_vtk(self):
1583 reference="hex_3D_o2p_reduced_node_s.xml"
1584 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_3D_order2p.msh",optimize=False)
1585 x=ReducedSolution(dom).getX()
1586 saveVTK(FINLEY_WORKDIR_PATH+"hex_3D_order2p_ReducedSolution_Scalar.xml",data=x[0])
1587 self.check_vtk("hex_3D_order2p_ReducedSolution_Scalar.xml",reference)
1588 def test_hex_3D_order2p_ReducedSolution_Vector_vtk(self):
1589 reference="hex_3D_o2p_reduced_node_v.xml"
1590 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_3D_order2p.msh",optimize=False)
1591 x=ReducedSolution(dom).getX()
1592 saveVTK(FINLEY_WORKDIR_PATH+"hex_3D_order2p_ReducedSolution_Vector.xml",data=x[0]*[1.,2.,3.])
1593 self.check_vtk("hex_3D_order2p_ReducedSolution_Vector.xml",reference)
1594 def test_hex_3D_order2p_ReducedSolution_Tensor_vtk(self):
1595 reference="hex_3D_o2p_reduced_node_t.xml"
1596 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_3D_order2p.msh",optimize=False)
1597 x=ReducedSolution(dom).getX()
1598 saveVTK(FINLEY_WORKDIR_PATH+"hex_3D_order2p_ReducedSolution_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1599 self.check_vtk("hex_3D_order2p_ReducedSolution_Tensor.xml",reference)
1600 def test_hex_3D_order2p_Function_Scalar_vtk(self):
1601 reference="hex_3D_o2p_cell_s.xml"
1602 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_3D_order2p.msh",optimize=False)
1603 x=Function(dom).getX()
1604 saveVTK(FINLEY_WORKDIR_PATH+"hex_3D_order2p_Function_Scalar.xml",data=x[0])
1605 self.check_vtk("hex_3D_order2p_Function_Scalar.xml",reference)
1606 def test_hex_3D_order2p_Function_Vector_vtk(self):
1607 reference="hex_3D_o2p_cell_v.xml"
1608 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_3D_order2p.msh",optimize=False)
1609 x=Function(dom).getX()
1610 saveVTK(FINLEY_WORKDIR_PATH+"hex_3D_order2p_Function_Vector.xml",data=x[0]*[1.,2.,3.])
1611 self.check_vtk("hex_3D_order2p_Function_Vector.xml",reference)
1612 def test_hex_3D_order2p_Function_Tensor_vtk(self):
1613 reference="hex_3D_o2p_cell_t.xml"
1614 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_3D_order2p.msh",optimize=False)
1615 x=Function(dom).getX()
1616 saveVTK(FINLEY_WORKDIR_PATH+"hex_3D_order2p_Function_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1617 self.check_vtk("hex_3D_order2p_Function_Tensor.xml",reference)
1618 def test_hex_3D_order2p_ReducedFunction_Scalar_vtk(self):
1619 reference="hex_3D_o2p_cell_reduced_s.xml"
1620 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_3D_order2p.msh",optimize=False)
1621 x=ReducedFunction(dom).getX()
1622 saveVTK(FINLEY_WORKDIR_PATH+"hex_3D_order2p_ReducedFunction_Scalar.xml",data=x[0])
1623 self.check_vtk("hex_3D_order2p_ReducedFunction_Scalar.xml",reference)
1624 def test_hex_3D_order2p_ReducedFunction_Vector_vtk(self):
1625 reference="hex_3D_o2p_cell_reduced_v.xml"
1626 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_3D_order2p.msh",optimize=False)
1627 x=ReducedFunction(dom).getX()
1628 saveVTK(FINLEY_WORKDIR_PATH+"hex_3D_order2p_ReducedFunction_Vector.xml",data=x[0]*[1.,2.,3.])
1629 self.check_vtk("hex_3D_order2p_ReducedFunction_Vector.xml",reference)
1630 def test_hex_3D_order2p_ReducedFunction_Tensor_vtk(self):
1631 reference="hex_3D_o2p_cell_reduced_t.xml"
1632 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_3D_order2p.msh",optimize=False)
1633 x=ReducedFunction(dom).getX()
1634 saveVTK(FINLEY_WORKDIR_PATH+"hex_3D_order2p_ReducedFunction_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1635 self.check_vtk("hex_3D_order2p_ReducedFunction_Tensor.xml",reference)
1636 def test_hex_3D_order2p_FunctionOnBoundary_Scalar_vtk(self):
1637 reference="hex_3D_o2p_boundary_s.xml"
1638 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_3D_order2p.msh",optimize=False)
1639 x=FunctionOnBoundary(dom).getX()
1640 saveVTK(FINLEY_WORKDIR_PATH+"hex_3D_order2p_FunctionOnBoundary_Scalar.xml",data=x[0])
1641 self.check_vtk("hex_3D_order2p_FunctionOnBoundary_Scalar.xml",reference)
1642 def test_hex_3D_order2p_FunctionOnBoundary_Vector_vtk(self):
1643 reference="hex_3D_o2p_boundary_v.xml"
1644 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_3D_order2p.msh",optimize=False)
1645 x=FunctionOnBoundary(dom).getX()
1646 saveVTK(FINLEY_WORKDIR_PATH+"hex_3D_order2p_FunctionOnBoundary_Vector.xml",data=x[0]*[1.,2.,3.])
1647 self.check_vtk("hex_3D_order2p_FunctionOnBoundary_Vector.xml",reference)
1648 def test_hex_3D_order2p_FunctionOnBoundary_Tensor_vtk(self):
1649 reference="hex_3D_o2p_boundary_t.xml"
1650 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_3D_order2p.msh",optimize=False)
1651 x=FunctionOnBoundary(dom).getX()
1652 saveVTK(FINLEY_WORKDIR_PATH+"hex_3D_order2p_FunctionOnBoundary_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1653 self.check_vtk("hex_3D_order2p_FunctionOnBoundary_Tensor.xml",reference)
1654 def test_hex_3D_order2p_ReducedFunctionOnBoundary_Scalar_vtk(self):
1655 reference="hex_3D_o2p_boundary_reduced_s.xml"
1656 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_3D_order2p.msh",optimize=False)
1657 x=ReducedFunctionOnBoundary(dom).getX()
1658 saveVTK(FINLEY_WORKDIR_PATH+"hex_3D_order2p_ReducedFunctionOnBoundary_Scalar.xml",data=x[0])
1659 self.check_vtk("hex_3D_order2p_ReducedFunctionOnBoundary_Scalar.xml",reference)
1660 def test_hex_3D_order2p_ReducedFunctionOnBoundary_Vector_vtk(self):
1661 reference="hex_3D_o2p_boundary_reduced_v.xml"
1662 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_3D_order2p.msh",optimize=False)
1663 x=ReducedFunctionOnBoundary(dom).getX()
1664 saveVTK(FINLEY_WORKDIR_PATH+"hex_3D_order2p_ReducedFunctionOnBoundary_Vector.xml",data=x[0]*[1.,2.,3.])
1665 self.check_vtk("hex_3D_order2p_ReducedFunctionOnBoundary_Vector.xml",reference)
1666 def test_hex_3D_order2p_ReducedFunctionOnBoundary_Tensor_vtk(self):
1667 reference="hex_3D_o2p_boundary_reduced_t.xml"
1668 dom=ReadMesh(FINLEY_TEST_MESH_PATH+"hex_3D_order2p.msh",optimize=False)
1669 x=ReducedFunctionOnBoundary(dom).getX()
1670 saveVTK(FINLEY_WORKDIR_PATH+"hex_3D_order2p_ReducedFunctionOnBoundary_Tensor.xml",data=x[0]*[[11.,12.,13.],[21.,22.,23],[31.,32.,33.]])
1671 self.check_vtk("hex_3D_order2p_ReducedFunctionOnBoundary_Tensor.xml",reference)
1672 def test_tet_2D_order2_vtk(self):
1673 reference="tet_2D_o2.xml"
1674 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order2.fly"),optimize=False)
1675 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order2.xml"),domain=dom)
1676 self.check_vtk("tet_2D_order2.xml",reference)
1677
1678 def test_tet_2D_order2_AllPoints_Scalar_vtk(self):
1679 reference="tet_2D_o1_node_3xs.xml"
1680 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order2.fly"),optimize=False)
1681 x=Solution(dom).getX()
1682 x_r=ReducedSolution(dom).getX()
1683 x_n=ContinuousFunction(dom).getX()
1684 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order2_AllPoints_Scalar.xml"),data_r=x_r[0],data_n=x_n[0],data=x[0])
1685 self.check_vtk("tet_2D_order2_AllPoints_Scalar.xml",reference)
1686 def test_tet_2D_order2_02Points_Scalar_vtk(self):
1687 reference="tet_2D_o2_node_2xs.xml"
1688 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order2.fly"),optimize=False)
1689 x=Solution(dom).getX()
1690 x_n=ContinuousFunction(dom).getX()
1691 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order2_O2Points_Scalar.xml"),data_n=x_n[0],data=x[0])
1692 self.check_vtk("tet_2D_order2_O2Points_Scalar.xml",reference)
1693 def test_tet_2D_order2_2Cells_Scalar_vtk(self):
1694 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order2.fly"),optimize=False)
1695 x=Function(dom).getX()
1696 x_b=FunctionOnBoundary(dom).getX()
1697 try:
1698 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order2_2Cells_Scalar.xml"),data=x[0],data_b=x_b[0])
1699 self.fail("non-matching data not detected.")
1700 except StandardError:
1701 pass
1702 def test_tet_2D_order2_BoundaryPoint_Scalar_vtk(self):
1703 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order2.fly"),optimize=False)
1704 x=ContinuousFunction(dom).getX()
1705 x_b=FunctionOnBoundary(dom).getX()
1706 try:
1707 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order2_BoundaryPoint_Scalar.xml"),data=x[0],data_b=x_b[0])
1708 self.fail("non-matching data not detected.")
1709 except StandardError:
1710 pass
1711 def test_tet_2D_order2_Cells_AllData_vtk(self):
1712 reference="tet_2D_o2_cell_all.xml"
1713 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order2.fly"),optimize=False)
1714 x=Function(dom).getX()
1715 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order2_Cells_AllData.xml"),data_s=x[0],data_v=x[0]*[1.,2.],data_t=x[0]*[[11.,12.],[21.,22.]],data_t2=x[0]*[[-11.,-12.],[-21.,-22.]])
1716 self.check_vtk("tet_2D_order2_Cells_AllData.xml",reference)
1717
1718 def test_tet_2D_order2_CellsPoints_AllData_vtk(self):
1719 reference="tet_2D_o2_cellnode_all.xml"
1720 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order2.fly"),optimize=False)
1721 x_c=Function(dom).getX()
1722 x_p=ContinuousFunction(dom).getX()
1723 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order2_CellsPoints_AllData.xml"),data_sp=x_p[0],
1724 data_vp=x_p[0]*[1.,2.],
1725 data_tp=x_p[0]*[[11.,12.],[21.,22.]],
1726 data_sc=x_c[0],
1727 data_vc=x_c[0]*[1.,2.],
1728 data_tc=x_c[0]*[[11.,12.],[21.,22.]])
1729 self.check_vtk("tet_2D_order2_CellsPoints_AllData.xml",reference)
1730 # ======================================================================================================================
1731 def test_tet_2D_order1_ContinuousFunction_Scalar_vtk(self):
1732 reference="tet_2D_o1_node_s.xml"
1733 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order1.fly"),optimize=False)
1734 x=ContinuousFunction(dom).getX()
1735 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order1_ContinuousFunction_Scalar.xml"),data=x[0])
1736 self.check_vtk("tet_2D_order1_ContinuousFunction_Scalar.xml",reference)
1737 def test_tet_2D_order1_ContinuousFunction_Vector_vtk(self):
1738 reference="tet_2D_o1_node_v.xml"
1739 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order1.fly"),optimize=False)
1740 x=ContinuousFunction(dom).getX()
1741 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order1_ContinuousFunction_Vector.xml"),data=x[0]*[1.,2.])
1742 self.check_vtk("tet_2D_order1_ContinuousFunction_Vector.xml",reference)
1743 def test_tet_2D_order1_ContinuousFunction_Tensor_vtk(self):
1744 reference="tet_2D_o1_node_t.xml"
1745 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order1.fly"),optimize=False)
1746 x=ContinuousFunction(dom).getX()
1747 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order1_ContinuousFunction_Tensor.xml"),data=x[0]*[[11.,12.],[21.,22.]])
1748 self.check_vtk("tet_2D_order1_ContinuousFunction_Tensor.xml",reference)
1749 def test_tet_2D_order1_Solution_Scalar_vtk(self):
1750 reference="tet_2D_o1_node_s.xml"
1751 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order1.fly"),optimize=False)
1752 x=Solution(dom).getX()
1753 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order1_Solution_Scalar.xml"),data=x[0])
1754 self.check_vtk("tet_2D_order1_Solution_Scalar.xml",reference)
1755 def test_tet_2D_order1_Solution_Vector_vtk(self):
1756 reference="tet_2D_o1_node_v.xml"
1757 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order1.fly"),optimize=False)
1758 x=Solution(dom).getX()
1759 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order1_Solution_Vector.xml"),data=x[0]*[1.,2.])
1760 self.check_vtk("tet_2D_order1_Solution_Vector.xml",reference)
1761 def test_tet_2D_order1_Solution_Tensor_vtk(self):
1762 reference="tet_2D_o1_node_t.xml"
1763 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order1.fly"),optimize=False)
1764 x=Solution(dom).getX()
1765 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order1_Solution_Tensor.xml"),data=x[0]*[[11.,12.],[21.,22.]])
1766 self.check_vtk("tet_2D_order1_Solution_Tensor.xml",reference)
1767 def test_tet_2D_order1_ReducedSolution_Scalar_vtk(self):
1768 reference="tet_2D_o1_node_s.xml"
1769 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order1.fly"),optimize=False)
1770 x=ReducedSolution(dom).getX()
1771 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order1_ReducedSolution_Scalar.xml"),data=x[0])
1772 self.check_vtk("tet_2D_order1_ReducedSolution_Scalar.xml",reference)
1773 def test_tet_2D_order1_ReducedSolution_Vector_vtk(self):
1774 reference="tet_2D_o1_node_v.xml"
1775 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order1.fly"),optimize=False)
1776 x=ReducedSolution(dom).getX()
1777 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order1_ReducedSolution_Vector.xml"),data=x[0]*[1.,2.])
1778 self.check_vtk("tet_2D_order1_ReducedSolution_Vector.xml",reference)
1779 def test_tet_2D_order1_ReducedSolution_Tensor_vtk(self):
1780 reference="tet_2D_o1_node_t.xml"
1781 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order1.fly"),optimize=False)
1782 x=ReducedSolution(dom).getX()
1783 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order1_ReducedSolution_Tensor.xml"),data=x[0]*[[11.,12.],[21.,22.]])
1784 self.check_vtk("tet_2D_order1_ReducedSolution_Tensor.xml",reference)
1785 def test_tet_2D_order1_Function_Scalar_vtk(self):
1786 reference="tet_2D_o1_cell_s.xml"
1787 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order1.fly"),optimize=False)
1788 x=Function(dom).getX()
1789 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order1_Function_Scalar.xml"),data=x[0])
1790 self.check_vtk("tet_2D_order1_Function_Scalar.xml",reference)
1791 def test_tet_2D_order1_Function_Vector_vtk(self):
1792 reference="tet_2D_o1_cell_v.xml"
1793 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order1.fly"),optimize=False)
1794 x=Function(dom).getX()
1795 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order1_Function_Vector.xml"),data=x[0]*[1.,2.])
1796 self.check_vtk("tet_2D_order1_Function_Vector.xml",reference)
1797 def test_tet_2D_order1_Function_Tensor_vtk(self):
1798 reference="tet_2D_o1_cell_t.xml"
1799 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order1.fly"),optimize=False)
1800 x=Function(dom).getX()
1801 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order1_Function_Tensor.xml"),data=x[0]*[[11.,12.],[21.,22.]])
1802 self.check_vtk("tet_2D_order1_Function_Tensor.xml",reference)
1803 def test_tet_2D_order1_ReducedFunction_Scalar_vtk(self):
1804 reference="tet_2D_o1_cell_s.xml"
1805 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order1.fly"),optimize=False)
1806 x=ReducedFunction(dom).getX()
1807 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order1_ReducedFunction_Scalar.xml"),data=x[0])
1808 self.check_vtk("tet_2D_order1_ReducedFunction_Scalar.xml",reference)
1809 def test_tet_2D_order1_ReducedFunction_Vector_vtk(self):
1810 reference="tet_2D_o1_cell_v.xml"
1811 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order1.fly"),optimize=False)
1812 x=ReducedFunction(dom).getX()
1813 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order1_ReducedFunction_Vector.xml"),data=x[0]*[1.,2.])
1814 self.check_vtk("tet_2D_order1_ReducedFunction_Vector.xml",reference)
1815 def test_tet_2D_order1_ReducedFunction_Tensor_vtk(self):
1816 reference="tet_2D_o1_cell_t.xml"
1817 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order1.fly"),optimize=False)
1818 x=ReducedFunction(dom).getX()
1819 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order1_ReducedFunction_Tensor.xml"),data=x[0]*[[11.,12.],[21.,22.]])
1820 self.check_vtk("tet_2D_order1_ReducedFunction_Tensor.xml",reference)
1821 def test_tet_2D_order1_FunctionOnBoundary_Scalar_vtk(self):
1822 reference="tet_2D_o1_boundary_s.xml"
1823 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order1.fly"),optimize=False)
1824 x=FunctionOnBoundary(dom).getX()
1825 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order1_FunctionOnBoundary_Scalar.xml"),data=x[0])
1826 self.check_vtk("tet_2D_order1_FunctionOnBoundary_Scalar.xml",reference)
1827 def test_tet_2D_order1_FunctionOnBoundary_Vector_vtk(self):
1828 reference="tet_2D_o1_boundary_v.xml"
1829 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order1.fly"),optimize=False)
1830 x=FunctionOnBoundary(dom).getX()
1831 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order1_FunctionOnBoundary_Vector.xml"),data=x[0]*[1.,2.])
1832 self.check_vtk("tet_2D_order1_FunctionOnBoundary_Vector.xml",reference)
1833 def test_tet_2D_order1_FunctionOnBoundary_Tensor_vtk(self):
1834 reference="tet_2D_o1_boundary_t.xml"
1835 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order1.fly"),optimize=False)
1836 x=FunctionOnBoundary(dom).getX()
1837 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order1_FunctionOnBoundary_Tensor.xml"),data=x[0]*[[11.,12.],[21.,22.]])
1838 self.check_vtk("tet_2D_order1_FunctionOnBoundary_Tensor.xml",reference)
1839 def test_tet_2D_order1_ReducedFunctionOnBoundary_Scalar_vtk(self):
1840 reference="tet_2D_o1_boundary_s.xml"
1841 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order1.fly"),optimize=False)
1842 x=ReducedFunctionOnBoundary(dom).getX()
1843 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order1_ReducedFunctionOnBoundary_Scalar.xml"),data=x[0])
1844 self.check_vtk("tet_2D_order1_ReducedFunctionOnBoundary_Scalar.xml",reference)
1845 def test_tet_2D_order1_ReducedFunctionOnBoundary_Vector_vtk(self):
1846 reference="tet_2D_o1_boundary_v.xml"
1847 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order1.fly"),optimize=False)
1848 x=ReducedFunctionOnBoundary(dom).getX()
1849 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order1_ReducedFunctionOnBoundary_Vector.xml"),data=x[0]*[1.,2.])
1850 self.check_vtk("tet_2D_order1_ReducedFunctionOnBoundary_Vector.xml",reference)
1851 def test_tet_2D_order1_ReducedFunctionOnBoundary_Tensor_vtk(self):
1852 reference="tet_2D_o1_boundary_t.xml"
1853 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order1.fly"),optimize=False)
1854 x=ReducedFunctionOnBoundary(dom).getX()
1855 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order1_ReducedFunctionOnBoundary_Tensor.xml"),data=x[0]*[[11.,12.],[21.,22.]])
1856 self.check_vtk("tet_2D_order1_ReducedFunctionOnBoundary_Tensor.xml",reference)
1857 # ======================================================================================================================
1858 def test_tet_2D_order2_ContinuousFunction_Scalar_vtk(self):
1859 reference="tet_2D_o2_node_s.xml"
1860 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order2.fly"),optimize=False)
1861 x=ContinuousFunction(dom).getX()
1862 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order2_ContinuousFunction_Scalar.xml"),data=x[0])
1863 self.check_vtk("tet_2D_order2_ContinuousFunction_Scalar.xml",reference)
1864 def test_tet_2D_order2_ContinuousFunction_Vector_vtk(self):
1865 reference="tet_2D_o2_node_v.xml"
1866 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order2.fly"),optimize=False)
1867 x=ContinuousFunction(dom).getX()
1868 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order2_ContinuousFunction_Vector.xml"),data=x[0]*[1.,2.])
1869 self.check_vtk("tet_2D_order2_ContinuousFunction_Vector.xml",reference)
1870 def test_tet_2D_order2_ContinuousFunction_Tensor_vtk(self):
1871 reference="tet_2D_o2_node_t.xml"
1872 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order2.fly"),optimize=False)
1873 x=ContinuousFunction(dom).getX()
1874 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order2_ContinuousFunction_Tensor.xml"),data=x[0]*[[11.,12.],[21.,22.]])
1875 self.check_vtk("tet_2D_order2_ContinuousFunction_Tensor.xml",reference)
1876 def test_tet_2D_order2_Solution_Scalar_vtk(self):
1877 reference="tet_2D_o2_node_s.xml"
1878 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order2.fly"),optimize=False)
1879 x=Solution(dom).getX()
1880 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order2_Solution_Scalar.xml"),data=x[0])
1881 self.check_vtk("tet_2D_order2_Solution_Scalar.xml",reference)
1882 def test_tet_2D_order2_Solution_Vector_vtk(self):
1883 reference="tet_2D_o2_node_v.xml"
1884 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order2.fly"),optimize=False)
1885 x=Solution(dom).getX()
1886 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order2_Solution_Vector.xml"),data=x[0]*[1.,2.])
1887 self.check_vtk("tet_2D_order2_Solution_Vector.xml",reference)
1888 def test_tet_2D_order2_Solution_Tensor_vtk(self):
1889 reference="tet_2D_o2_node_t.xml"
1890 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order2.fly"),optimize=False)
1891 x=Solution(dom).getX()
1892 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order2_Solution_Tensor.xml"),data=x[0]*[[11.,12.],[21.,22.]])
1893 self.check_vtk("tet_2D_order2_Solution_Tensor.xml",reference)
1894 def test_tet_2D_order2_ReducedSolution_Scalar_vtk(self):
1895 reference="tet_2D_o1_node_s.xml"
1896 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order2.fly"),optimize=False)
1897 x=ReducedSolution(dom).getX()
1898 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order2_ReducedSolution_Scalar.xml"),data=x[0])
1899 self.check_vtk("tet_2D_order2_ReducedSolution_Scalar.xml",reference)
1900 def test_tet_2D_order2_ReducedSolution_Vector_vtk(self):
1901 reference="tet_2D_o1_node_v.xml"
1902 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order2.fly"),optimize=False)
1903 x=ReducedSolution(dom).getX()
1904 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order2_ReducedSolution_Vector.xml"),data=x[0]*[1.,2.])
1905 self.check_vtk("tet_2D_order2_ReducedSolution_Vector.xml",reference)
1906 def test_tet_2D_order2_ReducedSolution_Tensor_vtk(self):
1907 reference="tet_2D_o1_node_t.xml"
1908 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order2.fly"),optimize=False)
1909 x=ReducedSolution(dom).getX()
1910 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order2_ReducedSolution_Tensor.xml"),data=x[0]*[[11.,12.],[21.,22.]])
1911 self.check_vtk("tet_2D_order2_ReducedSolution_Tensor.xml",reference)
1912 def test_tet_2D_order2_Function_Scalar_vtk(self):
1913 reference="tet_2D_o2_cell_s.xml"
1914 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order2.fly"),optimize=False)
1915 x=Function(dom).getX()
1916 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order2_Function_Scalar.xml"),data=x[0])
1917 self.check_vtk("tet_2D_order2_Function_Scalar.xml",reference)
1918 def test_tet_2D_order2_Function_Vector_vtk(self):
1919 reference="tet_2D_o2_cell_v.xml"
1920 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order2.fly"),optimize=False)
1921 x=Function(dom).getX()
1922 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order2_Function_Vector.xml"),data=x[0]*[1.,2.])
1923 self.check_vtk("tet_2D_order2_Function_Vector.xml",reference)
1924 def test_tet_2D_order2_Function_Tensor_vtk(self):
1925 reference="tet_2D_o2_cell_t.xml"
1926 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order2.fly"),optimize=False)
1927 x=Function(dom).getX()
1928 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order2_Function_Tensor.xml"),data=x[0]*[[11.,12.],[21.,22.]])
1929 self.check_vtk("tet_2D_order2_Function_Tensor.xml",reference)
1930 def test_tet_2D_order2_ReducedFunction_Scalar_vtk(self):
1931 reference="tet_2D_o2_reduced_cell_s.xml"
1932 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order2.fly"),optimize=False)
1933 x=ReducedFunction(dom).getX()
1934 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order2_ReducedFunction_Scalar.xml"),data=x[0])
1935 self.check_vtk("tet_2D_order2_ReducedFunction_Scalar.xml",reference)
1936 def test_tet_2D_order2_ReducedFunction_Vector_vtk(self):
1937 reference="tet_2D_o2_reduced_cell_v.xml"
1938 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order2.fly"),optimize=False)
1939 x=ReducedFunction(dom).getX()
1940 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order2_ReducedFunction_Vector.xml"),data=x[0]*[1.,2.])
1941 self.check_vtk("tet_2D_order2_ReducedFunction_Vector.xml",reference)
1942 def test_tet_2D_order2_ReducedFunction_Tensor_vtk(self):
1943 reference="tet_2D_o2_reduced_cell_t.xml"
1944 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order2.fly"),optimize=False)
1945 x=ReducedFunction(dom).getX()
1946 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order2_ReducedFunction_Tensor.xml"),data=x[0]*[[11.,12.],[21.,22.]])
1947 self.check_vtk("tet_2D_order2_ReducedFunction_Tensor.xml",reference)
1948 def test_tet_2D_order2_FunctionOnBoundary_Scalar_vtk(self):
1949 reference="tet_2D_o2_boundary_s.xml"
1950 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order2.fly"),optimize=False)
1951 x=FunctionOnBoundary(dom).getX()
1952 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order2_FunctionOnBoundary_Scalar.xml"),data=x[0])
1953 self.check_vtk("tet_2D_order2_FunctionOnBoundary_Scalar.xml",reference)
1954 def test_tet_2D_order2_FunctionOnBoundary_Vector_vtk(self):
1955 reference="tet_2D_o2_boundary_v.xml"
1956 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order2.fly"),optimize=False)
1957 x=FunctionOnBoundary(dom).getX()
1958 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order2_FunctionOnBoundary_Vector.xml"),data=x[0]*[1.,2.])
1959 self.check_vtk("tet_2D_order2_FunctionOnBoundary_Vector.xml",reference)
1960 def test_tet_2D_order2_FunctionOnBoundary_Tensor_vtk(self):
1961 reference="tet_2D_o2_boundary_t.xml"
1962 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order2.fly"),optimize=False)
1963 x=FunctionOnBoundary(dom).getX()
1964 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order2_FunctionOnBoundary_Tensor.xml"),data=x[0]*[[11.,12.],[21.,22.]])
1965 self.check_vtk("tet_2D_order2_FunctionOnBoundary_Tensor.xml",reference)
1966 def test_tet_2D_order2_ReducedFunctionOnBoundary_Scalar_vtk(self):
1967 reference="tet_2D_o2_boundary_s.xml"
1968 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order2.fly"),optimize=False)
1969 x=ReducedFunctionOnBoundary(dom).getX()
1970 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order2_ReducedFunctionOnBoundary_Scalar.xml"),data=x[0])
1971 self.check_vtk("tet_2D_order2_ReducedFunctionOnBoundary_Scalar.xml",reference)
1972 def test_tet_2D_order2_ReducedFunctionOnBoundary_Vector_vtk(self):
1973 reference="tet_2D_o2_boundary_v.xml"
1974 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order2.fly"),optimize=False)
1975 x=ReducedFunctionOnBoundary(dom).getX()
1976 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order2_ReducedFunctionOnBoundary_Vector.xml"),data=x[0]*[1.,2.])
1977 self.check_vtk("tet_2D_order2_ReducedFunctionOnBoundary_Vector.xml",reference)
1978 def test_tet_2D_order2_ReducedFunctionOnBoundary_Tensor_vtk(self):
1979 reference="tet_2D_o2_boundary_t.xml"
1980 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_2D_order2.fly"),optimize=False)
1981 x=ReducedFunctionOnBoundary(dom).getX()
1982 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_2D_order2_ReducedFunctionOnBoundary_Tensor.xml"),data=x[0]*[[11.,12.],[21.,22.]])
1983 self.check_vtk("tet_2D_order2_ReducedFunctionOnBoundary_Tensor.xml",reference)
1984 # ======================================================================================================================
1985 def test_tet_3D_order1_ContinuousFunction_Scalar_vtk(self):
1986 reference="tet_3D_o1_node_s.xml"
1987 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_3D_order1.fly"),optimize=False)
1988 x=ContinuousFunction(dom).getX()
1989 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_3D_order1_ContinuousFunction_Scalar.xml"),data=x[0])
1990 self.check_vtk("tet_3D_order1_ContinuousFunction_Scalar.xml",reference)
1991 def test_tet_3D_order1_ContinuousFunction_Vector_vtk(self):
1992 reference="tet_3D_o1_node_v.xml"
1993 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_3D_order1.fly"),optimize=False)
1994 x=ContinuousFunction(dom).getX()
1995 saveVTK(os.path.join(FINLEY_WORKDIR_PATH,"tet_3D_order1_ContinuousFunction_Vector.xml"),data=x[0]*[1.,2.,3.])
1996 self.check_vtk("tet_3D_order1_ContinuousFunction_Vector.xml",reference)
1997 def test_tet_3D_order1_ContinuousFunction_Tensor_vtk(self):
1998 reference="tet_3D_o1_node_t.xml"
1999 dom=ReadMesh(os.path.join(FINLEY_TEST_MESH_PATH,"tet_3D_order1.fly"),optimize=False)