Adaptive Grid

Endpoint: https://studiobitonti.appspot.com/conformalGrid

The adaptive grid function generates a regular euclidean grid inside a given closed volume (container). Unlike the conformal grid this grid is built independent of the bounding volume and is modified after words to match the container’s shape.

Attributes:


Origin: A 3D float array defining the origin of the euclidean grid.
Volume: The .stp or .igs file name of the closed container.
Cell Size: Float indicating step size of the grid.
Output: Name of the resultant .json file storing the grid information.
T: [YOUR SECRET TOKEN]

Optional:

Direct Output: The input of true or false, defines whether to send content of result file directly instead of its storage location.
Unitize: The input of true or false,defines whether to redivide the surface in unitized way.

Methods:

.setCellSize(t):
-sets the step size of the euclidean grid filling the volume.

.setVolume(‘input.stp’):
-sets the closed volume that will be filled with the regularized grid.

.setOrigin([float, float, float]):
-sets the 3D origin point of the euclidean grid that will fill the volume.

.setGridOuput(‘grid.json‘):
-Sets the output file name of the adaptive grid that is created by the .genGrid() method

.genGrid(token):
-Generates the grid needed to populate the final lattice

Output:

A .json file listing the eight corners that define each cell.


Input Volume File Format

To create an adaptive grid structure you need a CLOSED polysurface/surface .stp or .igs file (shown below). Once you have uploaded the file, use the .setVolume() method to assign this volume to your adaptive lattice object.

 
Input: Sample Closed Volume

Input: Sample Closed Volume

 
genysis.upload("EXPORTS/handleVol.stp","volume.stp",token)
lattice = genysis.adaptiveLattice()
lattice.setVolume('volume.stp')

Once the volume is defined you can set the cell size and output file using the .setCellSize() and .setGridOuput() methods respectively. Finally use the .genGrid() method to generate the adaptive lattice grid.

lattice.setGridOutput('handleAdaptiveGrid.json')
lattice.setCellSize(7)
lattice.genGrid(token)

genysis.visualize('handleAdaptiveGrid.json',token,True)

Visualizing the grid you should see something like the screen shot below.

Ouput: Sample Output of Adaptive Lattice

Ouput: Sample Output of Adaptive Lattice

Sample Ouput: Adaptive Grid (left) vs Conformal Grid (right) output

Sample Ouput: Adaptive Grid (left) vs Conformal Grid (right) output

If the cells at the boundary are too distorted or squished. You can manipulate the origin of the adaptive grid to shift the cells in any direction using the .setOrigin() method.

lattice.setOrigin([0,-5,0])
lattice.genGrid(token)
Francis Bitonti