Skip to article frontmatterSkip to article content
Site not loading correctly?

This may be due to an incorrect BASE_URL configuration. See the MyST Documentation for reference.

Solutions · 1. Dimensional analysis: the Buckingham Pi theorem and Taylor’s estimate of the Trinity yield

School of Engineering, Nazarbayev University

Worked solutions to the three exercises of Lecture 1. Each solution is computed here and checked with assert statements against an exact identity or an independent calculation. The first code cell sets up the notebook and runs Demonstration 1 of the lecture without showing its output, because some of the solutions use its variables.

Exercise 1

Problem. Use representation_scaling.buckingham_pi_nullspace on (T_period, L, m, g) and CANONICAL_DIM_MATRICES['capillary_droplet_oscillation'], and verify numerical invariance of the capillary Π\Pi-groups across SI, CGS, and Imperial (slug, ft, s) unit systems.


Exercise 1: Pendulum mass independence, capillary droplets and multi-unit invariance
====================================================================================
Pendulum Pi group: ['T_period^2 * g / (L)'] | Exponents: [[2, -1, 0, 1]]
Capillary Droplet Pi groups: ['sigma / (omega^2 * R^3 * rho)', 'mu / (omega * R^2 * rho)']
  SI (kg, m, s)            -> Pi values = [0.027017   0.00055667]
  CGS (g, cm, s)           -> Pi values = [0.027017   0.00055667]
  Imperial (slug, ft, s)   -> Pi values = [0.027017   0.00055667]

Explanation. Because mass MM appears only in column m of the pendulum matrix ([0, 0, 1, 0]), Dπ=0\mathbf{D}\boldsymbol{\pi} = \mathbf{0} forces 1⋅πm=01 \cdot \pi_m = 0, proving without solving Newton’s ODE that Tg/L=constT \sqrt{g/L} = \text{const} is independent of mass even at large amplitudes θ0\theta_0. For capillary droplets, scaling base units multiplies q\mathbf{q} by sidijs_i^{d_{ij}}, which cancels identically via ∑jdijπj=0\sum_j d_{ij} \pi_j = 0.


Exercise 2

Problem. Audit (a) omitting gravity gg in free-surface ship hull scaling (1:25 tow-tank test of a 150 m150\,\mathrm{m} ship cruising at 10 m/s10\,\mathrm{m/s}), and (b) adding a redundant Force row (Force = M L T^-2) to a 4-variable Hookean spring-mass matrix where naive n−m=0n - m = 0 fails.


Exercise 2: Missing Froude number in ship wave drag and redundant base dimensions (rank < m)
============================================================================================
Without g groups : ['rho * U^2 * L^2 / (F)', 'mu^2 / (F * rho)']
With g groups    : ['rho * U^2 * L^2 / (F)', 'mu^2 / (F * rho)', 'F * g^2 / (rho * U^6)']
1:25 Tow Tank: Re-matching speed = 250.0 m/s (Fr = 32.59 vs ship Fr = 0.261)
Froude-matched tow speed         = 2.00 m/s (William Froude's residual-wave-drag law)

Redundant 4x4 matrix: naive (n - m) = 0 groups, TRUE rank = 3 -> 1 Pi group: ['k_s / (omega^2 * m)']

Explanation. Omitting gg silently assumes surface gravity waves carry zero energy, and leads to towing a 6 m6\,\mathrm{m} model at 250 m/s250\,\mathrm{m/s} (Fr=32.6\mathrm{Fr} = 32.6 against 0.26 for the ship); matching Fr\mathrm{Fr} gives 2.00 m/s2.00\,\mathrm{m/s}. In part (b), Buckingham’s theorem is p=n−rank⁡(D)p = n - \operatorname{rank}(\mathbf{D}), never n−mn - m; linearly dependent dimensional rows reduce rank⁡(D)<m\operatorname{rank}(\mathbf{D}) < m, which exact RREF detects automatically.


Exercise 3

Problem. Implement nondimensional_data_collapse_fitter(dim_matrix, data_columns, target_col=0, var_names=None) that isolates target_col into Πout\Pi_{\mathrm{out}} (exponent +1) by placing repeating basis variables before target_col, computes all input Πk\Pi_k, and fits Πout=C∏kΠkαk\Pi_{\mathrm{out}} = C \prod_k \Pi_k^{\alpha_k} in log space. Test on synthetic multi-fluid convective heat-transfer data governed by Dittus–Boelter Nu=0.023 Re0.80 Pr0.40\mathrm{Nu} = 0.023\,\mathrm{Re}^{0.80}\,\mathrm{Pr}^{0.40}.


Exercise 3: Implement it yourself — automated Buckingham-Pi power-law data fitter
=================================================================================
Recovered prefactor C            : 0.023000  (Exact Dittus-Boelter = 0.023000)
Log-space collapse R^2           : 1.000000000000
Recovered variable exponents     : [ 0.  -0.2  0.6  0.8  0.8 -0.4  0.4]
Exact Dittus-Boelter exponents   : [ 0.  -0.2  0.6  0.8  0.8 -0.4  0.4]

Summary. By permuting target_col to the rightmost column before rational RREF, Πout\Pi_{\mathrm{out}} automatically isolates the target physical quantity (recovering Nusselt number Nu=hD/k\mathrm{Nu} = h D / k) while Π1,…,p−1\Pi_{1,\dots,p-1} span the dimensionless predictors. Regressing in 2-D (ln⁡Π1,ln⁡Π2)(\ln \Pi_1, \ln \Pi_2) space instead of raw 6-D variable space enforces exact physical unit consistency even when experimental data are noisy or scarce.