Skip to content

Commit

Permalink
shorten MWE
Browse files Browse the repository at this point in the history
  • Loading branch information
zjwegert committed Nov 15, 2024
1 parent a272132 commit f9d848f
Showing 1 changed file with 6 additions and 16 deletions.
22 changes: 6 additions & 16 deletions scripts/Embedded/Bugs/change_domain_bug.jl
Original file line number Diff line number Diff line change
Expand Up @@ -12,23 +12,13 @@ model = ref_model.model
Ω = Triangulation(model)
= Measure(Ω,2*order)
V_φ = TestFESpace(model,ReferenceFE(lagrangian,Float64,order))
Λ = SkeletonTriangulation(Ω)
= Measure(Λ,2order)

φh = interpolate(x->-cos(4π*x[1])*cos(4π*x[2])-0.2,V_φ)
x_φ = get_free_dof_values(φh)
idx = findall(isapprox(0.0;atol=10^-10),x_φ)
@assert isempty(idx)

Ωs = EmbeddedCollection(model,φh) do cutgeo
Γ = DifferentiableTriangulation(EmbeddedBoundary(cutgeo))
(;
=> Γ,
:dΓ => Measure(Γ,2*order)
)
end
geo = DiscreteGeometry(φh,model)
cutgeo = cut(model,geo)
Γ = DifferentiableTriangulation(EmbeddedBoundary(cutgeo))
= Measure(Γ,2order)

vh = zero(V_φ)

(vh)Ωs.
(vh*vh)Ωs.
(vh)dΓ
(vh*vh)dΓ

0 comments on commit f9d848f

Please sign in to comment.