Skip to content

Commit

Permalink
add dof indeices for faces and edges for beam/line elements
Browse files Browse the repository at this point in the history
  • Loading branch information
lijas committed Jul 2, 2024
1 parent 1f5ea8e commit d11004a
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions src/splines/bezier.jl
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ Ferrite.getnbasefunctions(::Bernstein{RefLine,2}) = 3

Ferrite.vertexdof_indices(::Bernstein{RefLine,2}) = ((1,),(2,))
Ferrite.edgedof_indices(::Bernstein{RefLine,2}) = ((1,2,3),)
Ferrite.facedof_indices(::Bernstein{RefLine,2}) = ()

function Ferrite.reference_shape_value(ip::Bernstein{RefLine,2}, _ξ::Vec{1}, i::Int)
ξ = 0.5*(_ξ[1] + 1.0)
Expand Down Expand Up @@ -183,6 +184,19 @@ function _compute_bezier_reference_shape_value(ip::Bernstein{shape,order}, ξ::V
return val
end

function _compute_vertexdof_indices(::Bernstein{RefLine,order}) where order
((1,),(2,))
end

function _compute_edgedof_indices(ip::Bernstein{RefLine,order}) where {order}
ind = ntuple(i-> i, order+1)
return (ind,)
end

function _compute_facedof_indices(ip::Bernstein{RefLine,order}) where {order}
()
end

function _compute_vertexdof_indices(::Bernstein{RefQuadrilateral,order}) where order
((1,),(2,),(3,),(4,),)
end
Expand Down

0 comments on commit d11004a

Please sign in to comment.