## org.ascape.model.space
Class GraphSmallWorld

    java.lang.Object
      org.ascape.model.space.CollectionSpace
          org.ascape.model.space.Discrete
              org.ascape.model.space.Graph
                  org.ascape.model.space.GraphSmallWorld

All Implemented Interfaces:
  java.io.Serializable, java.lang.Cloneable, java.lang.Iterable, java.util.Collection, Space, RandomFunctions

    public class GraphSmallWorld

extends Graph

A 1D Small World version of the default Graph.

See Also:
  Serialized Form

Nested Class Summary

Nested classes/interfaces inherited from class org.ascape.model.space.CollectionSpace
`CollectionSpace.ClosestDataPoint, CollectionSpace.ConditionalIterator, CollectionSpace.CSIterator, CollectionSpace.CSMutableIterator, CollectionSpace.ListMutableRandomIterator, CollectionSpace.ListRandomIterator, CollectionSpace.MutableSubIterator, CollectionSpace.SubIterator`

Field Summary

Fields inherited from class org.ascape.model.space.Discrete
`performanceWarning`

Fields inherited from class org.ascape.model.space.CollectionSpace
`collection, ESTIMATED_MAXIMUM_SIZE, extent, geometry`

Constructor Summary
`GraphSmallWorld()` Constructs a one-dimensional small-world graph.
`GraphSmallWorld(CoordinateDiscrete extent)` Constructs a one-dimensional small-world graph.

Method Summary
`double` `getRandomEdgeRatio()` Gets the random edge ratio.
`void` `initialize()` Initialize.
`void` `setRandomEdgeRatio(double randomEdgeRatio)` Sets the random edge ratio.

Methods inherited from class org.ascape.model.space.Graph
`add, addNeighbor, addNeighbor, addNeighborSafe, calculateNeighbors, clear, clearNeighbors, findCellAway, findCellToward, findNearest, findNeighbors, getAdjacencyMap, getNeighborsFor, isNeighbor, neighborIterator, remove, removeNeighbor, replaceNeighbor, setAdjacencyMap, setNeighborsFor, withinIterator`

Methods inherited from class org.ascape.model.space.Discrete

`bfsWithinIterator, calculateDistance, calculateDistance, findAvailable, findAvailable, findCellAwayBFS, findCellTowardBFS, findNearestAvailable, findNearestBFS, findOccupants, findOccupants, findRandomAvailable, findRandomAvailable, findRandomAvailable, findRandomAvailableNeighbor, findRandomNeighbor, findRandomNeighbor, findRandomUnoccupiedCell, findRandomUnoccupiedCell, findWithinDefault, getCells, getCellsNearDefault, getDistance, getMaximumRank, getSize`

Methods inherited from class org.ascape.model.space.CollectionSpace

`add, addAll, calculateDistance, clone, conditionalIterator, conditionalIterator, construct, contains, containsAll, countWithin, createOrder, createSpatialConditional, deleteSweep, filter, find, findMaximum, findMaximum, findMaximumWithin, findMinimum, findMinimum, findMinimumWithin, findNearest, findRandom, findRandom, findRandom, findRandom, findRandomCoordinate, findRandomWithin, findWithin, get, getContext, getExtent, getGeometry, getRandom, hasWithin, isDeleteSweepNeeded, isEmpty, isMutable, isPeriodic, iterator, iteratorCount, iteratorToList, moveAway, moveToward, newLocation, newLocation, populate, randomInRange, randomInRange, randomIs, randomizeOrder, randomToLimit, removeAll, retainAll, safeIterator, safeIterator, safeIterators, safeRandomIterator, set, setContext, setExtent, setExtent, setGeometry, setPeriodic, setRandom, setSize, size, toArray, toArray, toList`

Methods inherited from class java.lang.Object
`equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Methods inherited from interface java.util.Collection
`equals, hashCode`

Constructor Detail

### GraphSmallWorld

    public GraphSmallWorld()

  Constructs a one-dimensional small-world graph.

### GraphSmallWorld

    public GraphSmallWorld(CoordinateDiscrete extent)

  Constructs a one-dimensional small-world graph.

  Parameters:
    `extent` - a coordinate describing the size of this space

Method Detail

### initialize

    public void initialize()

  Description copied from interface: `Space`
  Initialize.

  Specified by:
    `initialize` in interface `Space`
  Overrides:
    `initialize` in class `Graph`

### getRandomEdgeRatio

    public double getRandomEdgeRatio()

  Gets the random edge ratio.

  Returns:
    the random edge ratio

### setRandomEdgeRatio

    public void setRandomEdgeRatio(double randomEdgeRatio)

  Sets the random edge ratio.

  Parameters:
    `randomEdgeRatio` - the new random edge ratio