This fork is primarily used for logging of the Fiedler eigenvalue and degree (number of connected components) over time. Since it logs this every iteration, usage may be slower than in other examples. For better performance, see Flocking V.
There are two basic types of parameters used: initial conditions and agent parameters. Agent parameters can be updated any time, including while in play. Initial conditions however require a reset before they take effect.
Note: If an initial condition is changed then the
Reset
button will turn yellow, indicating that a reset is required before some changes take effect.
Group 1
and Group 2
agents. Agents from the second group are rendered as the larger dots.k
nearest neighbors outside of the zone of orientation for their attraction vector.[0, 180]
) where the agent can not adjust their direction vector greater than this number for an individual iterationPlay
button to start animationPause
button to stop animationNext
button to do one time step of the algorithm.Dragging/Zooming behavior forked from mbostock's block: Drag & Zoom II
forked from lwthatcher's block: Directional Forces
forked from lwthatcher's block: Flocking
forked from lwthatcher's block: Flocking II
forked from lwthatcher's block: Flocking III
forked from lwthatcher's block: Flocking IV
forked from ojaneeo's block: Flocking IV
forked from lwthatcher's block: Flocking V
Modified http://www.numericjs.com/lib/numeric-1.2.6.js to a secure url
https://ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.min.js
https://www.numericjs.com/lib/numeric-1.2.6.js
https://gitcdn.github.io/bootstrap-toggle/2.2.2/js/bootstrap-toggle.min.js
https://d3js.org/d3.v4.min.js