Skip to content
CoreSource checked

Narrow Phase Collision Detection

Performs precise collision tests for candidate pairs found by broad phase.

Quick Facts

Compact metadata for implementation and discovery.

Category
Simulation
Difficulty
Advanced
Family
Collision Detection
Tier
Core
Status
Verified
Review
Source Checked
Sources
1
Formulas
0
Relationships
5
Code example
Ready
Visualization
Ready

Overview

Narrow phase collision detection computes exact overlap, contact points, normals, or penetration depth for objects that might collide.

Core Concepts

contact pointpenetration depthshape featurecollision normal

Quick facts

Complexity

Runtime and memory behavior at a glance.

Best

O(features)

Average

O(features)

Worst

O(features^2)

Space

O(contact count)

When to Use

  • Use when physics simulation needs contact point.
  • Use when the input matches the assumptions behind collision Detection.

When Not to Use

  • Avoid when the time step, forces, or constraints make the system unstable for the chosen method.
  • Avoid when a simpler algorithm gives the required result with less setup.

What It Does

  • Performs precise collision tests for candidate pairs found by broad phase
  • Uses contact point and penetration depth to guide the work.
  • Produces updated state.

Use Cases

  • Physics simulation
  • Animation
  • Interactive systems

Inputs

  • Current state
  • Forces or constraints
  • Time step

Outputs

  • Updated state
  • Constraint corrections
  • Collision results

Pseudocode

  1. 1.Prepare the inputs and state needed for Narrow Phase Collision Detection.
  2. 2.Apply the contact point step while the stopping condition has not been met.
  3. 3.Update intermediate state and discard invalid candidates.
  4. 4.Return updated state.

Canonical Example

Input
Narrow Phase Collision Detection input
Output
Updated state
Explanation
Narrow Phase Collision Detection applies contact point to produce updated state.

Implementation Notes

  • Use deterministic update ordering when reproducibility matters.
  • Keep the contact point step separate enough to test independently.

Common Pitfalls

  • Changing the time step without retuning stiffness or damping can destabilize the simulation.
  • Test boundary and adversarial cases, not only ideal inputs.

Interactive Mechanism Walkthrough

Iterative Convergence & State Trajectory

Show state updates, constraints, and error correction over simulation steps.

Narrow Phase Collision Detection mechanism walkthrough step 1 of 4x₀x₁x₂x*
Step 1 of 4: Prepare the inputs and state needed for Narrow Phase Collision Detection.
simulation-mechanism

Notes

Narrow Phase Collision Detection operates in O(features) time and O(contact count) space within the Collision Detection family. Often compared with Broad Phase Collision Detection and GJK Collision Detection.

Sources (1)

What each reference supports for this entry.

Real-Time Collision Detection

Book

Collision-detection reference covering Narrow Phase Collision Detection geometric query stage, candidate filtering, or contact-generation role.

Explore Next

Good next jumps from the relationship graph, ranked for useful discovery.

Narrow phase usually runs after broad phase finds candidate pairs.

GJK is a common narrow-phase method for convex shapes.

Tags

SimulationCollision DetectionNarrow PhaseGeometry