I tried measuring distances between Circles [i.e. between intersections of Circles with yellow center-to-center Lines], comparing horizontal to diagonal where the yellow-Lines variance occurs, and the ones I checked were the same, so I wondered why the yellow Lines vary in length. In the process I found that your Circles are not all of the same radius. With two selected:

Some of them share a common radius, but there are a variety of slightly different sizes. That "allows" the variation in center-to-center Line lengths even if the spaces between are equal.
I really believe what you want is not going to be possible in most instances, if your intent is to specify L & W & D. For example, I set up a simple situation in which all the X dimensions and the Circle radius are 1 drawing unit, and I sized the rectangle around them to make that true, rather than starting from a specified rectangle size:

[The odd-ball decimal component of the vertical dimension, rounded to 3 decimal places, is because the sine of 60° is involved.]
Now suppose a routine is defined, and you ask it to do its thing in a rectangle 8.5 units wide as above, but 7 units tall. It could use the same arrangement of Circles to have their distances from each other [which must always be in 0°- and 60°-angle displacements] and to the sides of the rectangle remain at 1 unit. But it will simply not be possible for the distance from the Circles to the top and bottom of the rectangle to also be 1 unit [that is, not to both top and bottom -- it can be to one of them if you want]. Something will have to give -- you can't avoid having some variance between either the distances from the edges or the spacings/angles between the Circles. You can get the desired result only in rectangles whose dimensions happen to have that kind of magical relationship to the Circle radius and the sine of 60°.
Kent Cooper, AIA