subdivide | R Documentation |
From the input particles ID's place the particles into a 3 x 3 x 3 grid with a side length of Grid.L/(3^n) around the center given. With the given grid then calculate the curl around the defined center.
This processes is continued recursively on a progressively more refined (smaller) grid with the center moving across the box containing all particles within in the halo (the center moves as a fraction of Grid.L)
subdivide( n = 1, center = c(0, 0, 0), id = seq_along(ID.table$RX), ntot = 0, noise = T, flag = F, Grid.L = Global.L )
n |
The layer of grid refinement and corresponds to the index in the Storage list |
center |
The center which the grid is defined around given in physical coordinates |
id |
A vector containing all the particle IDs which the grid is placed over. |
ntot |
A running total value for subdivision number taking place. Naturally set to 0 |
noise |
A boolean value determining if numerical noise should be calculated in determining the curl of the velocity field. It is naturally set to True. Set to False to reduce computational time when generating movies |
flag |
A boolean value determining if the flagged cells should be tracked, if True then a data.table is maintained showing all cells that where subdivided. Naturally set to False as it slows down computational time. |
Grid.L |
A value to define the length of one side of the total grid or mesh. |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.