Skip to content

D3 force simulation parameters poorly tuned — nodes scatter #7

@CalebisGross

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.

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