Skip to content

D3 force simulation parameters poorly tuned — nodes scatter #7

Closed

Description

@CalebisGross

Problem

`internal/web/static/index.html` lines ~1473-1477: Hardcoded force simulation parameters:

  • Charge strength: -300 (very strong repulsion)
  • Link distance: 80 (fixed regardless of graph size)
  • Center force: 0.05 (too weak to keep graph centered)
  • Collision radius: `(salience * 30) + 4` (arbitrary)

Impact

Nodes fly apart, cluster at edges, or overlap depending on dataset size. No meaningful spatial organization.

Fix

Make parameters adaptive based on node count, or expose them as configurable sliders.

Activity

  1. CalebisGross commented on Mar 10, 2026

    @CalebisGross
    CollaboratorAuthor

    Fixed in #42 — adaptive force parameters based on node count.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions