Back to the roots again

A presentation at Tech Talk @ Tagesspiegel in January 2024 in by Gunnar Bittersmann

Slide 1

Slide 1

Back to the roots

Slide 2

Slide 2

Back to the Future

Slide 3

Slide 3

THE FUTURE IS NOW

Slide 4

Slide 4

BACK TO THE ROOTS AGAIN

Slide 5

Slide 5

BEISPIEL: BILDERGALERIE

Slide 6

Slide 6

BEISPIEL: BILDERGALERIE

Slide 7

Slide 7

a·b=A
a/b=r
a=r·b
r·b·b=A
b² = A / r
b = √A / r
a = r · √A / r
a = √A · r

Slide 8

Slide 8

Sassematics Gunnar Bittersmann @g16n

Slide 9

Slide 9

Babylonian method (Heron’s method)
x0 ≈ √a > 0
xn+1 = (xn + a / xn) / 2
lim xn = √a

a=2
x0 = 1 x1 = (1 + 2 / 1) / 2 = 1.5
x2 = (1.5 + 2 / 1.5) / 2 = 1.41666667
x3 = (1.41666667 + 2 / 1.41666667) / 2 = 1.41421568…
√2 = 1.41421356…

Slide 10

Slide 10

Babylonian method (Heron’s method)
@function sqrt($a, $iterations: 10) {
$x: 1;
@for $i from 1 through $iterations { $x: ($x + $a / $x) / 2; }
@return $x;
}

Slide 11

Slide 11

Slide 12

Slide 12

Custom properties sind mehr als bloß CSS-Variablen

Slide 13

Slide 13

Heron-Verfahren (babylonisches Wurzelziehen) —area: 0.4; —a: calc(var(!—area) * var(—aspect-ratio)); —x0: 1; —x1: calc((var(!—x0) + var(!—a) / var(!—x0)) / 2); —x2: calc((var(!—x1) + var(!—a) / var(!—x1)) / 2); —x3: calc((var(!—x2) + var(!—a) / var(!—x2)) / 2); width: calc(var(!—x3) * 100%);

Slide 14

Slide 14

THE FUTURE IS NOW sqrt()

Slide 15

Slide 15

Slide 16

Slide 16

Slide 17

Slide 17

Slide 18

Slide 18

Slide 19

Slide 19

6 10 1 0 5 14

Slide 20

Slide 20

BACK TO THE ROOTS AGAIN FOTOS: GUNNAR BITTERSMANN