This is machine translation

Translated by Microsoft
Mouseover text to see original. Click the button below to return to the English version of the page.

Note: This page has been translated by MathWorks. Click here to see
To view all translated materials including this page, select Country from the country navigator on the bottom of this page.

TransientThermalResults

Transient thermal solution and derived quantities

Description

A TransientThermalResults object contains the temperature and gradients values in a form convenient for plotting and postprocessing.

The temperature and its gradient are calculated at the nodes of the triangular or tetrahedral mesh generated by generateMesh. Temperature values at the nodes appear in the Temperature property. The solution times appear in the SolutionTimes property. The three components of the temperature gradient at the nodes appear in the XGradients, YGradients, and ZGradients properties. The array dimensions of Temperature, XGradients, YGradients, and ZGradients let you extract solution and gradient values for specified time indices.

To interpolate the temperature or its gradient to a custom grid (for example, specified by meshgrid), use interpolateTemperature or evaluateTemperatureGradient.

To evaluate heat flux of a thermal solution at nodal or arbitrary spatial locations, use evaluateHeatFlux. To evaluate integrated heat flow rate normal to specified boundary, use evaluateHeatRate.

Creation

Solve a transient thermal problem using the solve function. This function returns a transient thermal solution as a TransientThermalResults object.

Properties

expand all

Finite element mesh, returned as a FEMesh Properties object.

Temperature values at nodes, returned as a vector or matrix.

Solution times, returned as a real vector. SolutionTimes is the same as the tlist input to solve.

Data Types: double

x-component of the temperature gradient at nodes, returned as a vector or matrix.

Data Types: double

y-component of the temperature gradient at nodes, returned as a vector or matrix.

Data Types: double

z-component of the temperature gradient at nodes, returned as a vector or matrix.

Data Types: double

Object Functions

evaluateHeatFluxEvaluate heat flux of a thermal solution at nodal or arbitrary spatial locations
evaluateHeatRateEvaluate integrated heat flow rate normal to specified boundary
evaluateTemperatureGradientEvaluate temperature gradient of a thermal solution at arbitrary spatial locations
interpolateTemperatureInterpolate temperature in a thermal result at arbitrary spatial locations

Examples

collapse all

Solve a 2-D transient thermal problem.

Create a transient thermal model for this problem.

thermalmodel = createpde('thermal','transient');

Create the geometry and include it in the model.

SQ1 = [3; 4; 0; 3; 3; 0; 0; 0; 3; 3];
D1 = [2; 4; 0.5; 1.5; 2.5; 1.5; 1.5; 0.5; 1.5; 2.5];
gd = [SQ1 D1];
sf = 'SQ1+D1';
ns = char('SQ1','D1');
ns = ns';
dl = decsg(gd,sf,ns);
geometryFromEdges(thermalmodel,dl);
pdegplot(thermalmodel,'EdgeLabels','on','FaceLabels','on')
xlim([-1.5 4.5])
ylim([-0.5 3.5])
axis equal

For the square region, assign these thermal properties:

  • Thermal conductivity is .

  • Mass density is .

  • Specific heat is .

thermalProperties(thermalmodel,'ThermalConductivity',10, ...
                               'MassDensity',2, ...
                               'SpecificHeat',0.1, ...
                               'Face',1);

For the diamond region, assign these thermal properties:

  • Thermal conductivity is .

  • Mass density is .

  • Specific heat is .

thermalProperties(thermalmodel,'ThermalConductivity',2, ...
                               'MassDensity',1, ...
                               'SpecificHeat',0.1, ...
                               'Face',2);

Assume that the diamond-shaped region is a heat source with a density of .

internalHeatSource(thermalmodel,4,'Face',2);

Apply a constant temperature of to the sides of the square plate.

thermalBC(thermalmodel,'Temperature',0,'Edge',[1 2 7 8]);

Set the initial temperature to .

thermalIC(thermalmodel,0);

Mesh the geometry.

generateMesh(thermalmodel);

The dynamics for this problem are very fast. The temperature reaches a steady state in about 0.1 second. To capture the interesting part of the dynamics, set the solution time to logspace(-2,-1,10). This command returns 10 logarithmically spaced solution times between 0.01 and 0.1.

tlist = logspace(-2,-1,10);

Solve the equation.

thermalresults = solve(thermalmodel,tlist)
thermalresults = 
  TransientThermalResults with properties:

      Temperature: [1481x10 double]
    SolutionTimes: [1x10 double]
       XGradients: [1481x10 double]
       YGradients: [1481x10 double]
       ZGradients: []
             Mesh: [1x1 FEMesh]

Plot the solution with isothermal lines by using a contour plot.

T = thermalresults.Temperature;
pdeplot(thermalmodel,'XYData',T(:,10),'Contour','on','ColorMap','hot')

Introduced in R2017a