API
API of FerriteIGA
After reinit! on cell or facet values, assembly follows the Ferrite manual.
Interpolation and cells
FerriteIGA.IGAInterpolation — Type
IGAInterpolation{shape, order}()Bernstein basis of degree order on shape (RefLine, RefQuadrilateral, or RefHexahedron). Use with BezierCellValues. For a 2D vector unknown write ip^2.
FerriteIGA.BezierCell — Type
BezierCell{shape, order}(nodes)One cell of a BezierGrid. nodes are control-point numbers. order is the degree.
FerriteIGA.BezierCoords — Type
BezierCoordsData for one cell, from getcoordinates. x, w are the NURBS points and weights. xb, wb are the Bézier points and weights. beo is the extraction operator.
FerriteIGA.BezierGrid — Type
BezierGrid(mesh::NURBSMesh)
BezierGrid(grid::Grid)Ferrite grid with NURBS weights and an extraction operator on each cell. BezierGrid(mesh) builds this from a NURBS patch. BezierGrid(grid) wraps an ordinary Ferrite grid.
FerriteIGA.BezierExtractionOperator — Type
BezierExtractionOperator{T}Represent the Bézier extraction operator for an element, used to map between the local Bernstein polynomial basis and the global B-spline or NURBS basis.
Grid helpers
Coordinates, weights, and extraction operators on a BezierGrid.
FerriteIGA.get_nurbs_coordinates — Function
get_nurbs_coordinates(grid::BezierGrid, cellid)Return the NURBS control-point coordinates for cell cellid
FerriteIGA.get_nurbs_weights — Function
get_nurbs_weights(grid::BezierGrid, cellid)Return a new vector of NURBS weights for cell cellid.
FerriteIGA.get_nurbs_weights! — Function
get_nurbs_weights!(w, grid::BezierGrid, cellid)
get_nurbs_weights!(w, grid::BezierGrid, cell)Fill w with the NURBS weights for the given cell (by id or cell object). w must be at least as long as the number of control points on the cell.
FerriteIGA.get_bezier_coordinates — Function
get_bezier_coordinates(grid::BezierGrid, cellid)Allocate and return (xb, wb, x, w) for cell cellid: Bézier points/weights and NURBS points/weights. See get_bezier_coordinates!.
FerriteIGA.get_bezier_coordinates! — Function
get_bezier_coordinates!(xb, wb, x, w, grid::BezierGrid, cellid)In-place fill of NURBS and Bézier data for cell cellid.
x,ware the NURBS control points and weights respectively.xb,wbare the above transformed in Bernstein basis from the Bezier extraction operator.
If the cell has no extraction operator, xb/wb is made as a copy of x/w.
FerriteIGA.get_extraction_operator — Function
get_extraction_operator(grid::BezierGrid, cellid)Bézier extraction operator $C^e$ for cell cellid, or nothing if the cell is not an IGA cell.
Cell and facet values
FerriteIGA.BezierCellValues — Type
BezierCellValues(qr, ip)Shape values on an IGA cell. Call reinit!(cv, coords) first. Then shape_value and shape_gradient return NURBS values.
FerriteIGA.BezierFacetValues — Type
BezierFacetValues(fqr, ip)Shape values on an IGA face. Call reinit!(fv, coords, faceid) first.
FerriteIGA.set_bezier_operator! — Function
set_bezier_operator!(cv, beo)
set_bezier_operator!(cv, beo, w)Set the current Bézier extraction operator on a BezierCellValues or BezierFacetValues. When NURBS weights w are given, they are stored and used in reinit! to form the rational basis.
Prefer reinit!(cv, getcoordinates(grid, cellid)), which sets the operator from BezierCoords automatically. This method is for manual assembly loops.
Iteration caches
Ferrite-style caches for looping over cells and facets on a BezierGrid.
FerriteIGA.IGACellCache — Type
IGACellCache(dh::DofHandler)
IGACellCache(dh::DofHandler, flags::UpdateFlags)Ferrite-style cell cache for a BezierGrid. After reinit!(cache, cellid), use getcoordinates(cache) for BezierCoords, celldofs(cache), and getnodes(cache) like Ferrite's CellCache.
FerriteIGA.IGAFaceCache — Type
IGAFaceCache(dh::DofHandler)
IGAFaceCache(dh::DofHandler, flags::UpdateFlags)Facet cache for a BezierGrid. After reinit!(cache, FacetIndex(cellid, faceid)), coordinate and dof accessors are delegated to the IGACellCache.
I/O
FerriteIGA.VTKIGAFile — Type
VTKIGAFile(filename, grid::BezierGrid)Write a BezierGrid to a .vtu file.
NURBS patches
Mesh construction and evaluation. Refinement APIs live on the NURBSMesh page.
FerriteIGA.generate_nurbs_patch — Function
generate_nurbs_patch(name, nels, order; kwargs...)Build a NURBS patch. name is the geometry (:plate_with_hole, :rectangle, :ring, ...). nels is how many elements in each direction. order is the degree. The Meshes page lists every name and keyword.