In blender you can use Drivers.
1) In N-panel click RMB on scale and in context menu select Drivers -> Manually create later. Scale will be pink-colored
2) Open Graph Editor in Drivers Mode
3) Chose X Scale, remove all dots from curve and draw a new one (CTRL+LMB to add a dot) You can perfectly align it using Active keyframe tab.
Here will be your curve, last 2 dots must have 0 Value, to make object completely invisible in long distance.
Horizontal will be distance between objects, vertical - Scale.
4) Goto Drivers Tab
5) Setup settings:
Type - Averaged Value
Var type - Distance
Object 1 & 2 - is your current object and object-controller.
6) In N-panel RMB-click on X scale and in context menu select Copy Driver. When Paste Driver in Y and Z Scale.
7) Finally copy your objects in a grid or any pattern:
See also: For more advanced cases you can use node-based visual programing: animation nodes