link_force: Attract or repel linked particles

link_forceR Documentation

Attract or repel linked particles

Description

This force works between linked particles and either attracts or repel them from each other depending on the value of the strength and distance parameters. The force is stronger the longer the linked particles are from each other, mimicking the mechanics of a rubber band.

Training parameters

The following parameters defines the training of the force and can be passed along a call to wield()

  • strength : The attractive force between the linked particles. The default weighs edges from low-degree particles higher (strength = 1 / (min(degree(from), degree(to)))). (tidy eval)

  • distance : The desired distance between linked particles. Defaults to 30 (tidy eval)

  • n_iter : The number of iteration towards the optimal solution per generation. Higher values leads to faster convergence (measured in number of generations) at the expense of longer computation time per generation. Defaults to 1.

See Also

Other forces: center_force, collision_force, field_force, manybody_force, map_force, mean_force, random_force, reset_force, trap_force, x_force, y_force


particles documentation built on Aug. 19, 2022, 5:06 p.m.