CH NEO-ZÜRICH EDITION
WEATHER · OVERCAST 9°C
BLEND OF THE DAY · 07/ROGUE
EST. 2027
THE AEC CYBER MORNING NEWS

PAZ Kaffi

DESIGN · DEMOLITION · CAFFEINE · DISPATCH
EDITION 1115 · 15 November 2026
BROADCAST 04:42 CET
2,400 BROADSHEETS PRINTED
READ TIME · 47 MIN
Three Materials, Two Areas, One Line: A Window's Uw in 64 Lines of Python
ACADEMY
FRAME · 06:55
15-11-2026

Three Materials, Two Areas, One Line: A Window's Uw in 64 Lines of Python

Build a standard-library Python calculator for window Uw from the EnDK Merkblatt Fenster, verify it at 0.96 W/m²K, and see why the spacer decides 1.0.

A window is three materials, two areas and one line. Frame and glass each bring an area and a U-value; the spacer that holds the panes apart brings a length. The window’s U-value, Uw, is their weighted average per square metre of opening. According to the EnDK (Konferenz Kantonaler Energiedirektoren), on page 3 of its Merkblatt Fenster: Uw = (Uf·Af + Ug·Ag + Ψg·l) / Aw, with Aw taken as the clear opening in the wall.

The Merkblatt is the 2021 edition, so this is not news. It is the sheet behind a great many Swiss energy calculations, and most of us still copy a Uw from a supplier’s datasheet without ever watching the three terms move. Today you build the calculator, check it against the Merkblatt’s own worked example, and find out which term you control at design stage and which one arrives on a lorry.

The surprise is the last term. Ψg (psi, the linear thermal transmittance of the glass edge, in W/mK) multiplies a length, not an area. Add a mullion and you add metres of edge. The psi values come from EN ISO 10077-1:2017, as the EnDK reports them; the people who measured them and the editors who turned them into usable tables are rarely named. Their tables are the reason a planner can check a window at all.

←TODAY: A 2021 EnDK sheet, a 1.0 W/m²K line and a spacer marking a few millimetres high decide many Swiss window checks.
→3012: The windows still being repaired in 3012 are the ones whose numbers anyone can recompute from plain text.
Fulcrum: A 64-line script you can read is the cheapest format longevity a practice can own.

The Tool: Python 3’s standard library and one formula. No package, no repo: window_uw.py is 64 lines, written and run by the PAZ editor on 3 November 2026 with Python 3.10.11. Every value comes from the EnDK Merkblatt Fenster 2021, which reproduces the limit table of SIA 380/1:2016 and the spacer table of EN ISO 10077-1:2017. The script touches no Rhino API, so it runs unchanged in the Rhino 8 ScriptEditor, the same editor PAZ uses in its Rhino and Grasshopper courses.

Setup:

python --version        # 3.10 or newer; standard library only
mkdir window-uw
cd window-uw
# save the program below as window_uw.py, then:
python window_uw.py     # on Windows also: py window_uw.py

First steps:

  1. Save the program below as window_uw.py in the empty folder.
  2. Run it. The first line must end in Uw 0.96 W/m2K (Merkblatt prints 0.96). If it does not, stop: a frame width is mistyped.
  3. Replace the frame widths in VARIANTS with the ones on your window maker’s section drawing and run it again.

The code, explained:

# window_uw.py - window U-value (Uw) from frame, glass and spacer, checked against the Swiss limits
# Standard library only. Lengths in m, U in W/m2K, psi in W/mK. Formula and values: EnDK Merkblatt Fenster 2021.

def window(W, H, side, top, bottom, mullion=0.0, sashes=2):
    """Net opening W x H; frame widths per edge; returns Aw, Ag, Af, glass-edge length lg."""
    gw = (W - 2 * side - (sashes - 1) * mullion) / sashes   # glass width per sash
    gh = H - top - bottom                                     # glass height
    Aw, Ag = W * H, sashes * gw * gh
    return Aw, Ag, Aw - Ag, sashes * 2 * (gw + gh)

def uw(Uf, Ug, psi, geo):
    Aw, Ag, Af, lg = geo
    return (Uf * Af + Ug * Ag + psi * lg) / Aw

def limit(theta_i=20.0, against="outside"):
    """SIA 380/1:2016 Uli for windows; 5 % per K away from 20 C, never below the 0.80 target value."""
    base = 1.0 if against == "outside" else 1.3
    return max(0.80, base * (1 - 0.05 * (theta_i - 20)))

# Self-check: the Merkblatt's own worked example (balcony door 1.40 x 2.04 m, wood-alu)
ex = window(1.40, 2.04, side=0.05, top=0.05, bottom=0.18, mullion=0.12)
print(f"Merkblatt example: Aw {ex[0]:.2f} Ag {ex[1]:.3f} Af {ex[2]:.2f} m2, lg {ex[3]:.2f} m"
      f" -> Uw {uw(1.2, 0.7, 0.04, ex):.2f} W/m2K (Merkblatt prints 0.96)")

# The proof window: 2-sash Normfenster 1.55 x 1.15 m. Frame widths are EXAMPLE inputs.
VARIANTS = {"slim frame":   window(1.55, 1.15, side=0.065, top=0.065, bottom=0.08, mullion=0.09),
            "chunky frame": window(1.55, 1.15, side=0.10, top=0.10, bottom=0.12, mullion=0.12)}
for name, (Aw, Ag, Af, lg) in VARIANTS.items():
    print(f"Normfenster 1.55 x 1.15 m, {name}: glass share {Ag / Aw:.0%}, edge {lg:.2f} m")

FRAMES = {"wood / wood-alu": 1.4, "PVC": 1.9, "insulated metal": 2.5}     # Rechenwerte Uf
SPACERS = {"aluminium": 0.08, "warm edge 0.04": 0.04}   # 0.08 = table value, 0.04 = declared

print(f"\n{'frame':<17}{'Uf':>5}{'Ug':>5}  {'spacer':<16}{'slim':>6}{'chunky':>8}  verdict (slim, limit 1.0)")
for fname, Uf in FRAMES.items():
    for Ug in (0.7, 0.5):
        for sname, psi in SPACERS.items():
            us, uc = (round(uw(Uf, Ug, psi, g), 3) for g in VARIANTS.values())
            verdict = "meets 0.8 too" if us <= 0.8 else ("ok" if us <= 1.0 else "fails")
            print(f"{fname:<17}{Uf:5.1f}{Ug:5.1f}  {sname:<16}{us:6.3f}{uc:8.3f}  {verdict}")

# The Merkblatt's rule of thumb (75 % glass, Ug 0.7, Uf 1.4, psi 0.045 -> Uw <= 1.0): one sash or two?
for n, mull in ((1, 0.0), (2, 0.09)):
    g = window(1.55, 1.15, side=0.065, top=0.065, bottom=0.08, mullion=mull, sashes=n)
    print(f"Rule of thumb, {n} sash: glass {g[1] / g[0]:.0%}, edge {g[3]:.2f} m"
          f" -> Uw {uw(1.4, 0.7, 0.045, g):.3f}")

print("\nLimit by room temperature (against outside):")
for t in (18, 20, 22, 28):
    print(f"  theta_i {t:>2} C -> Uli {limit(t):.2f} W/m2K")

# Where does each watt go? Slim wood-alu, Ug 0.5 triple glass, declared warm edge.
Aw, Ag, Af, lg = norm = VARIANTS["slim frame"]
Uf, Ug = 1.4, 0.5
parts = {"frame": Uf * Af, "glass": Ug * Ag, "glass edge": 0.04 * lg}
tot = sum(parts.values())
print(f"\nHeat loss split at Uw {tot / Aw:.2f}: " +
      ", ".join(f"{k} {v / tot:.0%}" for k, v in parts.items()))

# Site check: the spec said a declared warm edge (0.04); the IGU on site is printed 'Alu'.
spec, site = uw(Uf, Ug, 0.04, norm), uw(Uf, Ug, 0.08, norm)
print(f"\nSite check: spec Uw {spec:.2f}, delivered with aluminium spacer Uw {site:.2f}"
      f" -> {'still within 1.0' if site <= 1.0 else 'over the 1.0 limit'}"
      f" (+{(site - spec) / spec:.0%})")

Four lines of what it prints:

Merkblatt example: Aw 2.86 Ag 2.136 Af 0.72 m2, lg 9.60 m -> Uw 0.96 W/m2K (Merkblatt prints 0.96)
Rule of thumb, 1 sash: glass 80%, edge 4.85 m -> Uw 0.962
Rule of thumb, 2 sash: glass 75%, edge 6.68 m -> Uw 1.044
Heat loss split at Uw 0.88: frame 40%, glass 43%, glass edge 17%

Lines 1–13 — the formula as two functions: a function is a named, reusable block: inputs go in, a result comes out. window() turns the clear opening W × H and the frame width on each edge into Aw (opening), Ag (glass), Af (frame, simply Aw − Ag) and lg, the perimeter of every pane added up, returned as a tuple (an ordered bundle you unpack later). uw() is the Merkblatt formula, term for term. Geometry and physics live apart, so you can swap the window without touching the physics.

Lines 15–23 — the limit and the self-check: limit() encodes Tabelle 2: 1.0 W/m²K against outside air, 1.3 against unheated rooms, 5 % stricter or looser per kelvin away from 20 °C, never below the 0.80 target value. The script then recomputes the Merkblatt’s worked example, a 1.40 × 2.04 m wood-alu balcony door with Uf 1.2, Ug 0.7, Ψg 0.04 and 9.60 m of edge, and prints 0.96, exactly as published. That test is your licence to trust the rest.

Lines 25–40 — the Normfenster and the table: according to the Merkblatt, the Einzelbauteilnachweis uses a two-sash Normfenster of 1.55 × 1.15 m with a 75 % glass share when no measured installation dimensions exist. The slim frame widths (65/65/80 mm, 90 mm mullion) are example inputs chosen to hit that 75 %, not norm values; the chunky frame lands at 64 %. Three nested loops (a loop repeats a block once per item) run each frame against two glazings and two spacers, with the Merkblatt’s Rechenwerte for Uf: wood / wood-alu 1.4, PVC 1.9, insulated metal 2.5. The 0.08 is the EN ISO 10077-1:2017 table value for an aluminium spacer in a wood or PVC frame, applied here to every frame as a simplification (thermally broken metal frames carry 0.11). The 0.04 stands for a declared, monitored warm-edge value as in the Merkblatt example; the table value for a thermally improved spacer is 0.06. The verdict: on the slim frame, only wood or wood-alu with Ug 0.5 triple glass and a declared warm edge clears 1.0, at 0.875. PVC with the same glass and spacer sits on exactly 1.000.

That 1.000 is the beginner’s trap. Unrounded it is 1.00008; the script rounds to three decimals before comparing, so the verdict reads ok. Floating-point numbers (decimals as the computer stores them) rarely land exactly on a limit. Decide the rounding on purpose, print it, and treat anything within a few thousandths of the line as a design with no margin.

Lines 42–46 — one sash or two: the Merkblatt’s rule of thumb says 75 % glass, Ug 0.7, Uf 1.4 and Ψg 0.045 make Uw ≤ 1.0 possible. For a single sash the script agrees: 80 % glass, 4.85 m of edge, 0.962. Split the opening into two sashes and the mullion adds about 1.8 m of edge: 75 % glass, 6.68 m, 1.044. Same glass, same frame, one decision about how the window opens.

Lines 48–64 — limits, the watt split, the site check: at 18 °C room temperature the limit relaxes to 1.10; at 22 °C it tightens to 0.90; a 28 °C indoor pool hits the 0.80 floor. The 1.0 is the SIA 380/1:2016 value as the Merkblatt tabulates it; which version your canton has in force is a question for its energy office. The split for the slim window at Uw 0.88: frame 40 %, glass 43 %, glass edge 17 %. Seventeen percent through a strip a few millimetres wide. The last lines model a specified warm edge replaced on site by an aluminium spacer: 0.88 becomes 1.02, over the line by 17 %.

That case needs no software. SIA 331:2012, as the Merkblatt summarises it, requires the maker, the production date or number and, when thermally improved, the spacer material to be printed on the spacer itself, and the EnDK asks that these values be written into the tender and checked during execution. Substitutions happen for ordinary reasons, a supply gap or a mixed order; the marking exists so nobody has to guess. A torch and ten seconds, no licence key required.

From where I sit, in the late 2070s, the windows people could still repair were the ones whose numbers lived in plain text. Keep window_uw.py next to the Energienachweis; whoever renovates the building in 2051 can open it in any editor.

Atelier: A 12-person Zürich studio filing an Energienachweis usually carries the supplier’s Uw, and the spacer is decided at order stage, after the design team has moved on. Your Monday move: add one line, “spacer as delivered (printed marking)”, to the Bauleitung acceptance checklist, and feed the printed value into window_uw.py before signing off the delivery.

Hack: Sweep the spacer value and watch Uw climb with a line, not an area. Append these three lines to the script and predict before you run: each 0.02 W/mK on 6.68 m of edge over 1.7825 m² should add 0.075 to Uw.

# append to window_uw.py
for psi in (0.04, 0.06, 0.08):   # declared warm edge, table warm edge, table aluminium
    print(f"psi {psi:.2f} -> Uw {uw(1.4, 0.5, psi, norm):.3f}")

Expect 0.875, 0.950 and 1.025. The table warm-edge value still clears 1.0; only the aluminium spacer crosses it.

Learn-it:

Open the Merkblatt to page 11, run window_uw.py until it prints 0.96, then take the torch to your next window delivery.

FILED FROM
CO-SIGNERS
PAZ Academy
CONFIDENCE
HIGH
REPRINTS
© PAZ - PARAMETRIC ACADEMY ZURICH · ALL RIGHTS RESERVED

PAZ Kaffi · multidisciplinary editorial, led by PAZ Academy

⚑ REPORT AN ERROR · SUBMIT A CORRECTION
◂ BACK TO FRONT PAGE · PAZ KAFFI

© 2026 PAZ Academy.