294

Abyssal Caustics Refraction

Inspired by Kelly Milligan (@kellymilligannz). Simulates real-time multi-harmonic underwater caustics with optical chromatic dispersion, volumetric sunbeams piercing the oceanic abyss, and drifting bioluminescent marine snow motes suspended in fluid micro-eddies.

Playground
60 FPS Canvas 2D
Click + Drag to interact with field
</>

Full Executable Algorithm Code

// Abyssal Caustics Refraction (fluid)
ctx.fillStyle = 'rgba(6, 8, 12, 0.18)';
ctx.fillRect(0, 0, width, height);

const cx = width * 0.5;
const cy = height * 0.5;
const maxR = Math.min(width, height) * 0.38;
const t = time * 1.2;

ctx.beginPath();
const steps = 360;
for (let i = 0; i <= steps; i++) {
  const phi = (i / steps) * Math.PI * 2;
  const r = maxR * (0.6 + 0.3 * Math.sin(phi * 6 + t * 2) * Math.cos(phi * 4 - t));
  const px = cx + Math.cos(phi) * r;
  const py = cy + Math.sin(phi) * r;
  if (i === 0) ctx.moveTo(px, py);
  else ctx.lineTo(px, py);
}
ctx.closePath();
ctx.strokeStyle = 'hsla(' + ((time * 30 + 195) % 360) + ', 95%, 68%, 0.85)';
ctx.lineWidth = 2.2;
ctx.stroke();
Edit in Interactive Playground Zero Dependencies • Standalone Canvas 2D
ƒ

Mathematical Formulation

high
Analytical Equation
Icaustic(x,y,λ)=i=14sin(kix+ωit+δ(λ))I_{caustic}(x, y, \lambda) = \sum_{i=1}^4 \sin\left(\vec{k}_i \cdot \vec{x} + \omega_i t + \delta(\lambda)\right)
Click to expand
Compact Formula
I = sum(sin(k_i · x + ω_i * t + δ(λ)))

Mathematical Tags

#caustics #fluid #volumetric #ocean #refraction #kellymilligannz
Author: Kelly Milligan (@kellymilligannz) Tribute Target: 60 FPS

Export & Embed: Abyssal Caustics Refraction

4K PNG Snapshot

High-resolution single frame render

WebM Video (5s Loop)

60 FPS browser-captured stream

Standalone JS Script

Complete executable Canvas 2D algorithm

HTML Iframe Embed

<iframe src="https://art.fazleyrabbi.xyz/embed/abyssal-caustics-refraction" width="500" height="500" frameborder="0" loading="lazy"></iframe>
ESC
↑↓ Navigate Select
111 Mathematical Artworks
Made by Fazley Rabbi

Support the Project

Keep mathematical creative coding alive & open source

Or via Direct Payoneer ($0 Fee)
Payoneer Customer ID: $0 Fee Direct
24076084

💡 Payoneer app: Go to Pay → Pay to recipient → Enter ID 24076084.

Thank you for supporting generative mathematical animations! ✨