NanoComp / meep

free finite-difference time-domain (FDTD) software for electromagnetic simulations
GNU General Public License v2.0
1.17k stars 598 forks source link

Add note in docs for array slices that output is always centered on the Yee cell #2605

Closed oskooi closed 11 months ago

oskooi commented 11 months ago

In the documentation for output_dft, it is mentioned that:

Note that although the various field components are stored at different places in
the Yee lattice, when they are outputted they are all linearly interpolated to the 
same grid: to the points at the centers of the Yee cells, i.e. (i+0.5,j+0.5,k+0.5)⋅Δ
in 3d.

However, there is no such description for the array-slice routines get_array and get_dft_array. This interpolation feature is an important part of Meep's design philosophy of ensuring (for the user) an illusion of continuity.