Thermal model object
ThermalModel object contains information
about a heat transfer problem: the geometry, material properties, internal heat sources,
temperature on the boundaries, heat fluxes through the boundaries, mesh, and initial
ThermalModel object using
createpde with the first argument
AnalysisType— Type of thermal analysis
Type of thermal analysis, returned as
Geometry— Geometry description
Geometry description, returned as a geometry object.
MaterialProperties— Material properties within the domain
Material properties within the domain, returned as an object containing the material property assignments.
HeatSources— Heat source within the domain or subdomain
Heat source within the domain or subdomain, returned as an object containing heat source assignments.
BoundaryConditions— Boundary conditions applied to the geometry
Boundary conditions applied to the geometry, returned as an object containing the boundary condition assignments.
InitialConditions— Initial temperature or initial guess
Initial temperature or initial guess, returned as an object containing the initial temperature assignments within the geometric domain.
StefanBoltzmannConstant— Constant of proportionality in Stefan-Boltzmann law governing radiation heat transfer
Constant of proportionality in Stefan-Boltzmann law governing radiation heat transfer, returned as a number. This value must be consistent with the units of the model. Values of the Stefan-Boltzmann constant in commonly used system of units are:
SI – 5.670367e-8 W/(m2·K4)
CGS – 5.6704e-5 erg/(cm2·s·K4)
US customary – 1.714e-9 BTU/(hr·ft2·R4)
SolverOptions— Algorithm options for PDE solvers
Algorithm options for the PDE solvers, returned as a PDESolverOptions Properties object. The
PDESolverOptions include absolute and
relative tolerances for internal ODE solvers, maximum solver iterations, and
|Create 2-D geometry|
|Create geometry from mesh|
|Import geometry from STL data|
|Assign thermal properties of a material for a thermal model|
|Specify internal heat source for a thermal model|
|Specify boundary conditions for a thermal model|
|Set initial conditions or initial guess for a thermal model|
|Create triangular or tetrahedral mesh|
|Solve heat transfer or structural analysis problem|
Create a transient thermal model container.
thermalmodel = createpde('thermal','transient')
thermalmodel = ThermalModel with properties: AnalysisType: 'transient' Geometry:  MaterialProperties:  HeatSources:  StefanBoltzmannConstant:  BoundaryConditions:  InitialConditions:  Mesh:  SolverOptions: [1x1 PDESolverOptions]
Create the geometry and include it in the model.
g = @squareg; geometryFromEdges(thermalmodel,g)
ans = AnalyticGeometry with properties: NumCells: 0 NumFaces: 1 NumEdges: 4 NumVertices: 4
Assign material properties.
thermalProperties(thermalmodel,'ThermalConductivity',79.5,... 'MassDensity',7850,... 'SpecificHeat',450,... 'Face',1)
ans = ThermalMaterialAssignment with properties: RegionType: 'face' RegionID: 1 ThermalConductivity: 79.5000 MassDensity: 7850 SpecificHeat: 450
Specify that the entire geometry generates heat at the rate 25 W/m^3.
ans = HeatSourceAssignment with properties: RegionType: 'face' RegionID: 1 HeatSource: 25
Apply insulated boundary conditions on three edges and the free convection boundary condition on the right edge.
thermalBC(thermalmodel,'Edge',[1,3,4],'HeatFlux',0); thermalBC(thermalmodel,'Edge',2,... 'ConvectionCoefficient',5000,... 'AmbientTemperature',25)
ans = ThermalBC with properties: RegionType: 'Edge' RegionID: 2 Temperature:  HeatFlux:  ConvectionCoefficient: 5000 Emissivity:  AmbientTemperature: 25 Vectorized: 'off'
Set the initial conditions: uniform room temperature across domain and higher temperature on the left edge.
ans = GeometricThermalICs with properties: RegionType: 'edge' RegionID: 4 InitialTemperature: 100
Specify the Stefan-Boltzmann constant.
thermalmodel.StefanBoltzmannConstant = 5.670367e-8;
ans = FEMesh with properties: Nodes: [2x1541 double] Elements: [6x734 double] MaxElementSize: 0.1131 MinElementSize: 0.0566 MeshGradation: 1.5000 GeometricOrder: 'quadratic'
thermalmodel now contains the following properties.
thermalmodel = ThermalModel with properties: AnalysisType: 'transient' Geometry: [1x1 AnalyticGeometry] MaterialProperties: [1x1 MaterialAssignmentRecords] HeatSources: [1x1 HeatSourceAssignmentRecords] StefanBoltzmannConstant: 5.6704e-08 BoundaryConditions: [1x1 ThermalBCRecords] InitialConditions: [1x1 ThermalICRecords] Mesh: [1x1 FEMesh] SolverOptions: [1x1 PDESolverOptions]