Changes between Version 13 and Version 14 of u/erica/CylindricalGravity
- Timestamp:
- 01/07/15 11:42:37 (10 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
u/erica/CylindricalGravity
v13 v14 72 72 -1 corresponds to left/down, and +1 to right/up. So this states the 1st cell in the stencil (m=1) has a position to the left of the center cell in the i=1 (x) direction, and the 2nd cell is to the right. The 3rd and 4th cell has a 0 offset in x (because they are above and below the center cell). This is why their offsets are listed in the 2nd row of the table. Again, the center cell itself (m=0) has 0 offsets from itself in both directions. 73 73 74 The stencil values are also set here for regular, Cartesian geometry. They need to be modified later in the code for use with 2.5 geometry. 75 76 '''Stencil values''' is an (0:2*ndim) array. For 2D then, stencil values is 5 elements long. It is initialized with the following values which are the coefficients for the Poisson matrix equation described above for Cartesian geometry: 77 78 '''Stencil values (m) = ''' 79 80 || m || 0 || 1 || 2 || 3 || 4 || 5 || 81 || stencil values(m)|| -4 || 1 || 1 || 1 || 1 || 1 ||