gridap / gridap/GridapEmbedded.jl

Moment fitting with simplices

Open
#74 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Julia
Stars
50
Forks
16
PR merge metrics
No merged PRs in 30d

Description

Dear @ericneiva ,

the moment fitting machinery is not working for simplex background meshes.

Since the `JacobiPolynomialBasis` are a tensor product, the following line tries to invert a rectangular matrix.

https://github.com/gridap/GridapEmbedded.jl/blob/4cf152de7a4d624b2cfad1e382c4ab5f38b839d7/src/MomentFittedQuadratures/MomentFittedQuadratures.jl#L322

I guess that we should use `pinv` instead. What do you think?

Here a MWE:
```julia
using GridapEmbedded
using GridapEmbedded.LevelSetCutters
using GridapEmbedded.Interfaces
using Gridap
using Gridap.ReferenceFEs
geo = sphere(0.5,x0=Point(0.0,0.0))
domain = (-1,1,-1,1)
partition = (5,5)
model = CartesianDiscreteModel(domain,partition) |> simplexify
cutgeo = cut(model,geo)
act = Triangulation(cutgeo,ACTIVE)
Measure(act,Quadrature(momentfitted,cutgeo,2))
```

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.