Equation for Cube Edge-Lenth y that results in n-number of points with spacing x

39 Views Asked by At

I would need to find an equation that gives me the edge length l of a 3D cube that results in a specific number of points n inside the cube when their spacing is x. It's probably similar to the below but in 3D and simpler as edge length in XYZ is constant. For now, I assume that the point spacing x in XYZ is constant.

How to evenly space a number of points in a rectangle?

For constant d as described by @achille hui

l=x⌈(n^(1/3))−1⌉

How would this change for different x along different dimensions?