|At each site, IGG has many buildings, with modern means of communication connecting them. Unfortunately these communication lines all depend on electricity. In case of a blackout, transmitting management orders becomes impossible using those channels. Off the shelf backup communication systems are extremely expensive, and the CEO has realized IGG is already manufacturing all the important components of an alternative solution: cannons, gunpowder, titanium capsules, paper and pen. The idea is to place a single cannon near the HQ and fire orders in the direction of each building. In case of emergency, the typical usage is to send the same message to all buildings with the smallest amount of effort.||
Your task is to determine the optimal placement of the cannon (on each of the 10 sites of the company) to minimize the energy required to broadcast orders.
The energy required for a single shot is quadratic in the launch velocity v of the capsule, ie.
E = const * v * v
The elevation and direction of the cannon barrel can be easily set as well as v. The broadcast cost is the sum of the energies of all shots with optimal cannon settings.
Careful measurements show that the aerodynamic drag can be discarded and the maximum range of the cannon is larger than the distance between any two buildings.
5 -3.7 0.5 1.2 7.7 4.8 -7.7 -2.3 -0.9 5.2 3.4