Heat Conduction
LowLevelFEM.FDM
— MethodFDM(K, C, q, T0, tₘₐₓ, Δt; ϑ=...)
Solves a transient heat conduction problem using Finite Difference Method (FDM). Introducing a ϑ
parameter, special cases can be used as the Forward Euler (explicit, ϑ=0), Backward Euler (implicit, ϑ=1), Crank-Nicolson (ϑ=0.5) and intermediate cases (0<ϑ<1). (This method is known as ϑ-method. See [5].) K
is the heat conduction matrix, C
is the heat capacity matrix, q
is the heat flux vector, T0
is the initial temperature, tₘₐₓ
is the upper bound of the time intervall (lower bound is zero) and Δt
is the time step size. Returns the nodal temperature vectors in each time step arranged in the columns of the matrix T
and a vector t
of the time instants used.
The critical (largest allowed) time step is Δtₘₐₓ = 2 / ((1-2ϑ)*λₘₐₓ)
where λₘₐₓ
is the largest eigenvalue of (K+λC)θ=0 eigenvalue problem and ϑ
is the parameter of the ϑ-method. Default value of ϑ
is 1/2.
Return: T
Types:
K
: SystemMatrixC
: SystemMatrixq
: ScalarFieldT0
: ScalarFieldtₘₐₓ
: Float64Δt
: Float64T
: ScalarField
LowLevelFEM.applyHeatConvection!
— MethodapplyHeatConvection!(heatCondMat, heatFluxVec, heatConv)
Applies heat convectiom boundary conditions heatConv
on a heat conduction matrix heatCondMat
and heat flux vector heatFluxVec
. Mesh details are in problem
. heatConv
is a tuple of name
of physical group and prescribed heat transfer coefficient h
and ambient temperature Tₐ
. The ambient temperature can be either a constant or a function of x, y and z coordinates.
Returns: nothing
Types:
problem
: ProblemheatCondMat
: SystemMatrixheatFluxVec
: VectorFieldheatConv
: Vector{Tuple{String, Float64, Float64, Float64}}
LowLevelFEM.heatCapacityMatrix
— MethodheatCapacityMatrix(problem; lumped=...)
Solves the heat capacity matrix of the problem
. If lumped
is true, solves lumped heat capacity matrix.
Return: heatCapMat
Types:
problem
: Problemlumped
: BooleanmassMat
: SystemMatrix
LowLevelFEM.heatConductionMatrix
— MethodheatConductionMatrix(problem)
Solves the heat conduction matrix of the problem
.
Returns: heatCondMat
Types:
problem
: ProblemheatCondMat
: SystemMatrix
Examples
Kth = heatConductionMatrix(problem)
LowLevelFEM.heatConvectionMatrix
— MethodheatConvectionMatrix(problem, heatConvection)
Solves the heat convection matrix of the problem
. heatConvection
is a vector of heat convection boundary condicions defined in function heatConduction
. With the heat convection vector (see the heatConvectionVector
function) heatConvVec
, temperature field vector T
in hand the heat flux vector qCV
arising from the heat convection boundary condition can be solved. qCV = heatConvMat * T - heatConvVec
Return: heatConvMat
Types:
problem
: ProblemheatConvection
: Vector{Tuple{String, Float64, Float64, Float64}}heatConvMat
: SystemMatrix
LowLevelFEM.heatConvectionVector
— MethodheatConvectionVector(problem, heatConvection)
Solves a heat convection vector of problem
. heatConvection
is a vector of heat convection boundary condicions defined in function heatConduction
. With the heat convection matrix (see the heatConvectionMatrix
function) heatConvMat
, temperature field vector T
in hand the heat flux vector qCV
arising from the heat convection boundary condition can be solved. qCV = heatConvMat * T - heatConvVec
Return: heatConvVec
Types:
problem
: ProblemheatConvection
: Vector{Tuple{String, Float64, Float64, Float64}}heatConvVec
: ScalarField
LowLevelFEM.heatFluxVector
— MethodheatFluxVector(problem, heatFlux)
Solves a heat flux or heat source vector of problem
. heatFlux
is a tuple of name of physical group name
, heat flux qn
normal to the surface of the body. The outward direction is positive. It can solve heat flux (or heat source) depending on the problem.
- In case of 2D problems and Point physical group means concentrated heat flux.
- In case of 2D problems and Line physical group means surface heat flux.
- In case of 2D problems and Surface physical group means body heat source.
- In case of 3D problems and Point physical group means concentrated heat flux.
- In case of 3D problems and Line physical group means edge heat source.
- In case of 3D problems and Surface physical group means surface heat flux.
- In case of 3D problems and Volume physical group means body heat source.
Return: heatFluxVec
Types:
problem
: ProblemheatFlux
: Vector{Tuple{String, Float64, Float64, Float64}}heatFluxVec
: VectorField
LowLevelFEM.heatSourceVector
— MethodheatSourceVector(problem, heatSource)
Solves a heat flux or heat source vector of problem
. heatSource
is a tuple of name of physical group name
, heat flux qn
normal to the surface of the body. The outward direction is positive. It can solve heat flux (or heat source) depending on the problem.
- In case of 2D problems and Point physical group means concentrated heat flux.
- In case of 2D problems and Line physical group means surface heat flux.
- In case of 2D problems and Surface physical group means body heat source.
- In case of 3D problems and Point physical group means concentrated heat flux.
- In case of 3D problems and Line physical group means edge heat source.
- In case of 3D problems and Surface physical group means surface heat flux.
- In case of 3D problems and Volume physical group means body heat source.
Same as the heatFluxVector
function.
Return: heatSourceVec
Types:
problem
: ProblemheatSource
: Vector{Tuple{String, Float64, Float64, Float64}}heatSourceVec
: VectorField
LowLevelFEM.initialTemperature!
— MethodinitialTemperature!(name, T0; T=...)
Changes the tempetature value to T
at nodes belonging to physical group name
. Original values are in temperature vector T0
.
Returns: nothing
Types:
name
: StringT0
: ScalarFieldT
: Float64
LowLevelFEM.initialTemperature
— MethodinitialTemperature(problem, name; T=...)
Sets the temperature value T
at nodes belonging to physical group name
. Returns the T0
initial nodal temperature vector.
Return: T0
Types:
problem
: Problemname
: StringT
: Float64T0
: ScalarField
LowLevelFEM.latentHeatMatrix
— MethodlatentHeatMatrix(problem, u, v, T0)
Solves the latent heat matrix of the problem
. With this matrix the generated heat due to deformations (given with displacement field u
and velocity field v
) can be solved. T0
is the current temperature field which is given in absolute temperature scale (Kelvin).
Return: latHeatMat
Types:
problem
: Problemu
: VectorFieldv
: VectorFieldT0
: ScalarFieldlatHeatMat
: SystemMatrix
LowLevelFEM.solveHeatFlux
— MethodsolveHeatFlux(T; DoFResults=false)
Solves the heat flux field q
from temperature vector T
. heat flux is given per elements, so it usually contains jumps at the boundary of elements. Details of mesh is available in problem
. If DoFResults
is true, q
is a matrix with nodal results. In this case showDoFResults
can be used to show the results (otherwise showHeatFluxResults
or showElementResults
).
Return: q
Types:
problem
: ProblemT
: ScalarFieldq
: VectorField
LowLevelFEM.solveTemperature
— MethodsolveTemperature(problem, flux, temp, heatconv)
Solves the temperature field T
of problem
with given heat flux flux
, temperature temp
and heat convection heatconv
.
Return: T
Types:
problem
: Problemflux
: Vector{Tuple}temp
: Vector{Tuple}heatconv
: Vector{Tuple}T
: ScalarField
LowLevelFEM.solveTemperature
— MethodsolveTemperature(problem, flux, temp)
Solves the temperature field T
of problem
with given heat flux flux
and temperature temp
.
Return: T
Types:
problem
: Problemflux
: Vector{Tuple}temp
: Vector{Tuple}T
: ScalarField
LowLevelFEM.solveTemperature
— MethodsolveTemperature(problem, u; T0=273.0)
Solves the raise of temperature T
during reversible (no dissipation) elastic deformations, where u
is the displacement field, and problem
is a heat cunduction problem.
Return: T
Types:
problem
: Problemu
: VectorFieldT0
: Float64T
: ScalarField
LowLevelFEM.solveTemperature
— MethodsolveTemperature(K, q)
Solves the equation K*T=q for the temperature field T
. K
is the heat conduction matrix, q
is the heat flux vector.
Return: T
Types:
K
: SystemMatrixq
: ScalarFieldT
: ScalarField
- 5Bathe, K. J.: Finite element procedures, Wiley, 1983, https://doi.org/10.1002/nag.1610070412