wiki:examples:multiscale-heat-transfer-demo

This example demonstrates a multiscale approach for solving stationary heat transfer on a perforated ceramic sheet. Due to a periodic sheet structure, it is advantageous to separate two scales:

**Macroscale**- the ceramic sheet has dimensions 400 x 200 mm and contains circular holes, see figure below. Heat transfer model simplifies such a heterogeneous morphology to a homogeneous continuum using an effective conductivity coming from a microscale.**Microscale**- a representative volume element (RVE) captures morphology of ceramic sheet with a circular hole. RVE size is 2 x 2 mm. Effective conductivity of RVE is determined.

Microscale simulation considers RVE with a temperature gradient in *x* direction, assigning 0^{o}C to the left edge and 1^{o}C to the right edge. Solution of heat balance equation via finite elements provides temperature field on figure below. The RVE uses a regular structured mesh of 40 x 40 quadrilateral elements which yields 1599 equations for unknown temperature field. Heat conductivity is assigned as 1.0 W/m/K for solid elements. The effective conductivity is obtained by calculating heat flow on the right edge and from assigned boundary temperatures. The effective conductivity yields 0.314 W/m/K from the RVE and computation time is about 2.0 s.

Effective conductivity from the microscale is passed to the macroscale. Macroscale has dimensions 400 x 200 mm and is discretized into 40 x 20 finite elements, yielding 840 equations for unknown temperature field. Solution time is about 1.0 s. Figure below shows discretization and the resulting temperature field.

The MuPIF control script for this simulation is showed below. It can be also found under examples/Example12/Demo12.py on MuPIF installation.

import sys sys.path.append('../../..') from mupif import * from mupif import logger #Import module Example10/demoapp.py sys.path.append('../Example10') import demoapp #Read geometry and boundary condition for the microscale thermalMicro = demoapp.thermal('thermalMicro.in','') logger.info(thermalMicro.getApplicationSignature()) #Solve the microscale problem thermalMicro.solveStep(None) #Get effective conductivity from the microscale effConductivity = thermalMicro.getProperty(PropertyID.PID_effective_conductivity,0.0) logger.info('Computed effective conductivity from microscale: %f' % effConductivity.value) #Dump microscale results to VTK files thermalMicroField = thermalMicro.getField(FieldID.FID_Material_number, 0.0) thermalMicroField.field2VTKData().tofile('thermalMicroMaterial') thermalMicroField = thermalMicro.getField(FieldID.FID_Temperature, 0.0) thermalMicroField.field2VTKData().tofile('thermalMicroT') #Read geometry and boundary condition for the macroscale thermalMacro = demoapp.thermal('thermalMacro.in','') #Assign effective conductivity for the whole macroscale domain thermalMacro.setProperty(effConductivity) thermalMacro.solveStep(None) thermalMacroField = thermalMacro.getField(FieldID.FID_Temperature, 0.0) #Dump macroscale results to VTK files thermalMacroField.field2VTKData().tofile('thermalMacroT')

wiki/examples/multiscale-heat-transfer-demo.txt · Last modified: 2018/06/22 14:31 (external edit)