disk_grid


disk_grid, an Octave code which generates a grid of points over the interior of a disk in 2D.

The library allows the user to define an arbitrary disk by choosing its radius and center. The user also chooses N, the number of subintervals into which the horizontal radius line will be subdivided. It then returns the gridpoints defined by that choice.

Another function allows the user to specify that N points on a Fibonacci spiral are to be placed within the disk.

The test program creates input files to GNUPLOT which will create graphic images of the grids.

Licensing:

The computer code and data files described and made available on this web page are distributed under the MIT license

Languages:

disk_grid is available in a C version and a C++ version and a Fortran90 version and a MATLAB version and an Octave version and a Python version.

Related Data and Programs:

disk_grid_test

disk_integrals, an Octave code which returns the exact value of the integral of any monomial over the interior of a disk of radius R centered at the origin.

matlab_grid, an Octave code which generates a regular grid of points inside a variety of regions in one, two, three or many dimensions.

Reference:

  1. Richard Swinbank, James Purser,
    Fibonacci grids: A novel approach to global modelling,
    Quarterly Journal of the Royal Meteorological Society,
    Volume 132, Number 619, July 2006 Part B, pages 1769-1793.

Source Code:


Last revised on 06 January 2019.