Examples / 05

Simulation instead of a test rig: a heat sink designed with Gaussian processes

When the runs take place in a simulation program, what makes a good design changes. There is no scatter that would need replicates, but every run costs computing time. Here five settings of a heat sink are spread over the whole region in 40 simulations, a Gaussian process (kriging) learns three responses from them, and desirability finds the sweet spot. Three prototypes built and measured in the wind tunnel show at the end how far the simulation can be trusted.

Design
MaxPro, 40 simulations + 2 for sharpening
Model
Gaussian process, Matérn 5/2
Factors
5 geometry and flow settings
Responses
3, confirmed with 3 prototypes

Simulator and prototypes are emulated. Instead of a flow solver, a model built from textbook formulas for fin efficiency, heat transfer and pressure drop does the computing — not linear, without scatter, like a real simulator. The wind-tunnel measurements are the same formulas with a systematic offset and measurement scatter. That makes it possible to check at the end what the Gaussian process has learned. Every table and chart was computed and drawn by DoEStat.

Step 1 / The question

One heat sink, three limits

A power module with a 100 × 100 mm footprint is to be cooled by an aluminium finned heat sink with a fan blowing through it. The design is done in a thermal simulation; one run takes a good quarter of an hour, 40 runs fit into one night. Three quantities decide the design:

  • Thermal resistance from the module to the air — to be minimised, at most 0.35 K/W
  • Pressure drop across the heat sink — to be minimised, at most 60 Pa, or the fan cannot cope
  • Mass — to be minimised, at most 450 g

The three pull against each other: tall, closely spaced fins cool well but cost mass and pressure; more air cools better and costs pressure too. Five settings are free:

FactorUnitfromto
Fin heightmm20.060.0
Fin thicknessmm1.003.00
Fin gapmm2.008.00
Air flowm³/h10.040.0
Base thicknessmm4.012.0

Step 2 / Design

40 points that fill the region

A classical design is the wrong choice here. A central composite design puts its points on corners, faces and the centre, so it knows only three levels per factor, and it replicates the centre to estimate scatter. A simulator, however, returns the same number for the same input every time; every replicate would be wasted computing time. And whether the surfaces behave like a second-order polynomial nobody knows beforehand.

A space-filling design spreads the runs evenly over the interior instead. DoEStat offers several families for this. The one chosen is MaxPro (Joseph, Gul and Ba, 2015): the points are well spread not only in the five-dimensional region but also in every projection onto two, three or four factors. That matters as soon as a factor turns out to have no effect — then points fall onto each other in other designs, and the information shrinks.

MetricMaxPro, 40 (chosen)Sphere packing, 40Maximin Latin hypercube, 40Central composite, 43
MaxPro criterion ψ (projections, smaller is better)23.06∞144.00∞
Smallest distance between two points (unit cube)0.4250.8660.2970.500
Coverage radius (largest gap)0.7200.7510.7130.642
Largest column correlation |r|0.1080.0270.2050.000
Distinct levels per factor407403

The design evaluation shows the difference. Sphere packing keeps the largest minimum distance in the full region but uses only seven distinct values per factor for it. The central composite design has three. In both, points coincide in a projection, and the MaxPro criterion is infinite. MaxPro and the Latin hypercube have 40 distinct values per factor, but MaxPro spreads them far better in the projections.

Scatter-plot matrix of the 40 simulations over the five factors in coded units: in each of the ten pairs the points are spread evenly, without clusters or gaps, and every factor has 40 distinct values.
The design in every projectionEvery pair of factors is covered evenly, and no two points share a value.

Step 3 / Simulation

One night of computing

The design goes to the simulation as a table, and the results come back into the same table. In DoEStat a simulator can also be connected directly: a Python script receives the settings of a run and returns the responses; the runs then fill the data table without a detour through files.

What stands out in the results is their range: the thermal resistance runs from 0.20 to 1.10 K/W, the mass from 200 to almost 1,200 g, the pressure drop from under one to 70 Pa. The physics behind it is not linear — the efficiency of a fin follows a hyperbolic tangent, the pressure drop the square of the flow velocity.

And none of the 40 simulations keeps all three limits at once. Anyone simply taking the best run from the table would have nothing usable. The sweet spot lies between the points — where only a model can look.

All simulations
RunFin height [mm]Fin thickness [mm]Fin gap [mm]Air flow [m³/h]Base thickness [mm]Thermal resistance [K/W]Pressure drop [Pa]Mass [g]
160.02.815.0138.69.10.382910.92858.1
222.31.424.6234.59.60.539441.92408.2
337.72.726.4123.411.90.65838.06643.2
420.61.055.4424.84.00.707320.92202.9
553.52.033.1032.210.00.298514.01859.9
644.11.332.0016.910.90.275611.18779.2
728.01.003.5830.011.70.414222.43486.6
845.02.457.8711.29.50.81111.20568.8
957.91.625.3420.711.30.44702.66686.8
1020.01.197.9939.112.00.771545.34399.6
1156.32.997.2628.110.50.55525.00759.9
1229.92.212.1224.49.30.349245.68672.3
1351.51.036.2213.310.30.56791.15487.1
1459.91.437.5010.04.10.64390.51387.9
1537.31.172.5233.74.80.287126.32455.9
1628.82.346.9314.84.60.91274.96335.4
1743.12.115.8026.87.70.53487.57536.1
1850.92.682.0237.34.00.250648.54907.6
1942.02.932.8140.011.40.312148.23903.5
2032.71.856.7437.710.70.590920.32491.3
2123.42.067.4018.011.50.96869.64458.5
2220.13.002.2918.96.60.534769.66492.3
2355.62.244.2316.36.90.43773.00728.2
2426.21.585.9739.95.20.582235.18297.6
2548.71.932.6710.45.80.38413.64721.9
2632.32.793.2127.85.40.442632.31563.8
2724.61.713.3613.98.50.593310.66462.7
2840.61.503.7222.66.30.41348.20495.0
2949.51.307.1435.66.70.51586.95402.1
3025.22.657.7631.57.10.814126.15379.8
3158.42.426.3033.15.70.46746.29618.1
3239.12.974.4412.14.20.64393.77553.9
3335.82.513.9736.18.10.422030.08609.0
3452.42.888.0020.15.00.67812.78539.6
3559.32.552.3912.512.00.32735.301169.1
3634.81.107.6321.28.80.73494.76366.2
3730.91.225.0610.97.30.69882.60367.4
3821.32.865.7210.110.81.10175.98494.0
3957.41.012.2139.67.50.204718.93701.2
4046.71.754.8730.54.40.43628.75469.3
4131.81.002.0029.64.00.272435.64400.0
4240.41.002.7939.74.00.281124.58404.0

The last two rows are the runs from sharpening (step 6).

Step 4 / Gaussian process

A model that passes through every point

For simulation data one chooses the modelling strategy kriging in DoEStat. A Gaussian process assumes no polynomial. It assumes that settings close to each other give similar results, and estimates from the data how fast that similarity fades with distance — for each factor separately. Because the simulator does not scatter, the surface passes exactly through every computed point. In between it predicts not only a value but also how sure it is.

ResponseCorrelation functionProcess standard deviation σLOO RMSEQ² (leave-one-out)Quadratic polynomial: pred. R²
Thermal resistance [K/W]Matérn 5/2, one length scale per factor0.7500.01820.99220.9774
Pressure drop [Pa]Matérn 5/2, one length scale per factor60.55.020.90930.7936
Mass [g]Matérn 5/2, one length scale per factor20612.710.99980.9885

For an interpolator, quality is not measured with R² — that would always be 1. Instead every run is left out once and predicted from the others (leave-one-out). Q² is the share of the variation these predictions explain. For comparison, the table shows what a quadratic polynomial achieves on the same data in the same test.

What the process has learned about the factors

The estimated length scales say over what distance (in coded units; the range is 2 wide) a response changes noticeably along a factor. A small number means sensitive. A very large one means the surface is flat in that direction — the factor has no effect.

FactorThermal resistance [K/W]Pressure drop [Pa]Mass [g]
Fin height3.462.259.29
Fin thickness15.387.2010.56
Fin gap5.951.866.44
Air flow3.694.011000.00
Base thickness205.681000.0051.83

The physics can be recognised in it without anyone having specified it: the base thickness hardly matters for pressure drop and thermal resistance, but very much for the mass. The air flow acts on heat and pressure and does not affect the mass. The importance per factor makes this tangible as a share of the surface's variation:

FactorThermal resistance: main effectThermal resistance: totalPressure drop: main effectPressure drop: totalMass: main effectMass: total
Fin height24.9%28.2%31.1%43.0%36.2%40.0%
Fin thickness1.6%1.9%3.0%5.8%17.9%19.8%
Fin gap55.4%57.8%21.9%31.7%26.8%29.4%
Air flow14.0%16.2%26.5%36.8%0.0%0.0%
Base thickness0.0%0.0%0.0%0.0%15.0%15.0%

“Main effect” is the share a factor explains on its own; “total” includes its interplay with the others. For the pressure drop, “total” lies well above the main effect: fin height, fin gap and air flow act together there on the flow velocity. The values are Monte Carlo estimates over the region and scatter by a few percentage points: they are good enough for the ranking of the factors, not for the decimal place.

Contour plot of the thermal resistance over fin height 20 to 60 millimetres and fin gap 2 to 8 millimetres: the resistance rises steeply with the gap and falls with the height; the sweet spot is marked at 39 millimetres height and 2.7 millimetres gap, the simulation points are drawn in grey.
Thermal resistance: height × gapClose fins cool, and so do tall ones. The grey circles are the simulations — they do not lie in the cut but near it.
Contour plot of the Gaussian process standard error for the thermal resistance in the same cut: below 0.004 kelvin per watt in the middle and near the simulation points, up to 0.017 in the corners of the region; the minimum lies at the sweet spot, because sharpening took place there.
Where the process is sureThe standard error of the prediction in the same cut. It is small where runs were computed and grows towards the corners — smallest at the sweet spot, where sharpening took place.
Three-dimensional surface of the thermal resistance over fin height and fin gap: a slightly curved surface rising from 0.2 for tall, closely spaced fins to 0.8 for short, widely spaced ones.
The surfaceNot linear but smooth — the Gaussian process needs no model form chosen in advance for it.
Prediction profiler of the thermal resistance over all five factors at the sweet spot, each with a 95 per cent band: rising steeply with the fin gap, falling with fin height and air flow, flat for fin thickness and base.
Profiler at the sweet spotAll five factors at a glance; the band is the uncertainty of the process. The fin gap dominates, the base is flat.

Step 5 / Diagnostics

How far does the model carry?

An interpolator has no residuals in the usual sense — at the design points it hits exactly. Diagnostics therefore work through the leave-one-out predictions: for every run the deviation of the prediction from the other runs, divided by the standard error the process gives itself for it. If that self-assessment is right, these standardised residuals lie around zero like a standard normal distribution, with only about one value in twenty beyond ±2.

Standardised leave-one-out residuals of the thermal resistance against the leave-one-out prediction.
Leave-one-out: thermal resistanceEvery run predicted from the others, divided by the standard error.
Standardised leave-one-out residuals of the pressure drop against the leave-one-out prediction from minus 5 to 52 pascal.
Leave-one-out: pressure dropThe hardest response. At the lower left the process even predicts negative values.

It is not quite right. For the thermal resistance, four of the 42 values lie beyond ±2, one at almost 5; for the pressure drop there are three. The largest of each belongs to an extreme of the design: run 38 has the highest thermal resistance at 1.10 K/W (short fins, wide gap, little air), run 22 the highest pressure drop at 70 Pa — the only one above the limit. Leaving out such a run forces the process to extrapolate into a corner, and there it underestimates its uncertainty.

Two things follow. First, the emulator's band is a lower bound of the uncertainty, not its measure — at the edge of the region in particular. Second, the sweet spot lies far from these corners, in a region the design covers well. Whether the emulator is right there can be checked directly, and that happens in step 6. For the pressure drop, there is also the fact that some predictions in the lower range fall below zero — physically impossible. It is the hardest of the three responses: it grows with the square of the velocity and has its steepest slopes exactly where things get interesting.

Pressure drop and mass in a cut
Contour plot of the pressure drop over fin gap and air flow at the sweet spot: the pressure drop rises steeply for close fins and much air.
Pressure drop: gap × air flowSteep where the fins stand close and much air has to pass.
Contour plot of the mass over fin height and fin thickness at the sweet spot: the mass grows with both, most when tall and thick fins come together.
Mass: height × thicknessThin fins save the most.

Step 6 / Sweet spot

Three limits, one window

Desirability translates every response into a number between 0 (at the limit) and 1 (as good as needed) and looks for the setting at which the weighted mean is largest. Thermal resistance counts three times, pressure drop twice and mass once. The optimisation runs directly on the surfaces of the Gaussian process.

Sharpen first, then build

An optimum on an emulator is a prediction. Before anything is built, the simulator is run at exactly this setting — that costs a quarter of an hour and tells whether the emulator is right there. If it is off, the run joins the data, the process is refitted, and the search starts again. Here two additional simulations were needed for that:

RoundOverall desirability DThermal resistance: emulator ± SEThermal resistance: simulationPressure drop: emulator ± SEPressure drop: simulationMass: emulator ± SEMass: simulation
10.3980.2702 ± 0.00630.272431.85 ± 2.4335.64401.0 ± 3.2400.0
20.4030.2747 ± 0.00690.281125.96 ± 1.9324.58406.6 ± 1.4404.0
30.3970.2779 ± 0.00200.279224.89 ± 0.2824.86407.6 ± 0.2407.0

In the first round the pressure drop came out 3.8 Pa above the prediction — a good one and a half standard errors, not surprising in this steep region. With the new point, the optimum moves to more air and a slightly wider fin gap. After the third round, emulator and simulator agree to within one per cent; the search is complete.

FactorSettingUnitcoded
Fin height39.40mm−0.03
Fin thickness1.000mm−1.00
Fin gap2.652mm−0.78
Air flow37.53m³/h0.84
Base thickness4.00mm−1.00
ResponseGoalEmulator predictionEmulator 95% bandDesirability dSimulation at the setting
Thermal resistance [K/W]minimise, at most 0.350.27790.2740 … 0.28180.3610.2792
Pressure drop [Pa]minimise, at most 6024.8924.34 … 25.440.70224.86
Mass [g]minimise, at most 450407.6407.2 … 408.10.170407.0
Overall desirability D0.397

The sweet spot has 1 mm thin fins and a 4 mm base — both at their lower limit, because they only cost mass and hardly cool. The 28 fins stand 2.7 mm apart and are 39 mm tall, and the fan delivers 37.5 m³/h. The lowest individual desirability belongs to the mass (0.17): every millimetre of fin height that lowers the thermal resistance adds aluminium. What binds the overall result, though, is the thermal resistance — it counts three times, so DoEStat names it at the optimum as the goal holding D down the most.

All three responses in one picture

The overlaid view shows the latitude around the sweet spot: the contour lines of every response in its colour, the limits as heavy dashed lines, and shaded the region where all three are kept.

Overlaid contour plot over fin height and fin gap with the contour lines of all three responses; a slanted yellow band is feasible, bounded at the top by thermal resistance equals 0.35 and at the bottom by mass equals 450; the sweet spot lies in the middle of the band.
Fin height × fin gapThermal resistance limits at the top, mass at the bottom: taller fins have to stand further apart.
Overlaid contour plot over fin gap and air flow with the contour lines of all three responses; the feasible region lies at a small gap and much air, bounded by the thermal resistance and the pressure drop.
Fin gap × air flowMore air cools until the pressure drop reaches its limit.
Overlaid contour plot over fin height and air flow with the contour lines of all three responses; a large part of the cut is feasible, and the sweet spot lies at 39 millimetres and 37.5 cubic metres per hour.
Fin height × air flowThe most generous cut: a third of it keeps all three limits.

Where the next simulation would go

Anyone who wants to keep computing gets two suggestions from the Gaussian process: the point where it is least sure, and the point most likely to push the thermal resistance below the best so far (expected improvement). Both lie in corners of the region — the first because least is known there, the second because it looks only at the thermal resistance and knows nothing of pressure and mass. For the design, desirability therefore remains decisive.

SuggestionFin height [mm]Fin thickness [mm]Fin gap [mm]Air flow [m³/h]Base thickness [mm]PredictionStandard errorCriterion
Largest uncertainty20.01.008.0010.04.01.20360.0250max. standard error: 0.0250
Largest expected improvement60.01.002.0040.012.00.18040.0062expected improvement (EI): 0.0243

Step 7 / Validation

Three prototypes in the wind tunnel

The emulator reproduces what the simulator computes. Whether the simulator matches reality is a different question, and only an experiment answers it. Three heat sinks are milled to the sweet-spot geometry and measured in the wind tunnel at 37.5 m³/h:

ResponseSimulationPrototype 1Prototype 2Prototype 3Measured meanDeviationLimit
Thermal resistance [K/W]0.2790.2870.2950.3050.296+5.9%≤ 0.35
Pressure drop [Pa]24.925.128.726.126.6+7.1%≤ 60
Mass [g]407408406406407−0.1%≤ 450

Result: all three limits are kept on all three prototypes. The simulation is, however, measurably optimistic: the thermal resistance is 6% higher, the pressure drop 7% — the contact resistance under the module and the roughness of the milled channels are in no simulation model. The mass is right. The margin to the limit that desirability left was therefore needed.

Summing up

What the simulation achieved

42 simulations and three prototypes for five factors and three responses. A prototype programme answering the same question in the wind tunnel would have needed 43 milled heat sinks with a central composite design — and with three levels per factor would have captured the curvature of the pressure drop only roughly.

The space-filling design gave the Gaussian process the information it needs: many distinct values per factor and good projections, so that two practically inactive directions cost nothing. From that, the process recognised on its own which factor counts for which response, and stated where it is sure. Sharpening cost two quarter-hours of computing and brought the prediction at the sweet spot from “roughly” to “within one per cent”.

Against the truth: here the simulator is the truth, and the column “Simulation at the setting” in the optimisation table shows it: at the sweet spot the emulator is off by no more than one per cent for any response. What the prototypes show in addition no emulator can learn — the gap between simulation model and reality. For that, confirmation on the real part remains indispensable.

Project files

Run it yourself

The example ships with DoEStat as a project: Help ▸ Open sample project ▸ Other ▸ “Simulation with a Gaussian process: heat sink”, once with the data only and once with the finished analysis. The same files can be downloaded here.

Back: from screening to a response surface Next: categorical responses

Try DoEStat for free

30 days, the full feature set, no payment details. We send the download link by e-mail, usually on the next business day.

Request the trial