Physics & constraints · 3 / 10

Runge–Kutta / RK2 / RK4

途中の傾きも評価して軌道を計算する。

Compare in motion

弾の軌道

Synchronized comparison
AReference
大きい時間刻みのオイラー法

大きい時間刻みのオイラー法

BRunge–Kutta / RK2 / RK4100%
途中の変化を使い軌道を近似できる

途中の変化を使い軌道を近似できる

Loading demo…

Scrub to pause and inspect. At 0%, B matches A; at 100%, B shows the effect. The scene repeats every 8 seconds.

Look for: 途中の傾きも評価 → 次の位置を求める。

This model simplifies the technique to show its use case and effect. Operation counts describe the model; they are not performance measurements.

Read the storyboard

例: 弾の軌道

  1. 1. Start

    現在の位置と速度

  2. 2. Change

    途中の傾きも評価

  3. 3. Result

    次の位置を求める

途中の変化を使い軌道を近似できる。時間変化を示す模式図です。実際の描画結果や処理速度を再現したものではありません。

How it works

  1. 1. Input

    微分方程式の傾き

  2. 2. Process

    途中の傾きも評価

  3. 3. Result

    次の状態の近似

A schematic of Runge–Kutta / RK2 / RK4. It shows the relationship between input, process, and result; exact values and rendering depend on the implementation.

Further reading

Gaffer On Games — Integration Basics ↗

A general reference for this subcategory.