After months of work, the Gridap developers are happy to announce the Gridap v0.15 release !
This new version comes with major improvements in the user API (and also in the library internals). The most exciting novelty is how the user writes the weak form. Now, it should be as easy as “copying” it from the paper. Gridap will automatically generate an efficient Finite Element assembly loop for you, thanks to the awesome Julia JIT compiler.
Examples
Here is how the weak form of some well-known PDEs can be specified with the new Gridap API.
Poisson equation with a source term and a Neumann boundary condition
(see complete code here)
f(x) = 1.0
h(x) = 3.0
a(u,v) = ∫( ∇(v)⋅∇(u) )*dΩ
l(v) = ∫( v*f )*dΩ + ∫( v*h )*dΓ
Linear elasticity without body forces
(see complete code here)
E = 70.0e9;
ν = 0.33
λ = (E*ν)/((1+ν)*(1-2*ν))
μ = E/(2*(1+ν))
σ(ε) = λ*tr(ε)*one(ε) + 2*μ*ε
a(u,v) = ∫( ε(v) ⊙ (σ∘ε(u)) )*dΩ
l(v) = 0
Incompressible Navier-Stokes equation
(see complete code here)
Re = 10.0
res((u,p),(v,q)) = ∫( v⋅(Re*u⋅∇(u)) + ∇(v)⊙∇(u) - (∇⋅v)*p + q*(∇⋅u) )*dΩ
Poisson equation discretized with DG
(see complete code here)
a(u,v) =
∫( ∇(v)⋅∇(u) )*dΩ +
∫( (γ/h)*v*u - v*(n_Γ⋅∇(u)) - (n_Γ⋅∇(v))*u )*dΓ +
∫( (γ/h)*jump(v*n_Λ)⋅jump(u*n_Λ) -
jump(v*n_Λ)⋅mean(∇(u)) -
mean(∇(v))⋅jump(u*n_Λ) )*dΛ
l(v) =
∫( v*f )*dΩ +
∫( (γ/h)*v*u - (n_Γ⋅∇(v))*u )*dΓ
Stokes equation with an equal order DG
(see complete code here)
a((u,p),(v,q)) =
∫( ∇(v)⊙∇(u) - ∇(q)⋅u + v⋅∇(p) )*dΩ +
∫( (γ/h)*v⋅u - v⋅(n_Γ⋅∇(u)) - (n_Γ⋅∇(v))⋅u + 2*(q*n_Γ)⋅u )*dΓ +
∫( (γ/h)*jump(v⊗n_Λ)⊙jump(u⊗n_Λ) -
jump(v⊗n_Λ)⊙mean(∇(u)) -
mean(∇(v))⊙jump(u⊗n_Λ) +
(γ0*h)*jump(q*n_Λ)⋅jump(p*n_Λ) +
jump(q*n_Λ)⋅mean(u) -
mean(v)⋅jump(p*n_Λ)
)*dΛ
l((v,q)) =
∫( v⋅f + q*g )*dΩ +
∫( (γ/h)*v⋅u - (n_Γ⋅∇(v))⋅u + (q*n_Γ)⋅u )*dΓ
How to get started?
If you are further interested in the project, visit the Gridap.jl repository. Consider to give us an !
If you want to start learning how to solve PDEs with Gridap.jl, visit our Tutorials repository.
You are welcome to interact with the Gridap community via our Gitter chat.
Do you want to collaborate?
We are open to scientific collaborations with research groups willing to use Gridap for their research. We can collaborate, e.g., to add new functionality to the library and to write scientific publications resulting from it.