thermalmodel = createpde('thermal','transient');
gm = importGeometry(thermalmodel,'heatsinkv2.stl');
pdegplot(thermalmodel,'FaceLabel','on','FaceAlpha',0.5);
axis equal
generateMesh(thermalmodel);
figure;
pdeplot3D(thermalmodel);
TCval = @(location,state)139.3 + 0.204*(state.u-273.15);
MDval = 2770;
SHval = 875;
ATval = 25+273.15;
CCval = 30;
REval = 0.77;
thermalmodel.StefanBoltzmannConstant = 5.670373E-8;
faces = [1,3:30];
thermalProperties(thermalmodel,'ThermalConductivity',TCval,'MassDensity',MDval,'SpecificHeat',SHval);
thermalBC(thermalmodel,'Face',faces,'ConvectionCoefficient',@(region,state)CCval,'Emissivity',@(region,state)REval,'AmbientTemperature',ATval);
thermalBC(thermalmodel,'Face',2,'ConvectionCoefficient',5,'Emissivity',0.1,'AmbientTemperature',ATval);
thermalIC(thermalmodel,60+273.15);
tlist= [0:10];
thermalTransientResults = solve(thermalmodel,tlist);
pdeplot3D(thermalmodel,'ColorMapData',thermalTransientResults.Temperature(:,10)-273.15)
Best Answer