Grid
open class Grid<P : Position<P>> @JvmOverloads constructor(environment: Environment<*, P>, randomGenerator: RandomGenerator, xStart: Double, yStart: Double, xEnd: Double, yEnd: Double, xStep: Double, yStep: Double, xRand: Double = 0.0, yRand: Double = 0.0, xShift: Double = 0.0, yShift: Double = 0.0) : Deployment<P>
A (possibly randomized) grid of nodes.
Parameters
environment
the {@link Environment}Content copied to clipboard
random Generator
the {@link RandomGenerator}Content copied to clipboard
x Start
the start x positionContent copied to clipboard
y Start
the start y positionContent copied to clipboard
x End
the end x positionContent copied to clipboard
y End
the end y positionContent copied to clipboard
x Step
how distant on the x axis (on average) nodes should beContent copied to clipboard
y Step
how distant on the y axis (on average) nodes should beContent copied to clipboard
x Rand
how randomized should be positions along the x axisContent copied to clipboard
y Rand
how randomized should be positions along the y axisContent copied to clipboard
x Shift
how shifted should be positions between linesContent copied to clipboard
y Shift
how shifted should be positions along columnsContent copied to clipboard
Constructors
Functions
Link copied to clipboard
Returns the optional NetworkModel associated to the deployment, or null if there is none.
Link copied to clipboard
Returns a random element of the Iterable using the provided randomGenerator.
Link copied to clipboard
Fisher–Yates shuffle algorithm using a RandomGenerator. More information on Wikipedia.