← Back to team overview

ffc team mailing list archive

Re: [Branch ~ffc-core/ffc/main] Rev 1503: Added support for Circumradius from UFL.

 

It is now possible to do:

h = triangle.circumradius (or h = Circumradius(triangle))
h_avg = (h('+') + h('-'))/2.0

Note that in order to get matching results in the
dolfin/demo/pde/dg/poission demo the radius should be multiplied with
2.

h = triangle.circumradius*2.0
h_avg = (h('+') + h('-'))/2.0

Kristian

On 8 July 2010 15:27,  <noreply@xxxxxxxxxxxxx> wrote:
> ------------------------------------------------------------
> revno: 1503
> committer: Kristian B. Ølgaard <k.b.oelgaard@xxxxxxxxx>
> branch nick: ffc
> timestamp: Thu 2010-07-08 15:24:27 +0100
> message:
>  Added support for Circumradius from UFL.
> modified:
>  ChangeLog
>  ffc/codesnippets.py
>  ffc/cpp.py
>  ffc/quadrature/optimisedquadraturetransformer.py
>  ffc/quadrature/quadraturegenerator.py
>  ffc/quadrature/quadraturetransformer.py
>  ffc/quadrature/quadraturetransformerbase.py
>  test/regression/references/AlgebraOperators.h
>  test/regression/references/Biharmonic.h
>  test/regression/references/CoefficientOperators.h
>  test/regression/references/EnergyNorm.h
>  test/regression/references/Heat.h
>  test/regression/references/HyperElasticity.h
>  test/regression/references/MathFunctions.h
>  test/regression/references/MetaData.h
>  test/regression/references/Normals.h
>  test/regression/references/PoissonDG.h
>  test/regression/references/QuadratureElement.h
>  test/regression/references/SpatialCoordinates.h
>  test/regression/references/StabilisedStokes.h
>  test/regression/references/TensorWeightedPoisson.h
>  test/regression/references/VectorLaplaceGradCurl.h
>
>
> --
> lp:ffc
> https://code.launchpad.net/~ffc-core/ffc/main
>
> Your team FFC Core Team is subscribed to branch lp:ffc.
> To unsubscribe from this branch go to https://code.launchpad.net/~ffc-core/ffc/main/+edit-subscription
>
> === modified file 'ChangeLog'
> --- ChangeLog   2010-07-07 17:17:07 +0000
> +++ ChangeLog   2010-07-08 14:24:27 +0000
> @@ -1,3 +1,4 @@
> + - Added support for new geometric quantity Circumradius in UFL.
>  - Added support for new geometric quantity CellVolume in UFL.
>  0.9.3 [2010-07-01]
>  - Make global_dimension for Real return an int instead of double, bug # 592088
>
> === modified file 'ffc/codesnippets.py'
> --- ffc/codesnippets.py 2010-07-08 10:40:10 +0000
> +++ ffc/codesnippets.py 2010-07-08 14:24:27 +0000
> @@ -19,7 +19,7 @@
>            "fiat_coordinate_map", "transform_snippet",
>            "scale_factor", "combinations_snippet",
>            "normal_direction",
> -           "facet_normal", "ip_coordinates", "cell_volume"]
> +           "facet_normal", "ip_coordinates", "cell_volume", "circumradius"]
>
>  comment_ufc = """\
>  // This code conforms with the UFC specification version %(ufc_version)s
> @@ -224,6 +224,34 @@
>  // Cell Volume.
>  const double volume%(restriction)s = std::abs(detJ%(restriction)s)/6.0;"""
>
> +_circumradius_1D = """\
> +// Compute circumradius, in 1D it is equal to the cell volume.
> +const double circumradius%(restriction)s = std::abs(detJ%(restriction)s);"""
> +
> +_circumradius_2D = """\
> +// Compute circumradius, assuming triangle is embedded in 2D.
> +const double v1v2%(restriction)s  = std::sqrt( (x%(restriction)s[2][0] - x%(restriction)s[1][0])*(x%(restriction)s[2][0] - x%(restriction)s[1][0]) + (x%(restriction)s[2][1] - x%(restriction)s[1][1])*(x%(restriction)s[2][1] - x%(restriction)s[1][1]) );
> +const double v0v2%(restriction)s  = std::sqrt( J%(restriction)s_11*J%(restriction)s_11 + J%(restriction)s_01*J%(restriction)s_01 );
> +const double v0v1%(restriction)s  = std::sqrt( J%(restriction)s_00*J%(restriction)s_00 + J%(restriction)s_10*J%(restriction)s_10 );
> +
> +const double circumradius%(restriction)s = 0.25*(v1v2%(restriction)s*v0v2%(restriction)s*v0v1%(restriction)s)/(volume%(restriction)s);"""
> +
> +_circumradius_3D = """\
> +// Compute circumradius.
> +const double v1v2%(restriction)s  = std::sqrt( (x%(restriction)s[2][0] - x%(restriction)s[1][0])*(x%(restriction)s[2][0] - x%(restriction)s[1][0]) + (x%(restriction)s[2][1] - x%(restriction)s[1][1])*(x%(restriction)s[2][1] - x%(restriction)s[1][1]) + (x%(restriction)s[2][2] - x%(restriction)s[1][2])*(x%(restriction)s[2][2] - x%(restriction)s[1][2]) );
> +const double v0v2%(restriction)s  = std::sqrt(J%(restriction)s_01*J%(restriction)s_01 + J%(restriction)s_11*J%(restriction)s_11 + J%(restriction)s_21*J%(restriction)s_21);
> +const double v0v1%(restriction)s  = std::sqrt(J%(restriction)s_00*J%(restriction)s_00 + J%(restriction)s_10*J%(restriction)s_10 + J%(restriction)s_20*J%(restriction)s_20);
> +const double v0v3%(restriction)s  = std::sqrt(J%(restriction)s_02*J%(restriction)s_02 + J%(restriction)s_12*J%(restriction)s_12 + J%(restriction)s_22*J%(restriction)s_22);
> +const double v1v3%(restriction)s  = std::sqrt( (x%(restriction)s[3][0] - x%(restriction)s[1][0])*(x%(restriction)s[3][0] - x%(restriction)s[1][0]) + (x%(restriction)s[3][1] - x%(restriction)s[1][1])*(x%(restriction)s[3][1] - x%(restriction)s[1][1]) + (x%(restriction)s[3][2] - x%(restriction)s[1][2])*(x%(restriction)s[3][2] - x%(restriction)s[1][2]) );
> +const double v2v3%(restriction)s  = std::sqrt( (x%(restriction)s[3][0] - x%(restriction)s[2][0])*(x%(restriction)s[3][0] - x%(restriction)s[2][0]) + (x%(restriction)s[3][1] - x%(restriction)s[2][1])*(x%(restriction)s[3][1] - x%(restriction)s[2][1]) + (x%(restriction)s[3][2] - x%(restriction)s[2][2])*(x%(restriction)s[3][2] - x%(restriction)s[2][2]) );
> +const  double la%(restriction)s   = v1v2%(restriction)s*v0v3%(restriction)s;
> +const  double lb%(restriction)s   = v0v2%(restriction)s*v1v3%(restriction)s;
> +const  double lc%(restriction)s   = v0v1%(restriction)s*v2v3%(restriction)s;
> +const  double s%(restriction)s    = 0.5*(la%(restriction)s+lb%(restriction)s+lc%(restriction)s);
> +const  double area%(restriction)s = std::sqrt(s%(restriction)s*(s%(restriction)s-la%(restriction)s)*(s%(restriction)s-lb%(restriction)s)*(s%(restriction)s-lc%(restriction)s));
> +
> +const double circumradius%(restriction)s = area%(restriction)s / ( 6.0*volume%(restriction)s );"""
> +
>  evaluate_basis_dof_map = """\
>  unsigned int element = 0;
>  unsigned int tmp = 0;
> @@ -469,3 +497,7 @@
>                2: _cell_volume_2D,
>                3: _cell_volume_3D}
>
> +circumradius = {1: _circumradius_1D,
> +                2: _circumradius_2D,
> +                3: _circumradius_3D}
> +
>
> === modified file 'ffc/cpp.py'
> --- ffc/cpp.py  2010-07-08 10:40:10 +0000
> +++ ffc/cpp.py  2010-07-08 14:24:27 +0000
> @@ -97,6 +97,7 @@
>     "inv(J)":           lambda i, j: "K_%d%d" % (i, j),
>     "det(J)":           lambda r=None: "detJ%s" % choose_map[r],
>     "cell volume":      lambda r=None: "volume%s" % choose_map[r],
> +    "circumradius":     lambda r=None: "circumradius%s" % choose_map[r],
>     "scale factor":     "det",
>     "transform":        lambda t, j, k, r: _transform(t, j, k, r),
>     "normal component": lambda r, j: "n%s%s" % (choose_map[r], j),
> @@ -207,6 +208,7 @@
>     "fiat coordinate map":  lambda n: fiat_coordinate_map[n],
>     "generate normal":      lambda d, i: _generate_normal(d, i),
>     "generate cell volume": lambda d, i: _generate_cell_volume(d, i),
> +    "generate circumradius": lambda d, i: _generate_circumradius(d, i),
>     "generate ip coordinates":  lambda g, num_ip, name, ip, r=None: (ip_coordinates[g][0], ip_coordinates[g][1] % \
>                                 {"restriction": choose_map[r], "ip": ip, "name": name, "num_ip": num_ip}),
>     "scale factor snippet": scale_factor,
> @@ -559,6 +561,22 @@
>         error("Unsupported domain_type: %s" % str(domain_type))
>     return code
>
> +def _generate_circumradius(geometric_dimension, domain_type):
> +    "Generate code for computing a cell's circumradius."
> +
> +    # Choose snippets
> +    radius = circumradius[geometric_dimension]
> +
> +    # Choose restrictions
> +    if domain_type in ("cell", "exterior_facet"):
> +        code = radius % {"restriction": ""}
> +    elif domain_type == "interior_facet":
> +        code = radius % {"restriction": choose_map["+"]}
> +        code += radius % {"restriction": choose_map["-"]}
> +    else:
> +        error("Unsupported domain_type: %s" % str(domain_type))
> +    return code
> +
>  # Functions.
>  def indent(block, num_spaces):
>     "Indent each row of the given string block with n spaces."
> @@ -638,6 +656,10 @@
>
>     lines = code.split("\n")
>     for (line_number, line) in enumerate(lines):
> +        # Exclude commented lines.
> +        if line[:2] == "//" or line[:3] == "///":
> +            continue
> +
>         # Split words
>         words = [word for word in line.split(" ") if not word == ""]
>         # Remember line where variable is declared
>
> === modified file 'ffc/quadrature/optimisedquadraturetransformer.py'
> --- ffc/quadrature/optimisedquadraturetransformer.py    2010-07-08 09:38:34 +0000
> +++ ffc/quadrature/optimisedquadraturetransformer.py    2010-07-08 14:24:27 +0000
> @@ -230,6 +230,16 @@
>
>         return {():create_symbol(volume, GEO)}
>
> +    def circumradius(self, o,  *operands):
> +        # Safety check.
> +        ffc_assert(not operands, "Didn't expect any operands for Circumradius: " + repr(operands))
> +
> +        # FIXME: KBO: This has to change for higher order elements
> +        circumradius = format["circumradius"](self.restriction)
> +        self.trans_set.add(circumradius)
> +
> +        return {():create_symbol(circumradius, GEO)}
> +
>     def create_argument(self, ufl_argument, derivatives, component, local_comp,
>                   local_offset, ffc_element, transformation, multiindices):
>         "Create code for basis functions, and update relevant tables of used basis."
>
> === modified file 'ffc/quadrature/quadraturegenerator.py'
> --- ffc/quadrature/quadraturegenerator.py       2010-07-08 10:40:10 +0000
> +++ ffc/quadrature/quadraturegenerator.py       2010-07-08 14:24:27 +0000
> @@ -84,7 +84,6 @@
>         # FIXME: This will most likely have to change if we support e.g., 2D elements in 3D space.
>         jacobi_code = format["jacobian and inverse"](geo_dim)
>         jacobi_code += "\n\n" + format["scale factor snippet"]
> -        jacobi_code += "\n\n" + format["generate cell volume"](geo_dim, domain_type)
>
>     elif domain_type == "exterior_facet":
>         cases = [None for i in range(num_facets)]
> @@ -106,7 +105,6 @@
>         jacobi_code = format["jacobian and inverse"](geo_dim)
>         jacobi_code += "\n\n" + format["facet determinant"](geo_dim)
>         jacobi_code += "\n\n" + format["generate normal"](geo_dim, domain_type)
> -        jacobi_code += "\n\n" + format["generate cell volume"](geo_dim, domain_type)
>
>     elif domain_type == "interior_facet":
>         # Modify the dimensions of the primary indices because we have a macro element
> @@ -136,10 +134,13 @@
>         jacobi_code += "\n\n"
>         jacobi_code += format["facet determinant"](geo_dim, "+")
>         jacobi_code += "\n\n" + format["generate normal"](geo_dim, domain_type)
> -        jacobi_code += "\n\n" + format["generate cell volume"](geo_dim, domain_type)
>     else:
>         error("Unhandled integral type: " + str(integral_type))
>
> +    # Add common (for cell, exterior and interior) geo code.
> +    jacobi_code += "\n\n" + format["generate cell volume"](geo_dim, domain_type)
> +    jacobi_code += "\n\n" + format["generate circumradius"](geo_dim, domain_type)
> +
>     # After we have generated the element code for all facets we can remove
>     # the unused transformations and tabulate the used psi tables and weights.
>     common = [remove_unused(jacobi_code, trans_set)]
>
> === modified file 'ffc/quadrature/quadraturetransformer.py'
> --- ffc/quadrature/quadraturetransformer.py     2010-07-08 09:38:34 +0000
> +++ ffc/quadrature/quadraturetransformer.py     2010-07-08 14:24:27 +0000
> @@ -296,15 +296,21 @@
>         ffc_assert(not operands, "Didn't expect any operands for CellVolume: " + repr(operands))
>
>         # FIXME: KBO: This has to change for higher order elements
> -#        detJ = format["det(J)"](self.restriction)
> -#        volume = format["absolute value"](detJ)
> -#        self.trans_set.add(detJ)
> -
>         volume = format["cell volume"](self.restriction)
>         self.trans_set.add(volume)
>
>         return {():volume}
>
> +    def circumradius(self, o,  *operands):
> +        # Safety check.
> +        ffc_assert(not operands, "Didn't expect any operands for Circumradius: " + repr(operands))
> +
> +        # FIXME: KBO: This has to change for higher order elements
> +        circumradius = format["circumradius"](self.restriction)
> +        self.trans_set.add(circumradius)
> +
> +        return {():circumradius}
> +
>
>     def create_argument(self, ufl_argument, derivatives, component, local_comp,
>                   local_offset, ffc_element, transformation, multiindices):
>
> === modified file 'ffc/quadrature/quadraturetransformerbase.py'
> --- ffc/quadrature/quadraturetransformerbase.py 2010-07-07 17:17:07 +0000
> +++ ffc/quadrature/quadraturetransformerbase.py 2010-07-08 14:24:27 +0000
> @@ -250,7 +250,7 @@
>         error("This object should be implemented by the child class.")
>
>     # -------------------------------------------------------------------------
> -    # FacetNormal, CellVolume (geometry.py).
> +    # FacetNormal, CellVolume, Circumradius (geometry.py).
>     # -------------------------------------------------------------------------
>     def facet_normal(self, o,  *operands):
>         print "\n\nVisiting FacetNormal: ", repr(o)
> @@ -260,6 +260,10 @@
>         print "\n\nVisiting CellVolume: ", repr(o)
>         error("This object should be implemented by the child class.")
>
> +    def circumradius(self, o,  *operands):
> +        print "\n\nVisiting Circumeradius: ", repr(o)
> +        error("This object should be implemented by the child class.")
> +
>     # -------------------------------------------------------------------------
>     # Things that can be handled by the base class.
>     # -------------------------------------------------------------------------
>
> === modified file 'test/regression/references/AlgebraOperators.h'
> --- test/regression/references/AlgebraOperators.h       2010-07-08 10:44:16 +0000
> +++ test/regression/references/AlgebraOperators.h       2010-07-08 14:24:27 +0000
> @@ -1241,6 +1241,9 @@
>
>     // Cell Volume.
>
> +    // Compute circumradius, assuming triangle is embedded in 2D.
> +
> +
>     // Array of quadrature weights.
>     static const double W9[9] = {0.05581442, 0.06367809, 0.01939638, 0.08930307, 0.10188494, 0.03103421, 0.05581442, 0.06367809, 0.01939638};
>     // Quadrature points on the UFC reference element: (0.10271765, 0.08858796), (0.06655407, 0.40946686), (0.02393113, 0.78765946), (0.45570602, 0.08858796), (0.29526657, 0.40946686), (0.10617027, 0.78765946), (0.80869439, 0.08858796), (0.52397907, 0.40946686), (0.18840941, 0.78765946)
>
> === modified file 'test/regression/references/Biharmonic.h'
> --- test/regression/references/Biharmonic.h     2010-07-08 10:44:16 +0000
> +++ test/regression/references/Biharmonic.h     2010-07-08 14:24:27 +0000
> @@ -2927,6 +2927,9 @@
>
>     // Cell Volume.
>
> +    // Compute circumradius, assuming triangle is embedded in 2D.
> +
> +
>     // Array of quadrature weights.
>     static const double W1 = 0.50000000;
>     // Quadrature points on the UFC reference element: (0.33333333, 0.33333333)
> @@ -3049,6 +3052,10 @@
>
>     // Cell Volume.
>
> +    // Compute circumradius, assuming triangle is embedded in 2D.
> +
> +
> +
>     // Array of quadrature weights.
>     static const double W2[2] = {0.50000000, 0.50000000};
>     // Quadrature points on the UFC reference element: (0.21132487), (0.78867513)
>
> === modified file 'test/regression/references/CoefficientOperators.h'
> --- test/regression/references/CoefficientOperators.h   2010-07-08 10:44:16 +0000
> +++ test/regression/references/CoefficientOperators.h   2010-07-08 14:24:27 +0000
> @@ -1245,6 +1245,9 @@
>
>     // Cell Volume.
>
> +    // Compute circumradius, assuming triangle is embedded in 2D.
> +
> +
>     // Array of quadrature weights.
>     static const double W9[9] = {0.05581442, 0.06367809, 0.01939638, 0.08930307, 0.10188494, 0.03103421, 0.05581442, 0.06367809, 0.01939638};
>     // Quadrature points on the UFC reference element: (0.10271765, 0.08858796), (0.06655407, 0.40946686), (0.02393113, 0.78765946), (0.45570602, 0.08858796), (0.29526657, 0.40946686), (0.10617027, 0.78765946), (0.80869439, 0.08858796), (0.52397907, 0.40946686), (0.18840941, 0.78765946)
>
> === modified file 'test/regression/references/EnergyNorm.h'
> --- test/regression/references/EnergyNorm.h     2010-07-08 10:44:16 +0000
> +++ test/regression/references/EnergyNorm.h     2010-07-08 14:24:27 +0000
> @@ -1757,6 +1757,9 @@
>
>     // Cell Volume.
>
> +    // Compute circumradius.
> +
> +
>     // Array of quadrature weights.
>     static const double W8[8] = {0.03697986, 0.01602704, 0.02115701, 0.00916943, 0.03697986, 0.01602704, 0.02115701, 0.00916943};
>     // Quadrature points on the UFC reference element: (0.15668264, 0.13605498, 0.12251482), (0.08139567, 0.07067972, 0.54415184), (0.06583869, 0.56593317, 0.12251482), (0.03420279, 0.29399880, 0.54415184), (0.58474756, 0.13605498, 0.12251482), (0.30377276, 0.07067972, 0.54415184), (0.24571333, 0.56593317, 0.12251482), (0.12764656, 0.29399880, 0.54415184)
>
> === modified file 'test/regression/references/Heat.h'
> --- test/regression/references/Heat.h   2010-07-08 10:44:16 +0000
> +++ test/regression/references/Heat.h   2010-07-08 14:24:27 +0000
> @@ -1863,6 +1863,9 @@
>
>     // Cell Volume.
>
> +    // Compute circumradius, assuming triangle is embedded in 2D.
> +
> +
>     // Array of quadrature weights.
>     static const double W4[4] = {0.15902069, 0.09097931, 0.15902069, 0.09097931};
>     // Quadrature points on the UFC reference element: (0.17855873, 0.15505103), (0.07503111, 0.64494897), (0.66639025, 0.15505103), (0.28001992, 0.64494897)
>
> === modified file 'test/regression/references/HyperElasticity.h'
> --- test/regression/references/HyperElasticity.h        2010-07-08 10:44:16 +0000
> +++ test/regression/references/HyperElasticity.h        2010-07-08 14:24:27 +0000
> @@ -6312,6 +6312,9 @@
>
>     // Cell Volume.
>
> +    // Compute circumradius.
> +
> +
>     // Array of quadrature weights.
>     static const double W1 = 0.16666667;
>     // Quadrature points on the UFC reference element: (0.25000000, 0.25000000, 0.25000000)
> @@ -6464,6 +6467,9 @@
>
>     // Cell Volume.
>
> +    // Compute circumradius.
> +
> +
>     // Array of quadrature weights.
>     static const double W8[8] = {0.03697986, 0.01602704, 0.02115701, 0.00916943, 0.03697986, 0.01602704, 0.02115701, 0.00916943};
>     // Quadrature points on the UFC reference element: (0.15668264, 0.13605498, 0.12251482), (0.08139567, 0.07067972, 0.54415184), (0.06583869, 0.56593317, 0.12251482), (0.03420279, 0.29399880, 0.54415184), (0.58474756, 0.13605498, 0.12251482), (0.30377276, 0.07067972, 0.54415184), (0.24571333, 0.56593317, 0.12251482), (0.12764656, 0.29399880, 0.54415184)
>
> === modified file 'test/regression/references/MathFunctions.h'
> --- test/regression/references/MathFunctions.h  2010-07-08 10:44:16 +0000
> +++ test/regression/references/MathFunctions.h  2010-07-08 14:24:27 +0000
> @@ -1241,6 +1241,9 @@
>
>     // Cell Volume.
>
> +    // Compute circumradius, assuming triangle is embedded in 2D.
> +
> +
>     // Array of quadrature weights.
>     static const double W4[4] = {0.15902069, 0.09097931, 0.15902069, 0.09097931};
>     // Quadrature points on the UFC reference element: (0.17855873, 0.15505103), (0.07503111, 0.64494897), (0.66639025, 0.15505103), (0.28001992, 0.64494897)
>
> === modified file 'test/regression/references/MetaData.h'
> --- test/regression/references/MetaData.h       2010-07-08 10:44:16 +0000
> +++ test/regression/references/MetaData.h       2010-07-08 14:24:27 +0000
> @@ -1245,6 +1245,9 @@
>
>     // Cell Volume.
>
> +    // Compute circumradius, assuming triangle is embedded in 2D.
> +
> +
>     // Array of quadrature weights.
>     static const double W25[25] = {0.01146508, 0.01980408, 0.01734151, 0.00875550, 0.00186555, 0.02316122, 0.04000729, 0.03503250, 0.01768745, 0.00376870, 0.02752899, 0.04755190, 0.04163897, 0.02102297, 0.00447941, 0.02316122, 0.04000729, 0.03503250, 0.01768745, 0.00376870, 0.01146508, 0.01980408, 0.01734151, 0.00875550, 0.00186555};
>     // Quadrature points on the UFC reference element: (0.04504259, 0.03980986), (0.03762125, 0.19801342), (0.02636464, 0.43797481), (0.01428579, 0.69546427), (0.00462229, 0.90146491), (0.22157861, 0.03980986), (0.18507071, 0.19801342), (0.12969594, 0.43797481), (0.07027629, 0.69546427), (0.02273848, 0.90146491), (0.48009507, 0.03980986), (0.40099329, 0.19801342), (0.28101259, 0.43797481), (0.15226786, 0.69546427), (0.04926754, 0.90146491), (0.73861153, 0.03980986), (0.61691587, 0.19801342), (0.43232925, 0.43797481), (0.23425943, 0.69546427), (0.07579660, 0.90146491), (0.91514755, 0.03980986), (0.76436533, 0.19801342), (0.53566054, 0.43797481), (0.29024993, 0.69546427), (0.09391280, 0.90146491)
> @@ -1428,6 +1431,9 @@
>
>     // Cell Volume.
>
> +    // Compute circumradius, assuming triangle is embedded in 2D.
> +
> +
>     // Array of quadrature weights.
>     static const double W9[9] = {0.05581442, 0.06367809, 0.01939638, 0.08930307, 0.10188494, 0.03103421, 0.05581442, 0.06367809, 0.01939638};
>     // Quadrature points on the UFC reference element: (0.10271765, 0.08858796), (0.06655407, 0.40946686), (0.02393113, 0.78765946), (0.45570602, 0.08858796), (0.29526657, 0.40946686), (0.10617027, 0.78765946), (0.80869439, 0.08858796), (0.52397907, 0.40946686), (0.18840941, 0.78765946)
>
> === modified file 'test/regression/references/Normals.h'
> --- test/regression/references/Normals.h        2010-07-08 10:44:16 +0000
> +++ test/regression/references/Normals.h        2010-07-08 14:24:27 +0000
> @@ -3296,6 +3296,9 @@
>
>     // Cell Volume.
>
> +    // Compute circumradius, assuming triangle is embedded in 2D.
> +
> +
>     // Array of quadrature weights.
>     static const double W1 = 1.00000000;
>     // Quadrature points on the UFC reference element: (0.50000000)
>
> === modified file 'test/regression/references/PoissonDG.h'
> --- test/regression/references/PoissonDG.h      2010-07-08 10:44:16 +0000
> +++ test/regression/references/PoissonDG.h      2010-07-08 14:24:27 +0000
> @@ -1927,6 +1927,9 @@
>
>     // Cell Volume.
>
> +    // Compute circumradius, assuming triangle is embedded in 2D.
> +
> +
>     // Array of quadrature weights.
>     static const double W2[2] = {0.50000000, 0.50000000};
>     // Quadrature points on the UFC reference element: (0.21132487), (0.78867513)
> @@ -2113,6 +2116,10 @@
>
>     // Cell Volume.
>
> +    // Compute circumradius, assuming triangle is embedded in 2D.
> +
> +
> +
>     // Array of quadrature weights.
>     static const double W2[2] = {0.50000000, 0.50000000};
>     // Quadrature points on the UFC reference element: (0.21132487), (0.78867513)
>
> === modified file 'test/regression/references/QuadratureElement.h'
> --- test/regression/references/QuadratureElement.h      2010-07-08 10:44:16 +0000
> +++ test/regression/references/QuadratureElement.h      2010-07-08 14:24:27 +0000
> @@ -3247,6 +3247,9 @@
>
>     // Cell Volume.
>
> +    // Compute circumradius, assuming triangle is embedded in 2D.
> +
> +
>     // Array of quadrature weights.
>     static const double W4[4] = {0.15902069, 0.09097931, 0.15902069, 0.09097931};
>     // Quadrature points on the UFC reference element: (0.17855873, 0.15505103), (0.07503111, 0.64494897), (0.66639025, 0.15505103), (0.28001992, 0.64494897)
> @@ -3359,6 +3362,9 @@
>
>     // Cell Volume.
>
> +    // Compute circumradius, assuming triangle is embedded in 2D.
> +
> +
>     // Array of quadrature weights.
>     static const double W4[4] = {0.15902069, 0.09097931, 0.15902069, 0.09097931};
>     // Quadrature points on the UFC reference element: (0.17855873, 0.15505103), (0.07503111, 0.64494897), (0.66639025, 0.15505103), (0.28001992, 0.64494897)
>
> === modified file 'test/regression/references/SpatialCoordinates.h'
> --- test/regression/references/SpatialCoordinates.h     2010-07-08 10:44:16 +0000
> +++ test/regression/references/SpatialCoordinates.h     2010-07-08 14:24:27 +0000
> @@ -2403,6 +2403,9 @@
>
>     // Cell Volume.
>
> +    // Compute circumradius, assuming triangle is embedded in 2D.
> +
> +
>     // Array of quadrature weights.
>     static const double W4[4] = {0.15902069, 0.09097931, 0.15902069, 0.09097931};
>     // Quadrature points on the UFC reference element: (0.17855873, 0.15505103), (0.07503111, 0.64494897), (0.66639025, 0.15505103), (0.28001992, 0.64494897)
> @@ -2500,6 +2503,9 @@
>
>     // Cell Volume.
>
> +    // Compute circumradius, assuming triangle is embedded in 2D.
> +
> +
>     // Array of quadrature weights.
>     static const double W2[2] = {0.50000000, 0.50000000};
>     // Quadrature points on the UFC reference element: (0.21132487), (0.78867513)
>
> === modified file 'test/regression/references/StabilisedStokes.h'
> --- test/regression/references/StabilisedStokes.h       2010-07-08 10:44:16 +0000
> +++ test/regression/references/StabilisedStokes.h       2010-07-08 14:24:27 +0000
> @@ -5631,6 +5631,9 @@
>
>     // Cell Volume.
>
> +    // Compute circumradius, assuming triangle is embedded in 2D.
> +
> +
>     // Array of quadrature weights.
>     static const double W4[4] = {0.15902069, 0.09097931, 0.15902069, 0.09097931};
>     // Quadrature points on the UFC reference element: (0.17855873, 0.15505103), (0.07503111, 0.64494897), (0.66639025, 0.15505103), (0.28001992, 0.64494897)
> @@ -5769,6 +5772,9 @@
>
>     // Cell Volume.
>
> +    // Compute circumradius, assuming triangle is embedded in 2D.
> +
> +
>     // Array of quadrature weights.
>     static const double W4[4] = {0.15902069, 0.09097931, 0.15902069, 0.09097931};
>     // Quadrature points on the UFC reference element: (0.17855873, 0.15505103), (0.07503111, 0.64494897), (0.66639025, 0.15505103), (0.28001992, 0.64494897)
>
> === modified file 'test/regression/references/TensorWeightedPoisson.h'
> --- test/regression/references/TensorWeightedPoisson.h  2010-07-08 10:44:16 +0000
> +++ test/regression/references/TensorWeightedPoisson.h  2010-07-08 14:24:27 +0000
> @@ -3123,6 +3123,9 @@
>
>     // Cell Volume.
>
> +    // Compute circumradius, assuming triangle is embedded in 2D.
> +
> +
>     // Array of quadrature weights.
>     static const double W1 = 0.50000000;
>     // Quadrature points on the UFC reference element: (0.33333333, 0.33333333)
>
> === modified file 'test/regression/references/VectorLaplaceGradCurl.h'
> --- test/regression/references/VectorLaplaceGradCurl.h  2010-07-08 10:44:16 +0000
> +++ test/regression/references/VectorLaplaceGradCurl.h  2010-07-08 14:24:27 +0000
> @@ -24636,6 +24636,9 @@
>
>     // Cell Volume.
>
> +    // Compute circumradius.
> +
> +
>     // Array of quadrature weights.
>     static const double W8[8] = {0.03697986, 0.01602704, 0.02115701, 0.00916943, 0.03697986, 0.01602704, 0.02115701, 0.00916943};
>     // Quadrature points on the UFC reference element: (0.15668264, 0.13605498, 0.12251482), (0.08139567, 0.07067972, 0.54415184), (0.06583869, 0.56593317, 0.12251482), (0.03420279, 0.29399880, 0.54415184), (0.58474756, 0.13605498, 0.12251482), (0.30377276, 0.07067972, 0.54415184), (0.24571333, 0.56593317, 0.12251482), (0.12764656, 0.29399880, 0.54415184)
>
>
>