diff --git a/FIAT/expansions.py b/FIAT/expansions.py index 12c48be04..79a877b5f 100644 --- a/FIAT/expansions.py +++ b/FIAT/expansions.py @@ -77,7 +77,7 @@ def dubiner_recurrence(dim, n, order, ref_pts, jacobian, variant=None): pad_dim = dim + 2 dX = pad_jacobian(jacobian, pad_dim) - phi[0] = sum((ref_pts[i] - ref_pts[i] for i in range(dim)), 1.) + phi[0] = sum((ref_pts[i] - ref_pts[i] for i in range(dim)), math.sqrt(0.5)**dim) if dphi is not None: dphi[0] = (phi[0] - phi[0]) * dX[0] if ddphi is not None: @@ -138,7 +138,7 @@ def dubiner_recurrence(dim, n, order, ref_pts, jacobian, variant=None): n1 = sum(index) - 1 alpha = 3*n1*(n1*alpha + len(index)) / (n1+1)**2 - scale = math.sqrt(0.5 * alpha) + scale = math.sqrt(alpha) icur = idx(*index) for result in results: result[icur] *= scale diff --git a/test/unit/test_fiat.py b/test/unit/test_fiat.py index 2d17cfe97..87b920c6f 100644 --- a/test/unit/test_fiat.py +++ b/test/unit/test_fiat.py @@ -602,7 +602,6 @@ def eval_basis(f, pt): @pytest.mark.parametrize('cell', [I, T, S]) def test_make_bubbles(cell): - from FIAT.reference_element import make_lattice from FIAT.quadrature_schemes import create_quadrature from FIAT.expansions import polynomial_dimension from FIAT.polynomial_set import make_bubbles, PolynomialSet, ONPolynomialSet @@ -627,7 +626,7 @@ def test_make_bubbles(cell): # test linear independence m = B.get_num_members() - points = make_lattice(cell.get_vertices(), degree, interior=1) + points = cell.make_points(sd, 0, degree + 1) values = B.tabulate(points)[(0,) * sd] assert values.shape == (m, m) assert np.linalg.matrix_rank(values.T) == m