Flow Field / Vector Field

別名: vector field

Vector fields are classical mathematics; the long-form generative "flow field" technique was popularized in the 2010s (e.g. Tyler Hobbs).

コミュニティ・通称 名称 — 「flow field」「vector field」は命名されたアルゴリズム名というより、数学・物理から 借りた記述的な通称で、生成アートの意味での明確な命名者は確認されていない。技法は 2010年代の long-form 実践者(例: Tyler Hobbs)が普及させたが、技法の普及と名の命名は 別であり、命名者・命名年は未解決(要確認)。

ひとことで 各点に方向ベクトルを割り当てた場の上をパーティクルが流れる手法。多くは Perlin ノイズを角度に写像する。

Flow field — particle advection over a noise-derived vector field · Open in new tab ↗ · Motion begins only when you press Run.

コード

上のデモの実際のスケッチ(サンドボックスで再現可能)。これで全部です。

flow-field/index.html
const SEED = Math.floor(Math.random()*1e9);
const PALETTES = [
  ['#1f3a93','#e74c3c','#f1c40f','#27ae60','#2c3e50'],
  ['#264653','#2a9d8f','#e9c46a','#f4a261','#e76f51'],
  ['#220a32','#7b2cbf','#c77dff','#e0aaff','#ffd6ff'],
  ['#0a0908','#22333b','#eae0d5','#c6ac8f','#5e503f'],
];

function setup() {
  randomSeed(SEED); noiseSeed(SEED);
  const s = Math.min(windowWidth, windowHeight);
  createCanvas(s, s);
  pixelDensity(2);
  noStroke();

  const palette = random(PALETTES);
  background(palette.shift());

  const N = 2400;            // particles
  const STEPS = 220;         // path length
  const FREQ = 0.0025;       // noise spatial frequency
  const SPEED = s * 0.0018;
  const STEP_SIZE = s * 0.0035;

  for (let i = 0; i < N; i++) {
    let x = random(width);
    let y = random(height);
    fill(random(palette) + '20');
    for (let j = 0; j < STEPS; j++) {
      // map noise → angle (×TWO_PI gives strong direction)
      const a = noise(x*FREQ, y*FREQ) * TWO_PI * 2.0;
      x += cos(a) * STEP_SIZE;
      y += sin(a) * STEP_SIZE;
      if (x < 0 || y < 0 || x >= width || y >= height) break;
      circle(x, y, SPEED);
    }
  }
}

デモのソースを開く ↗

仕組み

キャンバスを覆うグリッドをつくる。各セルについて、セルの座標でノイズ関数をサンプリングし、その結果を角度に対応づけて、すべてのセルに方向を与える。次にパーティクルをランダムな位置に配置し、各ステップで、そのパーティクルがいるセルの角度を参照して、その角度の向きへ少しだけ前進させ、軌跡の一区間を描く。これを多数のパーティクルについて多数のステップ繰り返すと、特徴的な「梳いたような」流線のテクスチャが得られる。ノイズの周波数は場がどれだけ細かく渦巻くかを、ステップ幅とパーティクル数は密度を制御する。

パラメータ

系譜

先行例
Tyler Hobbs
関連
Perlin / Simplex Noise、Particle System、Strange Attractor

よく組み合わされるアルゴリズム

このアルゴリズムを使う作品 (50)

Alan Ki Aankhen
fahad-karim
APEX
phenomena
Backwards
asaf-slook
Blaschke Ballet
numbersinmotion
Blooms
cory-haber
Coded Algorithmic Drawing #9
joan-truckenbrod
Collapsed Sequence
toiminto
Cytographia
golan-levin
Dipolar
junia-farquhar
Drift
paolo-ceric
Dustfold
lunarean
Ego Death
electralina
Electriz
che-yu-wu
Essenza
stefano-contiero
Exstasis
grant-oesterling
Fidenza
tyler-hobbs
Flows
ryley-o-eth
Fluiroso
sebastian-brocher-cryptoarte
Good, Computer
dean-blacc
Gravity 12
jimmy-herdberg
Gravity 16
jimmy-herdberg
Hello Modulo
nat-sarkissian
Hōrō
makio135
ilumz
wolffia-inc-motus-art
Lacunae
james-dalessandro
Life and Love and Nothing
nat-sarkissian
Longing
phenomena
Low Tide
artem-verkhovskiy-x-andy-shaw
Lumina
distcollective
Meridian
matt-deslauriers
Metaphysics
jinyao-lin
Mycelia
jmy
Nära
tengil
Neural Sediments
eko33
ORI
james-merrill
Phototaxis
casey-reas
Pointers
steve-pikelny
QQL
tyler-hobbs
Roamings
luca-ionescu
sail-o-bots
sturec
Through Curved Air
jacob-gold
Total Strangers
artem-verkhovskiy-x-andy-shaw
Trichro-matic
mountvitruvius
Tropism
neel-shivdasani
UMK
fernando-jerez
undead wyverns
hideo
Watercolor Dreams
numbersinmotion
We
vamoss
Wind Map
fernanda-viegas
Your Story
encapsuled

参考文献

最終更新 2026-07-16