title: I'm looking for an equation to plot a sphere in a 3D array
body: <p>I am making a game in Unity, coding in c#. The world is built from cubes (similar to minecraft), I store them in a 3D array of ints, whose values are later used to instantiate the actual cubes. I am working on filling the 3D array with different shapes.
  My knowledge of math is not very in depth and so I am having trouble with plotting the points of a sphere in the 3D array. Does anyone know an algorithm I could use?</p>