# Garden Rose

Shape · (x, y, z) = f(u, v, t)

`((1 − (1.25(1 − mod(3.6u, 2 · π)/π)² − 0.25)²/2) · sin(π/2 · exp(−u/(8 · π))) · (v/π + 1.95653(v/π)² · (1.27689v/π − 1)² · cos(π/2 · exp(−u/(8 · π)))) · cos u,  (1 − (1.25(1 − mod(3.6u, 2 · π)/π)² − 0.25)²/2) · (v/π · cos(π/2 · exp(−u/(8 · π))) − 1.95653(v/π)² · (1.27689v/π − 1)² · sin(π/2 · exp(−u/(8 · π)))²),  (1 − (1.25(1 − mod(3.6u, 2 · π)/π)² − 0.25)²/2) · sin(π/2 · exp(−u/(8 · π))) · (v/π + 1.95653(v/π)² · (1.27689v/π − 1)² · cos(π/2 · exp(−u/(8 · π)))) · sin u)`

[Open in the app](https://www.wavelace.com/app#p=181) · [This page](https://www.wavelace.com/presets/garden-rose)

### What it draws

A rose in bloom, built as one sheet wound twelve times round the vertical axis. The angle is `u`, and the opening dials take it through `24π`. The other parameter, `v/π`, runs from 0 at the heart of the flower to 1 at the tip of a petal.

All three expressions share a factor, the petal's outline, and an angle `φ = π/2 · e^(−u/(8π))`. A point a distance `v/π` along a petal sits at that angle from the vertical. The first and last expressions turn it round the axis with `cos u` and `sin u`, and the middle one is its height.

### The petal

Write `s = 1 − mod(3.6u, 2π)/π`. It falls from 1 to −1 across each petal, and 3.6 petals fill a turn, each 100° wide.

The outline `1 − (1.25s² − 0.25)²/2` scales the petal's length. It is 0.5 where two petals meet, 1 at `s = ±1/√5`, and 0.97 in the middle, a small notch at the tip of every petal.

The term `1.95653 (v/π)² (1.27689 v/π − 1)²` is the curl. It is 0 at the heart and again at `v/π ≈ 0.78`, at most 0.075 between them, and 0.15 at the tip, so a petal's edge rolls outward most in its last fifth.

### The bloom

The angle `φ` does the opening. On the first turn it is close to `π/2`, so the outer petals lie flat. It shrinks by a factor of e every four turns, to `π/2 · e^(−3) ≈ 0.078` on the last, where the inner petals stand almost upright and close into a bud.

Since 3.6 is not a whole number, each turn's petals start 40° on from the turn's before, and they overlap like tiles. The pattern of 18 petals comes round again every five turns.

### Try

- Press `Top` to look down into the flower. The petals spiral in, each ring offset from the one outside it.
- Set `Turns of u` to 4. The angle only falls to `π/2 · e^(−1) ≈ 0.58`, so the flower is half open with no bud.
- Set `Span of v (×π)` to 1.5. The curl grows with the fourth power of `v/π`, and the petal edges fling outward.
- Turn `Mesh` down from its top stop to see the grid of `u` and `v` lines the petals are made of.

### Read more

- [Parametric surface](https://en.wikipedia.org/wiki/Parametric_surface)
- [Modulo](https://en.wikipedia.org/wiki/Modulo)
- [Exponential decay](https://en.wikipedia.org/wiki/Exponential_decay)
- [Rose](https://en.wikipedia.org/wiki/Rose)
