SyFi
0.3
|
Inherits TestCase.
Public Member Functions | |
def | test_reference_line_dimensions |
def | test_reference_triangle_dimensions |
def | test_reference_rectangle_dimensions |
def | test_reference_tetrahedron_dimensions |
def | test_reference_box_dimensions |
def | test_spacetime_dimensions |
Private Member Functions | |
def | _validate_vertex |
def | _validate_line |
def | _validate_triangle |
def | _validate_tetrahedron |
def | _validate_rectangle |
def | _validate_box |
Definition at line 10 of file test_geometry.py.
def test_syfi.test_geometry.TestGeometry._validate_box | ( | self, | |
cell, | |||
dim | |||
) | [private] |
Definition at line 59 of file test_geometry.py.
References test_syfi.test_geometry.TestGeometry._validate_line(), test_syfi.test_geometry.TestGeometry._validate_rectangle(), and test_syfi.test_geometry.TestGeometry._validate_vertex().
Referenced by test_syfi.test_geometry.TestGeometry.test_reference_box_dimensions().
00059 00060 def _validate_box(self, cell, dim): 00061 self.assertEqual(cell.no_space_dim(), 3) 00062 #self.assertEqual(cell.no_space_dim(), dim) 00063 00064 self.assertEqual(cell.no_vertices(), 8) 00065 for i in range(6): 00066 self._validate_vertex(cell.vertex(i), dim) 00067 for i in range(12): 00068 self._validate_line(cell.line(i), dim) 00069 for i in range(6): 00070 self._validate_rectangle(cell.rectangle(i), dim)
def test_syfi.test_geometry.TestGeometry._validate_line | ( | self, | |
cell, | |||
dim | |||
) | [private] |
Definition at line 19 of file test_geometry.py.
References test_syfi.test_geometry.TestGeometry._validate_vertex().
Referenced by test_syfi.test_geometry.TestGeometry._validate_box(), test_syfi.test_geometry.TestGeometry._validate_rectangle(), test_syfi.test_geometry.TestGeometry._validate_tetrahedron(), test_syfi.test_geometry.TestGeometry._validate_triangle(), and test_syfi.test_geometry.TestGeometry.test_reference_line_dimensions().
00019 00020 def _validate_line(self, cell, dim): 00021 self.assertEqual(cell.no_space_dim(), 1) 00022 #self.assertEqual(cell.no_space_dim(), dim) 00023 00024 self.assertEqual(cell.no_vertices(), 2) 00025 for i in range(2): 00026 self._validate_vertex(cell.vertex(i), dim)
def test_syfi.test_geometry.TestGeometry._validate_rectangle | ( | self, | |
cell, | |||
dim | |||
) | [private] |
Definition at line 49 of file test_geometry.py.
References test_syfi.test_geometry.TestGeometry._validate_line(), and test_syfi.test_geometry.TestGeometry._validate_vertex().
Referenced by test_syfi.test_geometry.TestGeometry._validate_box(), and test_syfi.test_geometry.TestGeometry.test_reference_rectangle_dimensions().
00049 00050 def _validate_rectangle(self, cell, dim): 00051 self.assertEqual(cell.no_space_dim(), 2) 00052 #self.assertEqual(cell.no_space_dim(), dim) 00053 00054 self.assertEqual(cell.no_vertices(), 4) 00055 for i in range(4): 00056 self._validate_vertex(cell.vertex(i), dim) 00057 for i in range(4): 00058 self._validate_line(cell.line(i), dim)
def test_syfi.test_geometry.TestGeometry._validate_tetrahedron | ( | self, | |
cell, | |||
dim | |||
) | [private] |
Definition at line 37 of file test_geometry.py.
References test_syfi.test_geometry.TestGeometry._validate_line(), test_syfi.test_geometry.TestGeometry._validate_triangle(), and test_syfi.test_geometry.TestGeometry._validate_vertex().
Referenced by test_syfi.test_geometry.TestGeometry.test_reference_tetrahedron_dimensions().
00037 00038 def _validate_tetrahedron(self, cell, dim): 00039 self.assertEqual(cell.no_space_dim(), 3) 00040 #self.assertEqual(cell.no_space_dim(), dim) 00041 00042 self.assertEqual(cell.no_vertices(), 4) 00043 for i in range(4): 00044 self._validate_vertex(cell.vertex(i), dim) 00045 for i in range(6): 00046 self._validate_line(cell.line(i), dim) 00047 for i in range(4): 00048 self._validate_triangle(cell.triangle(i), dim)
def test_syfi.test_geometry.TestGeometry._validate_triangle | ( | self, | |
cell, | |||
dim | |||
) | [private] |
Definition at line 27 of file test_geometry.py.
References test_syfi.test_geometry.TestGeometry._validate_line(), and test_syfi.test_geometry.TestGeometry._validate_vertex().
Referenced by test_syfi.test_geometry.TestGeometry._validate_tetrahedron(), and test_syfi.test_geometry.TestGeometry.test_reference_triangle_dimensions().
00027 00028 def _validate_triangle(self, cell, dim): 00029 self.assertEqual(cell.no_space_dim(), 2) 00030 #self.assertEqual(cell.no_space_dim(), dim) 00031 00032 self.assertEqual(cell.no_vertices(), 3) 00033 for i in range(3): 00034 self._validate_vertex(cell.vertex(i), dim) 00035 for i in range(3): 00036 self._validate_line(cell.line(i), dim)
def test_syfi.test_geometry.TestGeometry._validate_vertex | ( | self, | |
v, | |||
dim | |||
) | [private] |
Definition at line 12 of file test_geometry.py.
Referenced by test_syfi.test_geometry.TestGeometry._validate_box(), test_syfi.test_geometry.TestGeometry._validate_line(), test_syfi.test_geometry.TestGeometry._validate_rectangle(), test_syfi.test_geometry.TestGeometry._validate_tetrahedron(), and test_syfi.test_geometry.TestGeometry._validate_triangle().
00012 00013 def _validate_vertex(self, v, dim): 00014 if len(v) != dim: 00015 print 00016 print v 00017 print 00018 self.assertEqual(len(v), dim)
Definition at line 95 of file test_geometry.py.
References test_syfi.test_geometry.TestGeometry._validate_box().
00095 00096 def test_reference_box_dimensions(self): 00097 d = 3 00098 SyFi.initSyFi(d) 00099 c = SyFi.ReferenceBox() 00100 self._validate_box(c, d)
Definition at line 71 of file test_geometry.py.
References test_syfi.test_geometry.TestGeometry._validate_line().
00071 00072 def test_reference_line_dimensions(self): 00073 d = 1 00074 SyFi.initSyFi(d) 00075 c = SyFi.ReferenceLine() 00076 self._validate_line(c, d)
Definition at line 83 of file test_geometry.py.
References test_syfi.test_geometry.TestGeometry._validate_rectangle().
00083 00084 def test_reference_rectangle_dimensions(self): 00085 d = 2 00086 SyFi.initSyFi(d) 00087 c = SyFi.ReferenceRectangle() 00088 self._validate_rectangle(c, d)
Definition at line 89 of file test_geometry.py.
References test_syfi.test_geometry.TestGeometry._validate_tetrahedron().
00089 00090 def test_reference_tetrahedron_dimensions(self): 00091 d = 3 00092 SyFi.initSyFi(d) 00093 c = SyFi.ReferenceTetrahedron() 00094 self._validate_tetrahedron(c, d)
Definition at line 77 of file test_geometry.py.
References test_syfi.test_geometry.TestGeometry._validate_triangle().
00077 00078 def test_reference_triangle_dimensions(self): 00079 d = 2 00080 SyFi.initSyFi(d) 00081 c = SyFi.ReferenceTriangle() 00082 self._validate_triangle(c, d)
Definition at line 101 of file test_geometry.py.
00101 00102 def test_spacetime_dimensions(self): 00103 l = SyFi.ReferenceLine() 00104 t = SyFi.ReferenceTriangle() 00105 sd = SyFi.SpaceTimeDomain(l, t) 00106 #self.assertEqual(TODO)