Your browser sucks, JavaScript disabled! Gunnar's console needs JavaScript and WebAssembly. Git over SSH on port 2222 does not.

nordisk/facett

.nornir/helix-facets-design.md

Helix facets — design spec (2026-07-10)

Three new 3-D data-viz facets, generalizing the existing facett_graph3d::Layout3D::Helix (facett-graph3d/src/lib.rs:111). Reuse what's there: Graph3D/Node3, the injected-clock spin (FC-7, with_clock), the neon painters (neon::paint_node_orb/paint_edge_particles/ paint_shockwave), DecorPolicy, the GPU path (graph_gpu.wgsl), look::Theme, state_json.

The unifying invariant: Z = DEPTH = the stack of layers/versions; the circle (cross- section) holds the per-layer data; dims beyond the circle's 2-3 spatial axes spill into colour (then size/glow).


Variant A — DNA Helix (facett-dnahelix or Layout3D::Dna)

A true double-helix. Each data record = one rung (base pair) at step i. Two backbone strands spiral around a central axis; a rung connects strandA_i ↔ strandB_i.

Geometric roles (fixed) ← data fields (user-choosable via a column picker):

geometric role what it does default data field
axial position (along the helix) which rung / where up the ladder z — the "pinnarna i DNA-stegen" (progression / time / index). matches user.
rung radius R_i (half-length) fat/thin helix at that step x — "randen av pinnen" (magnitude). matches user.
rung tilt / base-pair asymmetry signed lean of the rung y ← MY ANSWER (see below).
twist θ_i = i·pitch the helical spin itself constant pitch (choosable); optionally data-driven
colour 4th dimension optional field

The y answer ("y vet jag inte — hjälp mig"): map y to base-pair asymmetry / rung lean — DNA's two strands give you a signed second variable for free. strandA_i sits at radius R·(1 + k·y_i), strandB_i at R·(1 − k·y_i). At y=0 the rung is symmetric through the axis; y>0 pushes the pair toward strand A, y<0 toward strand B — the ladder visibly leans. So: x = how wide the rung is, y = which way it leans (a signed value), z = how far up the ladder. (Alternative if you'd rather: y = local pitch — vertical rise between rungs, so y stretches/compresses the helix. Make it a DnaAxis::{Tilt, Pitch} toggle so both ship.)

Strands drawn as glowing tubes (neon orbs along each), rungs as glowing edges. Spins on the axis by default. state_json exposes the axis→field mapping + spin/yaw.


Variant B — Time Helix / Time Vortex (facett-timehelix) ⬅ the Doctor-Who one

A rotatable cylinder viewed down its axis — you fly into the tunnel.

Doctor Who intro — deep analysis → the render treatment

The title "time vortex": a tunnel/wormhole the camera flies through forever; swirling cloud walls in teal/cyan shot with gold lightning; the tunnel recedes to a bright core / vanishing point while distant walls dissolve into darkness (depth fog); the walls spiral as you fly; energy filaments streak forward; heavy additive bloom + motion blur + a sense of infinite depth and speed. Translate that to the facet:

  1. Camera down the axis toward a bright vanishing point — radial core gradient (cyan-white centre → deep indigo rim).
  2. Perspective shrink + exponential depth fade (this is the "tona ner som en flygsimulator"): alpha_layer = exp(-depth·k), and colour lerps toward deep blue with depth (atmospheric fog). Near layer = big/bright/saturated; far layer = small/dim/blue → dissolves to black.
  3. Slow axial swirl via the injected clock.
  4. Additive glow points (neon::paint_node_orb) + faint per-layer glow rings.
  5. Energy filaments = optional inter-layer edges as glowing curved streaks (neon::paint_edge_particles) — this is literally Variant C's version-wires.
  6. Palette: cyan/teal + gold accents on deep indigo/black; theme-aware via look::Theme. Optionally a subtle volumetric cloud shimmer in graph_gpu.wgsl.

Variant C — Component-DAG Time Helix (nornir follow-on)

The generalized Z-helix where each layer = a moment in time (release/commit/version) and each layer holds a component dependency DAG (components as disc nodes + intra-layer dep edges). Inter-layer wires connect component C in layer z → C in layer z+1 (its next version) = the glowing filaments = version evolution. Fly down the vortex to watch the whole dependency graph evolve over time.

Nornir uses (after A+B land in facett):


Build plan / sequencing

  1. facett: Variant A (DNA Helix) + Variant B (Time Vortex) as first-class Facets (headless state_json, injected-clock spin, theme-aware, pointer-drag orbit takeover).

  2. facett-demo: wire both into tabs (e.g. dna + timehelix), seeded with realistic demo data; add to LEGEND + mega_matrix coverage gate + a robot-drive step.

  3. Commit on a branch in facett + facett-demo. cargo build/cargo test -p facett-demo

    • -p facett-graph3d/new-crate green.
  4. nornir (separate, follow-on): Variant C for Funnel-DAG + Component-DAG. (Note nornir cargo test is currently RED — see workspace FIXQUEUE N10 — fix that first.)