BUG: Horizontal R space on tensor product element is not globally constant
Los mantenedores suelen responder en 1 día
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 4/5
- Tiempo estimado
- 3-5 días
- Aptitud para principiantes
- 48/100
Línea de trabajo
Comienza ejecutando el reproducer del issue y compara las dimensiones de los espacios de funciones R × CG y DQ0 × CG a medida que aumenta la resolución de la malla base. Rastrea cómo se representa el elemento R horizontal en TensorProductElement y en la extrusión; después, confirma el fix obteniendo 5 DOFs para cada resolución de malla indicada.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Describe the bug
This is a bug only on the horizontal R space - not the vertical.
I would like to construct an element on a cuboid mesh that is a tensor product of R space and CG.
elt = TensorProductElement(FiniteElement("R", quadrilateral, 0),
FiniteElement("CG", interval, p))
M = FunctionSpace(mesh, elt)
This TensorProductElement treats the R space as a per-cell discontinuous constant.
Steps to Reproduce
The following code compares the actual number of DOFS for this TensorProductElement to the expected DOFs (P*Layers + 1 when CG^P is in the extrusion direction and R in the horizontal direction).
We only extrude in 2 layers for each example so the number of DOFs coming from CG should not change. If the R space works correctly then increasing the resolution of the base mesh should not change the number of DOFs.
from firedrake import *
P = 2
LAYERS = 2
EXPECTED = P * LAYERS + 1
print(f"{'nx,ny':>8} {'base cells':>11} {'R (x) CG':>10} {'DQ0 (x) CG':>11} {'expected':>9}")
for n in (1, 2, 3, 4):
base = UnitSquareMesh(n, n, quadrilateral=True)
mesh = ExtrudedMesh(base, layers=LAYERS, layer_height=1.0 / LAYERS)
cg_v = FiniteElement("CG", interval, P)
r_elt = TensorProductElement(FiniteElement("R", quadrilateral, 0), cg_v)
dq_elt = TensorProductElement(FiniteElement("DQ", quadrilateral, 0), cg_v)
dim_r = FunctionSpace(mesh, r_elt).dim()
dim_dq = FunctionSpace(mesh, dq_elt).dim()
print(f"{f'{n},{n}':>8} {n*n:>11} {dim_r:>10} {dim_dq:>11} {EXPECTED:>9}")
Expected behavior
I expect every example R \times CG example in the above to have 5 DOFs.
Environment:
- OS: MACOS
- Python version: 3.14.6
- Lenguaje dominante
- Python
- Estrellas
- 684
- Forks
- 204
- Merge medio
- 4 d 14 h
- PR fusionados (30 d)
- 46
Preparar el entorno
- Sin Dockerfile ni archivo de Docker Compose
- Tiene una plantilla de pull request
- Sin guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de firedrakeproject/firedrake
-
BUG: NonlinearVariationalSolver errors with adj_kwargsPosiblemente ocupada @dham la tomó hace 151 días. Abiertobug
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
firedrakeproject/firedrake#5186 ·
Los mantenedores suelen responder en 1 día
-
bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
firedrakeproject/firedrake#5091 ·
Los mantenedores suelen responder en 1 día
-
documentation
Dificultad 1/5 1-3 horas Aptitud para principiantes 82/100
firedrakeproject/firedrake#3556 ·
Los mantenedores suelen responder en 1 día
-
bug
Dificultad 4/5 3-5 días Aptitud para principiantes 22/100
firedrakeproject/firedrake#5644 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
Function.assign on a subset fails with a Constant, a Real Function or abs in the expressionPosiblemente ocupada @connorjward la tomó hace 2 días. Abierto
firedrakeproject/firedrake#5643 · 1 asignado ·
Los mantenedores suelen responder en 1 día
Todos los issues de firedrakeproject/firedrake
Issues similares
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
alltheplaces/alltheplaces#20570 · 2 comentarios ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 74/100
Los mantenedores suelen responder en 1 día
-
area:ci bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 85/100
catincloud-labs/dagster-dex#206 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
number_to_words raises ValueError with threshold= for ordinals ("12th") and comma-grouped strings ("1,000")Posiblemente ocupada @hemtilva la tomó hoy. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 74/100
Los mantenedores suelen responder en 1 día
-
providers security
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
agentbreeder/agentbreeder#1031 ·
Los mantenedores suelen responder en 1 día