-
Notifications
You must be signed in to change notification settings - Fork 12
Expand file tree
/
Copy pathExtendableFEM.jl
More file actions
225 lines (203 loc) · 7.81 KB
/
ExtendableFEM.jl
File metadata and controls
225 lines (203 loc) · 7.81 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
"""
ExtendableFEM
$(read(joinpath(@__DIR__, "..", "README.md"), String))
"""
module ExtendableFEM
using ADTypes: ADTypes, KnownJacobianSparsityDetector
using ChunkSplitters: chunks
using BlockArrays: BlockMatrix, BlockVector, Block, blocks, axes, mortar
using CommonSolve: CommonSolve
using DifferentiationInterface: DifferentiationInterface,
AutoSparse, AutoForwardDiff, prepare_jacobian
using DiffResults: DiffResults
using DocStringExtensions: DocStringExtensions, TYPEDEF, TYPEDSIGNATURES
using ExtendableFEMBase: ExtendableFEMBase, AbstractFiniteElement,
AbstractFunctionOperator, AbstractH1FiniteElement,
AbstractHdivFiniteElement, BEdgeDofs, BFaceDofs,
CellDofs, Curl2D, Curl3D, CurlScalar,
DefaultName4Operator, Divergence, Dofmap4AssemblyType,
EdgeDofs, EffAT4AssemblyType, FEEvaluator, FEMatrix,
FEMatrixBlock, FESpace, FEVector, FEVectorBlock,
FaceDofs, Gradient, H1BR, H1BUBBLE, H1CR, H1MINI,
H1P1, H1P1TEB, H1P2, H1P2B, H1P3, H1Pk, H1Q1, H1Q2,
HCURLN0, HCURLN1, HDIVBDM1, HDIVBDM2, HDIVRT0,
HDIVRT1, HDIVRTk, HDIVRTkENRICH, Hessian, Identity, IdentityComponent,
L2P0, L2P1, Laplacian, Length4Operator,
NeededDerivative4Operator, NormalFlux,
ParentDofmap4Dofmap, PointEvaluator, QPInfos,
QuadratureRule, Reconstruct, SegmentIntegrator,
StandardFunctionOperator, TangentFlux,
TangentialGradient, VertexRule, _addnz, add!,
addblock!, addblock_matmul!, displace_mesh,
displace_mesh!, eval_func, eval_func_bary, evaluate!,
evaluate_bary!, fill!, get_AT, get_FEType,
get_ncomponents, get_ndofs, get_polynomialorder,
initialize!, integrate, integrate!,
integrate_segment!, lazy_interpolate!, nodevalues,
nodevalues!, nodevalues_subset!, nodevalues_view,
norms, unicode_gridplot, unicode_scalarplot,
update_basis!, SymmetricGradient
using ExtendableGrids: ExtendableGrids, AT_NODES, AbstractElementGeometry,
Adjacency, AssemblyType, BEdgeNodes, BFaceFaces, BFaceNormals,
BFaceNodes, BFaceRegions, CellAssemblyGroups,
CellFaceOrientations, CellFaces, CellGeometries,
CellNodes, CellRegions, Coordinates, EdgeNodes,
ElementGeometries, ExtendableGrid, FaceCells, FaceEdges,
FaceNodes, FaceNormals, FaceRegions, FaceVolumes,
PColorPartitions, PartitionCells, PartitionEdges,
GridComponentAssemblyGroups4AssemblyType,
GridComponentGeometries4AssemblyType,
GridComponentRegions4AssemblyType,
GridComponentVolumes4AssemblyType, L2GTransformer,
ON_BEDGES, ON_BFACES, ON_CELLS, ON_EDGES, ON_FACES,
ON_IFACES, SerialVariableTargetAdjacency,
UniqueBFaceGeometries, UniqueCellGeometries,
UniqueFaceGeometries, append!, dim_element, eval_trafo!,
facetype_of_cellface, interpolate!,
max_num_targets_per_source, num_cells, num_faces,
num_nodes, num_sources, num_targets, simplexgrid,
num_pcolors, num_partitions, num_partitions_per_color,
unique, update_trafo!, xrefFACE2xrefCELL,
xrefFACE2xrefOFACE
using ExtendableSparse: ExtendableSparse, ExtendableSparseMatrix, flush!,
MTExtendableSparseMatrixCSC, findindex,
rawupdateindex!
using ForwardDiff: ForwardDiff
using GridVisualize: GridVisualize, GridVisualizer, gridplot!, reveal, save,
scalarplot!, vectorplot!, streamplot!
using LinearAlgebra: LinearAlgebra, copyto!, isposdef, mul!, norm
using LinearSolve: LinearSolve, LinearProblem, UMFPACKFactorization, deleteat!,
init, solve
using Printf: Printf, @printf, @sprintf
using SciMLBase: SciMLBase
using SparseConnectivityTracer: SparseConnectivityTracer, TracerSparsityDetector, jacobian_sparsity
using SparseArrays: SparseArrays, AbstractSparseArray, findnz, nnz,
nzrange, rowvals, sparse, SparseVector, spzeros, qr, rank
using SparseMatrixColorings: GreedyColoringAlgorithm, sparsity_pattern
using StaticArrays: @MArray
using TimerOutputs: TimerOutput, print_timer, @timeit
using UnicodePlots: UnicodePlots
## reexport stuff from ExtendableFEMBase and ExtendableGrids
export FESpace, FEMatrix, FEVector
export H1P1, H1P2, H1P3, H1Pk
export H1Q1, H1Q2
export H1CR, H1BR, H1P2B, H1MINI, H1P1TEB, H1BUBBLE
export HDIVRT0, HDIVRT1, HDIVRTk
export HDIVBDM1, HDIVBDM2
export HCURLN0, HCURLN1
export HDIVRTkENRICH
export L2P0, L2P1
export ON_FACES, ON_BFACES, ON_EDGES, ON_FACES, ON_CELLS, AT_NODES
export nodevalues, nodevalues!, nodevalues_view, nodevalues_subset!
export interpolate!, lazy_interpolate!
export PointEvaluator, evaluate, evaluate!, evaluate_bary!, eval_func, eval_func_bary
export SegmentIntegrator, integrate_segment!, initialize!
export integrate!, integrate, QuadratureRule
export unicode_gridplot, unicode_scalarplot
export CellDofs, BFaceDofs, FaceDofs, EdgeDofs, BEdgeDofs
# export get_polynomialorder
export displace_mesh, displace_mesh!
export Reconstruct, Identity, Divergence, Gradient
# export _addnz
export addblock!, addblock_matmul!
export unicode_gridplot, unicode_scalarplot
## reexport stuff from GridVisualize
export reveal, save
include("io.jl")
export print_convergencehistory
export print_table
include("unknowns.jl")
export Unknown
export grid, dofgrid, streamlines
export id, grad, hessian, div, normalflux, tangentialflux, Δ, apply, curl1, curl2, curl3, laplace, tangentialgrad, symgrad_voigt, εV
include("operators.jl")
#export AbstractOperator
export assemble!, apply_penalties!
include("common_operators/reduction_operator.jl")
# wip
#export AbstractReductionOperator
#export FixbyInterpolation
include("restrictions.jl")
include("problemdescription.jl")
export ProblemDescription
export assign_unknown!
export assign_operator!
export replace_operator!
export assign_restriction!
include("helper_functions.jl")
export get_periodic_coupling_info
export get_periodic_coupling_matrix
export tmul!
include("tensors.jl")
export TensorDescription
export TDScalar
export TDVector
export TDMatrix
export TDRank3
export TDRank4
export tensor_view
include("solver_config.jl")
export SolverConfiguration
export residual
export timeroutputs
include("solvers.jl")
export solve
export iterate_until_stationarity
export get_unknown_id
include("solvers_diffeq.jl")
export generate_ODEProblem
include("jump_operators.jl")
#export DiscontinuousFunctionOperator
export Jump, Average, Left, Right
export jump, average, this, other
#export is_discontinuous
include("common_operators/item_integrator.jl")
export ItemIntegrator
export evaluate, evaluate!
export L2NormIntegrator
include("common_operators/item_integrator_dg.jl")
export ItemIntegratorDG
include("common_operators/linear_operator.jl")
export LinearOperator
include("common_operators/linear_operator_dg.jl")
export LinearOperatorDG
include("common_operators/bilinear_operator.jl")
export BilinearOperator
include("common_operators/bilinear_operator_dg.jl")
export BilinearOperatorDG
include("common_operators/nonlinear_operator.jl")
export NonlinearOperator
include("common_operators/callback_operator.jl")
export CallbackOperator
include("common_operators/combinedofs.jl")
export CombineDofs
export get_periodic_coupling_info
include("common_operators/interpolateboundarydata_operator.jl")
export InterpolateBoundaryData
export apply!
include("common_operators/homogeneousdata_operator.jl")
export HomogeneousBoundaryData
export HomogeneousData
export assemble!, fixed_dofs, fixed_vals
include("common_operators/fixdofs_operator.jl")
export FixDofs
include("common_operators/discface_interpolator.jl")
export FaceInterpolator
include("common_restrictions/boundarydata_restriction.jl")
export BoundaryDataRestriction
include("common_restrictions/coupled_dofs_restriction.jl")
export CoupledDofsRestriction
include("common_restrictions/linear_functional_restriction.jl")
export LinearFunctionalRestriction
export ZeroMeanValueRestriction
export MassRestriction
include("plots.jl")
export plot_convergencehistory!
export scalarplot!
export vectorplot!
export plot, plot!
# export default_generateplots
export plot_unicode
include("diffeq_interface.jl")
export generate_ODEProblem
end #module