{
 "id": "gjk-epa-collision-detection",
 "title": "GJK and EPA convex collision detection",
 "aliases": [
  "GJK",
  "Gilbert-Johnson-Keerthi",
  "EPA",
  "expanding polytope algorithm"
 ],
 "domain": "simulation",
 "subdomain": "collision detection",
 "stage": "simulation",
 "realtime": "realtime",
 "platforms": [
  "cpu",
  "cuda",
  "unity",
  "unreal",
  "godot",
  "webgl2",
  "webgpu",
  "desktop-gpu"
 ],
 "year_introduced": 1988,
 "inputs": [
  "mesh"
 ],
 "outputs": [
  "point-cloud"
 ],
 "style": "both",
 "dynamic": "dynamic",
 "summary": "Narrow-phase test for convex shapes: GJK finds whether two shapes overlap or their closest points through support mappings, and EPA recovers penetration depth and normal when they do.",
 "how_it_works": "Both algorithms work on the Minkowski difference of two convex shapes, which is never built explicitly. All they need is a support function: for a direction, return the farthest point of each shape, and subtract. GJK keeps a small simplex (point, segment, triangle, tetrahedron) inside that difference. Each iteration asks for the support point toward the origin, adds it, and reduces the simplex to the feature closest to the origin. If the simplex encloses the origin the shapes overlap; if the support point cannot pass the origin, they are separate and the last closest feature gives distance and witness points. When overlap is found, EPA starts from the final simplex, inflates it into a polytope, and repeatedly expands the face closest to the origin by a new support point until the face stops moving; that face's normal and distance are the minimum translation vector, and barycentric weights give contact points. Spheres, capsules, boxes and hulls plug in with only a support function.",
 "when_to_use": "Choose it as the generic narrow phase for arbitrary convex colliders (hulls, capsules, cones, rounded boxes) and for continuous or distance queries. Prefer a dedicated analytic test for sphere-sphere or box-box pairs, which are faster and more robust. Prefer `coacd-convex-decomposition` to turn concave meshes into convex pieces GJK can consume, `three-mesh-bvh` for triangle-mesh queries, and `sequential-impulses` or `xpbd` to resolve the contacts GJK and EPA produce.",
 "cost": {
  "class": "cheap",
  "notes": "A handful of support evaluations per pair, usually under about ten iterations when warm-started from the previous frame's simplex."
 },
 "failure_modes": [
  "Degenerate simplices (coplanar or collinear points) cause infinite loops or NaNs unless guarded with tolerances",
  "EPA returns wrong or unstable normals for shallowly penetrating or very large or thin shapes",
  "Tolerance mismatch between GJK and EPA leaves shapes reported as touching with no usable normal",
  "Contact manifold from one EPA point jitters; stacking needs a manifold generator or persistent contacts",
  "Only convex shapes: concave meshes silently give the hull's contacts"
 ],
 "sources": [
  {
   "role": "primary",
   "key": "doi:10.1109/56.2083",
   "type": "paper",
   "title": "A fast procedure for computing the distance between complex objects in three-dimensional space",
   "authors": [
    "E.G. Gilbert",
    "D.W. Johnson",
    "S.S. Keerthi"
   ],
   "year": 1988,
   "venue": "IEEE Journal on Robotics and Automation",
   "url": "https://doi.org/10.1109/56.2083",
   "ids": {
    "doi": "10.1109/56.2083"
   },
   "license": null,
   "extra": {
    "csl_type": "journal-article"
   },
   "provenance": {
    "title": {
     "authority": "crossref",
     "endpoint": "https://api.crossref.org/works/10.1109/56.2083",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "authors": {
     "authority": "crossref",
     "endpoint": "https://api.crossref.org/works/10.1109/56.2083",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "year": {
     "authority": "crossref",
     "endpoint": "https://api.crossref.org/works/10.1109/56.2083",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "venue": {
     "authority": "crossref",
     "endpoint": "https://api.crossref.org/works/10.1109/56.2083",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "url": {
     "authority": "crossref",
     "endpoint": "https://api.crossref.org/works/10.1109/56.2083",
     "checked_at": "2026-11-29T15:51:27.588Z"
    }
   },
   "status": "verified",
   "checked_at": "2026-11-29T15:51:27.588Z",
   "title_sim": 1,
   "__bib": "gilbert1988fast"
  },
  {
   "role": "primary",
   "key": "doi:10.1080/10867651.1999.10487502",
   "type": "paper",
   "title": "A Fast and Robust GJK Implementation for Collision Detection of Convex Objects",
   "authors": [
    "Gino Van den Bergen"
   ],
   "year": 1999,
   "venue": "Journal of Graphics Tools",
   "url": "https://doi.org/10.1080/10867651.1999.10487502",
   "ids": {
    "doi": "10.1080/10867651.1999.10487502"
   },
   "license": null,
   "extra": {
    "csl_type": "journal-article"
   },
   "provenance": {
    "title": {
     "authority": "crossref",
     "endpoint": "https://api.crossref.org/works/10.1080/10867651.1999.10487502",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "authors": {
     "authority": "crossref",
     "endpoint": "https://api.crossref.org/works/10.1080/10867651.1999.10487502",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "year": {
     "authority": "crossref",
     "endpoint": "https://api.crossref.org/works/10.1080/10867651.1999.10487502",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "venue": {
     "authority": "crossref",
     "endpoint": "https://api.crossref.org/works/10.1080/10867651.1999.10487502",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "url": {
     "authority": "crossref",
     "endpoint": "https://api.crossref.org/works/10.1080/10867651.1999.10487502",
     "checked_at": "2026-11-29T15:51:27.588Z"
    }
   },
   "status": "verified",
   "checked_at": "2026-11-29T15:51:27.588Z",
   "title_sim": 1,
   "__bib": "bergen1999fast"
  },
  {
   "role": "tutorial",
   "key": "url:https://caseymuratori.com/blog_0003",
   "type": "tutorial",
   "title": "Implementing GJK (Molly Rocket)",
   "authors": [
    "Casey Muratori"
   ],
   "year": null,
   "venue": "caseymuratori.com",
   "url": "https://caseymuratori.com/blog_0003",
   "ids": {},
   "license": null,
   "extra": {
    "http_status": 200,
    "live": true,
    "archive": {
     "url": "http://web.archive.org/web/20260823181154/https://caseymuratori.com/blog_0003",
     "timestamp": "20260823181154"
    },
    "page_title": "Implementing GJK (2006)",
    "host": "caseymuratori.com",
    "title_confirmed_by_page": false,
    "title_unconfirmed": true
   },
   "provenance": {
    "title": {
     "authority": "research-draft",
     "endpoint": "title_hint/author_hint, checked against page title where available",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "url": {
     "authority": "http",
     "endpoint": "GET https://caseymuratori.com/blog_0003 → 200",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "authors": {
     "authority": "research-draft",
     "endpoint": "title_hint/author_hint, checked against page title where available",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "venue": {
     "authority": "http",
     "endpoint": "GET https://caseymuratori.com/blog_0003 → 200",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "year": {
     "authority": "research-draft",
     "endpoint": "title_hint/author_hint, checked against page title where available",
     "checked_at": "2026-11-29T15:51:27.588Z"
    }
   },
   "status": "verified",
   "checked_at": "2026-11-29T15:51:27.588Z",
   "title_sim": 0.5714285714285714,
   "__bib": "muratoriimplementing"
  },
  {
   "role": "implementation",
   "key": "gh:jrouwe/joltphysics",
   "type": "code",
   "title": "jrouwe/JoltPhysics",
   "description": "A multi core friendly rigid body physics and collision detection library. Written in C++. Suitable for games and VR applications. Used by Horizon Forbidden West and Death Stranding 2.",
   "authors": [
    "jrouwe"
   ],
   "year": 2021,
   "venue": "GitHub",
   "url": "https://github.com/jrouwe/JoltPhysics",
   "ids": {
    "repo": "jrouwe/JoltPhysics"
   },
   "license": "MIT",
   "extra": {
    "stars": 12549,
    "stars_checked": "2026-11-29",
    "archived": false,
    "fork": false,
    "pushed_at": "2026-11-28T16:13:09Z",
    "language": "C++",
    "homepage": null,
    "license_name": "MIT License"
   },
   "provenance": {
    "title": {
     "authority": "github",
     "endpoint": "https://api.github.com/repos/jrouwe/JoltPhysics",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "authors": {
     "authority": "github",
     "endpoint": "https://api.github.com/repos/jrouwe/JoltPhysics",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "year": {
     "authority": "github",
     "endpoint": "https://api.github.com/repos/jrouwe/JoltPhysics",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "venue": {
     "authority": "github",
     "endpoint": "https://api.github.com/repos/jrouwe/JoltPhysics",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "url": {
     "authority": "github",
     "endpoint": "https://api.github.com/repos/jrouwe/JoltPhysics",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "license": {
     "authority": "github",
     "endpoint": "https://api.github.com/repos/jrouwe/JoltPhysics",
     "checked_at": "2026-11-29T15:51:27.588Z"
    }
   },
   "status": "verified",
   "checked_at": "2026-11-29T15:51:27.588Z",
   "title_sim": null,
   "__bib": "jrouwe2021jrouwe"
  },
  {
   "role": "implementation",
   "key": "gh:bulletphysics/bullet3",
   "type": "code",
   "title": "bulletphysics/bullet3",
   "description": "Bullet Physics SDK: real-time collision detection and multi-physics simulation for VR, games, visual effects, robotics, machine learning etc.",
   "authors": [
    "bulletphysics"
   ],
   "year": 2011,
   "venue": "GitHub",
   "url": "https://github.com/bulletphysics/bullet3",
   "ids": {
    "repo": "bulletphysics/bullet3"
   },
   "license": "NOASSERTION",
   "extra": {
    "stars": 14921,
    "stars_checked": "2026-11-29",
    "archived": false,
    "fork": false,
    "pushed_at": "2026-10-09T21:51:41Z",
    "language": "C++",
    "homepage": "http://bulletphysics.org",
    "license_name": "Other"
   },
   "provenance": {
    "title": {
     "authority": "github",
     "endpoint": "https://api.github.com/repos/bulletphysics/bullet3",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "authors": {
     "authority": "github",
     "endpoint": "https://api.github.com/repos/bulletphysics/bullet3",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "year": {
     "authority": "github",
     "endpoint": "https://api.github.com/repos/bulletphysics/bullet3",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "venue": {
     "authority": "github",
     "endpoint": "https://api.github.com/repos/bulletphysics/bullet3",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "url": {
     "authority": "github",
     "endpoint": "https://api.github.com/repos/bulletphysics/bullet3",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "license": {
     "authority": "github",
     "endpoint": "https://api.github.com/repos/bulletphysics/bullet3",
     "checked_at": "2026-11-29T15:51:27.588Z"
    }
   },
   "status": "verified",
   "checked_at": "2026-11-29T15:51:27.588Z",
   "title_sim": null,
   "__bib": "bulletphysics2011bulletphysics"
  }
 ],
 "presets": [
  {
   "id": "gjk-epa-collision-detection-live",
   "title": "GJK & EPA convex collision — live Minkowski difference A−B, enclosing simplex & EPA penetration vector",
   "runtime": "glsl-fragment",
   "params": {
    "P_ORBIT_SEP": 0.22,
    "P_ROT_SPEED": 1,
    "P_MINKOWSKI_VIS": 1,
    "P_SHAPE_ROUND": 0.03
   },
   "basis": "original",
   "license_note": "Original interactive WebGL2 fragment shader written for Texel Atlas (MIT).",
   "code": "const float P_ORBIT_SEP = 0.22; // P Orbit Distance [0.08, 0.42, 0.01]\nconst float P_ROT_SPEED = 1.0; // P Motion Speed [0.0, 2.5, 0.05]\nconst float P_MINKOWSKI_VIS = 1.0; // P Minkowski Glow [0.2, 1.8, 0.05]\nconst float P_SHAPE_ROUND = 0.03; // P Margin Radius [0.005, 0.07, 0.005]\n\nmat2 rot2(float a) { float c = cos(a), s = sin(a); return mat2(c, -s, s, c); }\n\nfloat sdSegment(vec2 p, vec2 a, vec2 b) {\n  vec2 pa = p - a, ba = b - a;\n  float h = clamp(dot(pa, ba) / max(dot(ba, ba), 1e-5), 0.0, 1.0);\n  return length(pa - ba * h);\n}\n\n// Support function for a regular N-gon centered at c, rotated by ang, radius r, margin m\nvec2 supportPoly(vec2 dir, vec2 c, float r, float ang, int nSides, float margin) {\n  vec2 ld = rot2(-ang) * dir;\n  float bestDot = -1e9;\n  vec2 bestV = vec2(0.0);\n  for (int i = 0; i < 6; i++) {\n    if (i >= nSides) break;\n    float a = float(i) * (6.2831853 / float(nSides));\n    vec2 v = vec2(cos(a), sin(a)) * r;\n    float d = dot(v, ld);\n    if (d > bestDot) { bestDot = d; bestV = v; }\n  }\n  vec2 nd = dir / max(length(dir), 1e-5);\n  return c + rot2(ang) * bestV + nd * margin;\n}\n\n// Signed distance to a regular N-gon via exact half-space intersection\nfloat sdPoly(vec2 p, vec2 c, float r, float ang, int nSides, float margin) {\n  vec2 q = rot2(-ang) * (p - c);\n  float dMax = -1e9;\n  float apothem = r * cos(3.14159265 / float(nSides));\n  for (int i = 0; i < 6; i++) {\n    if (i >= nSides) break;\n    float a = (float(i) + 0.5) * (6.2831853 / float(nSides));\n    vec2 n = vec2(cos(a), sin(a));\n    dMax = max(dMax, dot(q, n) - apothem);\n  }\n  return dMax - margin;\n}\n\n// Signed distance to exact convex Minkowski difference M = A - B via support planes!\n// Also outputs EPA closest boundary point to the origin (minimum translation vector)\nfloat sdMinkowski(vec2 p, vec2 cA, float rA, float aA, vec2 cB, float rB, float aB, float m, out vec2 epaVec, out float epaDepth) {\n  float dMax = -1e9;\n  epaDepth = 1e9;\n  epaVec = vec2(1.0, 0.0);\n  for (int i = 0; i < 24; i++) {\n    float ang = float(i) * (6.2831853 / 24.0);\n    vec2 dir = vec2(cos(ang), sin(ang));\n    vec2 sup = supportPoly(dir, cA, rA, aA, 5, m) - supportPoly(-dir, cB, rB, aB, 3, m);\n    float planeDist = dot(sup, dir);\n    // Half-space signed distance at query point p\n    dMax = max(dMax, dot(p, dir) - planeDist);\n    // EPA: minimum distance from origin (0,0) to supporting hyperplane\n    if (planeDist < epaDepth) {\n      epaDepth = planeDist;\n      epaVec = dir * planeDist;\n    }\n  }\n  return dMax;\n}\n\nvec3 aces(vec3 x) {\n  x = max(x, 0.0);\n  return (x * (2.51 * x + 0.03)) / (x * (2.43 * x + 0.59) + 0.14);\n}\n\nvoid mainImage(out vec4 fragColor, in vec2 fragCoord) {\n  vec2 uv = (fragCoord - 0.5 * iResolution.xy) / iResolution.y;\n  float px = 1.0 / max(iResolution.y, 1.0);\n  float tAnim = iTime * max(P_ROT_SPEED, 0.0);\n  float sep = clamp(P_ORBIT_SEP, 0.05, 0.48);\n  float mGlow = clamp(P_MINKOWSKI_VIS, 0.1, 2.0);\n  float margin = clamp(P_SHAPE_ROUND, 0.004, 0.08);\n\n  // Split viewport: Left = World Space (Shapes A & B), Right = Configuration Space (Minkowski Diff A - B)\n  bool rightPane = uv.x > 0.0;\n  vec2 lp = uv - vec2(rightPane ? 0.42 : -0.42, 0.0);\n\n  // Two convex shapes oscillating cleanly between separated and penetrating states\n  float osc = sep * (0.65 + 0.55 * sin(tAnim * 0.85));\n  vec2 cA = vec2(-osc * 0.55, 0.06 * cos(tAnim * 0.6));\n  vec2 cB = vec2(osc * 0.55, -0.06 * cos(tAnim * 0.6));\n  float rA = 0.145;\n  float rB = 0.135;\n  float aA = tAnim * 0.45;\n  float aB = -tAnim * 0.62 + 0.5;\n\n  vec2 epaVec;\n  float epaDepth;\n  float dMinkOrigin = sdMinkowski(vec2(0.0), cA, rA, aA, cB, rB, aB, margin, epaVec, epaDepth);\n  bool colliding = dMinkOrigin < 0.0;\n\n  // Blueprint grid background\n  vec3 col = vec3(0.028, 0.038, 0.062);\n  vec2 g = abs(fract(lp * 10.0 - 0.5) - 0.5);\n  col += vec3(0.02, 0.032, 0.048) * smoothstep(0.035, 0.005, min(g.x, g.y));\n  // Subtle coordinate axes in each pane\n  float axes = min(abs(lp.x), abs(lp.y));\n  col += vec3(0.08, 0.12, 0.18) * smoothstep(px * 2.2, px * 0.4, axes);\n\n  if (!rightPane) {\n    // Left Pane: World Space convex shapes A (pentagon) and B (triangle)\n    float dA = sdPoly(lp, cA, rA, aA, 5, margin);\n    float dB = sdPoly(lp, cB, rB, aB, 3, margin);\n\n    vec3 colA = vec3(0.18, 0.72, 0.96);\n    vec3 colB = vec3(0.96, 0.58, 0.18);\n    if (dA < 0.0) col = mix(col, colA, 0.48);\n    if (dB < 0.0) col = mix(col, colB, 0.48);\n    if (dA < 0.0 && dB < 0.0) {\n      // Overlap intersection zone glowing hot crimson\n      col = mix(col, vec3(1.0, 0.22, 0.36), 0.75);\n    }\n    col = mix(col, colA * 1.25, smoothstep(px * 3.2, px * 0.6, abs(dA)));\n    col = mix(col, colB * 1.25, smoothstep(px * 3.2, px * 0.6, abs(dB)));\n\n    // Draw EPA Minimum Translation Vector (MTV) separating B from A when colliding\n    if (colliding) {\n      vec2 mtvStart = 0.5 * (cA + cB);\n      vec2 mtvEnd = mtvStart + epaVec;\n      float dMtv = sdSegment(lp, mtvStart, mtvEnd);\n      col = mix(col, vec3(1.0, 0.96, 0.42), smoothstep(px * 4.0, px * 0.8, dMtv));\n      col = mix(col, vec3(1.0, 0.98, 0.65), smoothstep(0.016, 0.005, length(lp - mtvEnd)));\n    }\n  } else {\n    // Right Pane: Minkowski Difference M = A - B centered on Origin (0,0)\n    vec2 dummyVec; float dummyD;\n    float dM = sdMinkowski(lp, cA, rA, aA, cB, rB, aB, margin, dummyVec, dummyD);\n\n    // Distance field contour rings outside Minkowski sum\n    float iso = smoothstep(0.07, 0.01, abs(fract(max(dM, 0.0) * 14.0) - 0.5));\n    col += vec3(0.07, 0.14, 0.22) * iso * step(0.0, dM) * 0.6;\n\n    // Fill Minkowski Difference polygon (emerald when separated, crimson when Origin is inside!)\n    vec3 minkCol = colliding ? vec3(0.95, 0.24, 0.36) : vec3(0.16, 0.86, 0.58);\n    if (dM < 0.0) {\n      col = mix(col, minkCol * 0.55, 0.58 * min(mGlow, 1.4));\n    }\n    col = mix(col, minkCol * 1.35, smoothstep(px * 3.5, px * 0.7, abs(dM)));\n\n    // Construct a 3-vertex GJK Simplex inside M around the origin\n    vec2 s0 = supportPoly(vec2(1.0, 0.15), cA, rA, aA, 5, margin) - supportPoly(vec2(-1.0, -0.15), cB, rB, aB, 3, margin);\n    vec2 s1 = supportPoly(vec2(-0.55, 0.84), cA, rA, aA, 5, margin) - supportPoly(vec2(0.55, -0.84), cB, rB, aB, 3, margin);\n    vec2 s2 = supportPoly(vec2(-0.45, -0.89), cA, rA, aA, 5, margin) - supportPoly(vec2(0.45, 0.89), cB, rB, aB, 3, margin);\n    float dSimplex = min(sdSegment(lp, s0, s1), min(sdSegment(lp, s1, s2), sdSegment(lp, s2, s0)));\n    col = mix(col, vec3(0.86, 0.94, 1.0), smoothstep(px * 2.8, px * 0.6, dSimplex) * 0.85);\n\n    // Highlight EPA penetration vector from Origin (0,0) to closest edge of M\n    if (colliding) {\n      float dEpa = sdSegment(lp, vec2(0.0), epaVec);\n      col += vec3(1.0, 0.92, 0.32) * exp(-dEpa * 85.0) * 0.85;\n      col = mix(col, vec3(1.0, 0.96, 0.45), smoothstep(px * 3.8, px * 0.8, dEpa));\n      col = mix(col, vec3(1.0, 0.98, 0.72), smoothstep(0.017, 0.005, length(lp - epaVec)));\n    }\n\n    // Origin (0,0) target crosshair\n    float dOrig = length(lp);\n    col = mix(col, vec3(1.0), smoothstep(0.022, 0.008, dOrig));\n    col = mix(col, colliding ? vec3(1.0, 0.25, 0.35) : vec3(0.2, 0.95, 0.65), smoothstep(0.012, 0.004, dOrig));\n  }\n\n  // Center pane divider\n  col = mix(col, vec3(0.75, 0.84, 0.96), smoothstep(px * 2.5, px * 0.5, abs(uv.x)));\n\n  fragColor = vec4(pow(clamp(aces(col), 0.0, 1.0), vec3(1.0 / 2.2)), 1.0);\n}",
   "execution_fidelity": "conceptual-diagram",
   "proof": {
    "kind": "rendered",
    "label": "rendered 2026-11-30",
    "ok": true,
    "proof": {
     "ok": true,
     "technique": "gjk-epa-collision-detection",
     "runtime": "glsl-fragment",
     "checked_at": "2026-11-30T19:04:29.000Z",
     "renderer": "Headless EGL Tesla T4/PCIe/SSE2, OpenGL 3.30 Core, 512×512, iTime=1.5",
     "stats": {
      "mean": 0.3213,
      "std": 0.1794,
      "min": 0.1976,
      "max": 0.9053
     },
     "image": "/specimens/gjk-epa-collision-detection-live.webp",
     "reason": null
    }
   }
  }
 ],
 "related": [
  "sequential-impulses",
  "coacd-convex-decomposition",
  "three-mesh-bvh",
  "xpbd",
  "mujoco-articulated-dynamics"
 ],
 "extends": [],
 "supersedes": [],
 "combines_with": [
  {
   "id": "sequential-impulses",
   "why": "GJK/EPA output (normal, depth, witness points) becomes the contact constraints the impulse solver iterates over."
  },
  {
   "id": "coacd-convex-decomposition",
   "why": "Decomposition supplies the convex parts whose support functions GJK queries for concave objects."
  }
 ],
 "provenance": {
  "prose": "original text written for this index (research draft, editorially reviewed)",
  "sources_verified_at": "2026-11-29T15:51:27.588Z",
  "draft": "data/drafts/simulation/gjk-epa-collision-detection.json"
 },
 "solves": [
  "need overlap test between arbitrary convex colliders",
  "want penetration depth and normal for two hulls",
  "closest distance between two convex shapes for physics",
  "need a generic narrow phase using only support functions"
 ],
 "authority": "Gilbert et al., 1988",
 "url": "https://texelatlas.vercel.app/t/gjk-epa-collision-detection/",
 "execution_fidelity": "conceptual-diagram",
 "fidelity_label": "Visual Diagram",
 "benchmark_eligible": false,
 "gpu_weight": {
  "weight_x": 52.47,
  "tier": "heavy",
  "p50_ms": 1.6477,
  "p95_ms": 1.8002,
  "baseline_p50_ms": 0.0329,
  "gpu": "Tesla T4/PCIe/SSE2",
  "resolution": "1920x1080",
  "method": "opengl-timer-query",
  "frames": 40,
  "preset_id": "gjk-epa-collision-detection-live",
  "execution_fidelity": "conceptual-diagram",
  "fidelity_label": "Visual Diagram",
  "benchmark_eligible": false,
  "generated_at": "2026-11-30T21:07:47Z",
  "l4": {
   "weight_x": 55.7,
   "tier": "heavy",
   "p50_ms": 0.8801,
   "p95_ms": 0.9002,
   "speedup_x": 1.87,
   "gpu": "NVIDIA L4/PCIe/SSE2",
   "resolution": "1920x1080",
   "baseline_p50_ms": 0.0159
  },
  "a100": {
   "weight_x": 37.36,
   "tier": "heavy",
   "p50_ms": 1.076,
   "p95_ms": 1.0852,
   "speedup_x": 1.53,
   "gpu": "NVIDIA A100-SXM4-40GB/PCIe/SSE2",
   "resolution": "1920x1080",
   "baseline_p50_ms": 0.0288
  }
 }
}