Skip to main content

Function: springForceConstant()

springForceConstant(n, scale): number

Defined in: src/mobjects/graph/layoutAlgorithms.ts:126

Compute the Fruchterman-Reingold force constant k for n vertices. It is the optimal distance between two vertices for the given scale.

Parameters​

n​

number

scale​

number

Returns​

number