I own a gym. It’s not so much based on the square footage of your space as it is on how many members you have and what type of a gym it is. My gym is strictly private. I only have three cardio pieces. Other gyms I’ve been involved with had 3500 members and we had roughly 22 pieces of cardio.
Knowing peak time member usage is helpful to determine needed equipment, but there is no formula that I know of. Typically bikes and stair machines take up 24 sq. ft; rowers 40 sq ft; and treadmills 45 sq ft. These numbers included the space needed between pieces.