Module gengeo :: Class MNTable2D

[hide private]
[frames] | no frames]

# Class MNTable2D

     object --+
              |
    ??.instance --+
                  |
                 MNTable2D

Known Subclasses:
  - CircMNTable2D
  - , CircMNTableXY2D

A multi-group neighbour table for constructing 2D particle assemblies

Instance Methods | [hide private]

void

GrowNGroups(...) Expands the neighbour table to permit the specified number of particle groups |

__init__(...) Constructs a neighbour table with specified bounds, cell size and initial number of particle groups. |

__reduce__(...) helper for pickle |

__str__(...) str(x) |

void

breakBondsAlongLineSegment(...) Breaks bonds within the specified distance of the given line segment. |

void

generateBonds(...) Generates bonds between particle pairs separated by less than the specified tolerance |

void

generateBondsTaggedMasked(...) Generates bonds between particle pairs separated by less than the specified tolerance. |

void

generateBondsWithMask(...) Generates bonds between particle pairs separated by less than the specified tolerance. |

generateClusterBonds(...) Generates bonds between particle pairs separated by less than the specified tolerance. |

void

generateRandomBonds(...) Generates bonds between particle pairs separated by less than the specified tolerance. |

boost::python::list

getBondList(...) Returns a python list of bonds with the specified group ID as int-int pairs |

int

getNumParticles(...) Returns the number of the particles in the specified group. |

boost::python::list

getSphereListFromGroup(...) Returns a python list of Sphere objects with the specified group ID |

double

getSumVolume(...) Returns the sum of the particle areas in the specified group. |

insert(...) Inserts sphere |

insertBond(...) Inserts bond between particles with the specified particle IDs |

removeTaggedParticles(...) Removes particles with given tag and mask |

setOutputPrecision(...) Set the number of significant digits for file output |

void

tagClosestParticle(...) Assigns the specified tag to the particle which is closest to the given point. |

void

tagParticlesAlongLine(...) Assigns the specified tag to all particles from group `groupID` that lie within the specified distance of the given line. |

void

tagParticlesAlongLineSegment(...) Assigns the specified tag to all particles from group `groupID` that lie within the specified distance of the given line segment. |

void

tagParticlesAlongLineWithMask(...) Assigns the specified tag to all particles from group `groupID` that lie within the specified distance of the given line. |

void

tagParticlesInVolume(...) Assigns the specified tag to all particles from group `groupID` that lie within the specified volume. |

void

tagParticlesNear(...) Assigns the specified tag to all particles from group `groupID` that lie within the specified distance of the given point. |

tagParticlesToClosest(...) Tags particles in `groupID1` closest to spheres in `groupID2` |

void

write(...) Writes the particle assembly and bonding information to the specified file using the specified output style (0: debug; 1: geo; 2: vtk) |

Inherited from `unreachable.instance`: `__new__` Inherited from `object`: `__delattr__`, `__format__`, `__getattribute__`, `__hash__`, `__reduce_ex__`, `__repr__`, `__setattr__`, `__sizeof__`, `__subclasshook__`

Class Variables | [hide private]

| __instance_size__ = `128`

Properties | [hide private]

Inherited from `object`: `__class__`

Method Details | [hide private]

### GrowNGroups(...)

Expands the neighbour table to permit the specified number of particle groups

Parameters:
  - `numGroups` (int) - number of groups to create
Returns: void

### __init__(...)
(Constructor)

Constructs a neighbour table with specified bounds, cell size and initial number of particle groups.

Parameters:
  - `minPoint` (Vector3) - lower-left point of the particle region
  - `maxPoint` (Vector3) - upper-right point of the particle region
  - `gridSize` (double) - the cell size for neighbour searches
  - `numGroups` (unsigned int) - the initial number of groups (default: 1)
Overrides: object.__init__

### __reduce__(...)

helper for pickle

Overrides: object.__reduce__
  (inherited documentation)

### __str__(...)
(Informal representation operator)

str(x)

Overrides: object.__str__
  (inherited documentation)

### breakBondsAlongLineSegment(...)

Breaks bonds within the specified distance of the given line segment. Only bonds with the specified tag connecting particles in the specified group will be broken.

Parameters:
  - `lineSegment` (LineSegment2D) - the line segment along which to break bonds
  - `distance` (double) - the maximum distance between bonds and the line segment
  - `tag` (int) - the bond tag of bonds to break
  - `groupID` (unsigned int) - the group ID of particles whose bonds are broken (default: 0)
Returns: void

### generateBonds(...)

Generates bonds between particle pairs separated by less than the specified tolerance

Parameters:
  - `groupID` (int) - the group ID of particles to bond together (default: 0)
  - `tolerance` (double) - maximum distance separating bonded particles
  - `bondID` (int) - the bond ID to assign generated bonds
Returns: void

### generateBondsTaggedMasked(...)

Generates bonds between particle pairs separated by less than the specified tolerance. A tag mask is used to select groups of particles to tag.

Parameters:
  - `groupID` (int) - the group ID of particles to bond together (default: 0)
  - `tolerance` (double) - maximum distance separating bonded particles
  - `bondID` (int) - the bond ID to assign generated bonds
  - `tag1` (int) - the 1st particle tag
  - `mask1` (int) - the mask for the 1st particle tag
  - `tag2` (int) - the 2nd particle tag
  - `mask2` (int) - the mask for the 2nd particle tag
Returns: void

### generateBondsWithMask(...)

Generates bonds between particle pairs separated by less than the specified tolerance. A tag mask is used to select groups of particles to tag.

Parameters:
  - `groupID` (int) - the group ID of particles to bond together (default: 0)
  - `tolerance` (double) - maximum distance separating bonded particles
  - `bondID` (int) - the bond ID to assign generated bonds
  - `tag` (int) - the tag of particles to bond
  - `mask` (int) - the bond mask
Returns: void

### generateClusterBonds(...)

Generates bonds between particle pairs separated by less than the specified tolerance. Bonds generated between particles having the same particle tag are given tag `bondTag1` and bonds generated between particles of differing tags are given tag `bondTag2`

Parameters:
  - `groupID` (int) - the group ID of particles to bond together (default: 0)
  - `tolerance` (double) - maximum distance separating bonded particles
  - `bondTag1` (int) - the bond tag for bonds between particles with the same particle tag
  - `bondTag2` (int) - the bond tag for bonds between particles with differing particle tags

### generateRandomBonds(...)

Generates bonds between particle pairs separated by less than the specified tolerance. Bonds are generated between particle pairs with the prescribed probability.

Parameters:
  - `groupID` (int) - the group ID of particles to bond together (default: 0)
  - `tolerance` (double) - maximum distance separating bonded particles
  - `probability` (double) - probability that a particle-pair is bonded (0.0 < probability < 1.0)
  - `bondID` (int) - the bond ID to assign generated bonds
  - `tag` (int) - the tag of particles to bond
  - `mask` (int) - the bond mask
Returns: void

### getBondList(...)

Returns a python list of bonds with the specified group ID as int-int pairs

Parameters:
  - `groupID` (int) - the bond tag
Returns: boost::python::list

### getNumParticles(...)

Returns the number of the particles in the specified group.

Parameters:
  - `groupID` (int) - the group ID of the particles to count (default: 0).
Returns: int

### getSphereListFromGroup(...)

Returns a python list of Sphere objects with the specified group ID

Parameters:
  - `groupID` (int) - the group ID of spheres to return as a list (default: 0)
Returns: boost::python::list

### getSumVolume(...)

Returns the sum of the particle areas in the specified group.

Parameters:
  - `groupID` (int) - the group ID of particles whose areas are summed (default: 0).
Returns: double

### insert(...)

Inserts sphere

Parameters:
  - `sphere` (Sphere) - the sphere to insert
  - `groupID` (int) - the group ID of the inserted sphere (default: 0).

### insertBond(...)

Inserts bond between particles with the specified particle IDs

Parameters:
  - `Id1` (int) - ID of first particle to bond
  - `Id2` (int) - ID of second particle to bond
  - `tag` (int) - the bond tag to assign to the generated bond

### removeTaggedParticles(...)

Removes particles with given tag and mask

Parameters:
  - `groupID` (int) - the group ID of particles to remove (default: 0).
  - `tag` (int) - the tag of particles to remove.
  - `mask` (int) - the tag mask of particles to remove.

### setOutputPrecision(...)

Set the number of significant digits for file output

Parameters:
  - `precision` (int) - the number of significant digits (default: 10).

### tagClosestParticle(...)

Assigns the specified tag to the particle which is closest to the given point.

Parameters:
  - `point` (Vector3) - the point closest to the particle to be tagged
  - `tag` (int) - the tag to assign closest particle
  - `groupID` (unsigned int) - the group ID of particle to tag (default: 0)
Returns: void

### tagParticlesAlongLine(...)

Assigns the specified tag to all particles from group `groupID` that lie within the specified distance of the given line.

Parameters:
  - `line` (Line2D) - the line along which to tag particles
  - `distance` (double) - the maximum distance between tagged particles and the line
  - `tag` (int) - the tag to assign particles
  - `groupID` (unsigned int) - the group ID of particles to tag (default: 0)
Returns: void

### tagParticlesAlongLineSegment(...)

Assigns the specified tag to all particles from group `groupID` that lie within the specified distance of the given line segment.

Parameters:
  - `line` (Line2D) - the line along which to tag particles
  - `distance` (double) - the maximum distance between tagged particles and the line
  - `tag` (int) - the tag to assign particles
  - `mask` (int) - the mask - determines which bits of the tag are influenced
  - `groupID` (unsigned int) - the group ID of particles to tag (default: 0)
Returns: void

### tagParticlesAlongLineWithMask(...)

Assigns the specified tag to all particles from group `groupID` that lie within the specified distance of the given line.

Parameters:
  - `line` (Line2D) - the line along which to tag particles
  - `distance` (double) - the maximum distance between tagged particles and the line
  - `tag` (int) - the tag to assign particles
  - `mask` (int) - the mask - determines which bits of the tag are influenced
  - `groupID` (unsigned int) - the group ID of particles to tag (default: 0)
Returns: void

### tagParticlesInVolume(...)

Assigns the specified tag to all particles from group `groupID` that lie within the specified volume.

Parameters:
  - `volume` (AVolume) - the volume within which to tag particles
  - `tag` (int) - the tag to assign particles
  - `groupID` (unsigned int) - the group ID of particles to tag (default: 0)
Returns: void

### tagParticlesNear(...)

Assigns the specified tag to all particles from group `groupID` that lie within the specified distance of the given point.

Parameters:
  - `point` (Vector3) - the point around which to tag particles
  - `distance` (double) - the maximum distance between tagged particles and the specified point
  - `tag` (int) - the tag to assign particles
  - `groupID` (unsigned int) - the group ID of particles to tag (default: 0)
Returns: void

### tagParticlesToClosest(...)

Tags particles in `groupID1` closest to spheres in `groupID2`

Parameters:
  - `groupID1` (int) - the group ID of particles to tag (default: 0).
  - `groupID2` (int) - the group ID of closest spheres.

### write(...)

Writes the particle assembly and bonding information to the specified file using the specified output style (0: debug; 1: geo; 2: vtk)

Parameters:
  - `fileName` (string) - the name of the file to write
  - `outputStyle` (int) - output style (0: debug; 1: geo; 2: vtk)
Returns: void