Primarily: fixed the gmsh module to use integer indices
also did some pep8/pyflakes cleanup
This commit is contained in:
+6
-3
@@ -45,8 +45,9 @@ def baker_exact_3D(X):
|
||||
np.sin(z * np.pi / 2.0)), 2)
|
||||
return answer
|
||||
|
||||
def exact_me(X, f):
|
||||
a = np.array([f(i) for i in X])
|
||||
|
||||
def exact_me(points, f):
|
||||
a = np.array([f(i) for i in points])
|
||||
return a
|
||||
|
||||
|
||||
@@ -71,10 +72,12 @@ def improved_answer(answer, exact):
|
||||
else:
|
||||
return False
|
||||
|
||||
def identical_points(a,b):
|
||||
|
||||
def identical_points(a, b):
|
||||
return all(set(j[i] for j in a) \
|
||||
== set(j[i] for j in b) for i in xrange(len(a[0])))
|
||||
|
||||
|
||||
def improved(qlin, err, final, exact):
|
||||
if np.abs(final - exact) <= np.abs(qlin - exact):
|
||||
return True
|
||||
|
||||
Reference in New Issue
Block a user