Comments (10)
Fixed in FEniCS/ufl#295 (though we also need to update our UFL fork).
from firedrake.
This is very curious. I have looked at the commits for TSFC and UFL in the last year and none of them seem to touch CellDiameter
.
from firedrake.
My guess is FEniCS/ufl#197
That probably changed the implemented of cell_diameter
in apply_geometry_lowering
in UFL to return CellDiameter
for extruded hex cells, rather than fall-through to the Q1 case.
from firedrake.
Spot on @wence-, thanks! For an extruded mesh we have domain.ufl_coordinate_element().degree() == (1, 1)
which was a previously permissible element. Now though we have domain.ufl_coordinate_element().embedded_superdegree == 2
which is no longer allowed.
This might well be a simple fix. Looking at where embedded_superdegree
is defined we should probably be using max
instead of sum
(we even use min
for embedded_subdegree
).
from firedrake.
Nah, sum
is correct, since a Q1 element contains some quadratic polynomials, so it is embedded in the complete polynomial space P2.
from firedrake.
That implementation is, however, probably wrong because it should probably say sum(sub.embedded_superdegree() for sub in sub_elements())
(which would handle the case of TPE(TPE(interval, interval), interval)
(say)
from firedrake.
OK. Do you have any suggestion for what the right thing is to do here? Should CellDiameter
for an extruded mesh not be supported?
from firedrake.
I think in apply_geometry_lowering the check for Q1 cells needs to be reinstated. So it does something like:
if all(degree == 1 for degree in self.degree()):
# can do affine and/or Q1 lowering
I don't know exactly how to check for Q1, but notice that previously the check was (pseudo-code)
if not (P1 or Q1):
dont_lower
elif P1:
lower_simplex
else:
# must be Q1
lower_hypercube
But now the check is:
if not P1:
dont_lower
elif P1:
lower_simplex
else:
# unreachable
lower_hypercube
from firedrake.
I believe that degree()
is no longer a UFL finite element property and now only embedded_{super,sub}degree
exist so this may be tricky to fix. I have added this to the agenda for the next Firedrake meeting.
from firedrake.
This looks like a mistake in the UFL changes last year. The test for geometry lowering is using the embedded_superdegree but it should be using the embedded_subdegree. The reason subdegree is right is that you care about whether the edges are straight, not whether there are any quadratic functions on the interior.
from firedrake.
Related Issues (20)
- BUG: Solving the Stokes equations defined with TrialFunction returns an error HOT 1
- BUG: Greater error than expected in quadrilateral GLL elements HOT 4
- Compute norm of assembled derivative HOT 5
- "Too many indices for sum factorisation!" for calculating radius on extruded CubedSphereMesh. HOT 1
- INSTALL: ImportError when running firedrake-update on Linux HOT 2
- INSTALL: Linux (Ubuntu 22.04.4 LTS) HOT 12
- Tests for `to_petsc_local_numbering`
- BUG: firedrake-install is now failing with --petsc-int-type=int64 HOT 3
- Buckling problem HOT 2
- Flake8 for demos HOT 2
- Zenodo release
- Labelling of Internal Facets in Mesh Generated with Netgen HOT 3
- Zenodo release request
- Error on interpolation using --petsc-int-type int64 HOT 1
- BUG: Adjoint inconsistency with self-assignment via projection HOT 1
- BUG: Many tests fail with 64-bit indices
- Zenodo release please. HOT 1
- BUG: mesh.locate_cell not returning what is expected for points outside the mesh (--petsc-int-type=int64) HOT 2
- Interpolation on two different meshes doesn't work on parallel
- BUG: restricted mode in Lineareigenproblem for mixed problems.
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from firedrake.