Algorithm/ants, common: added ID to element class + network, ants bugfix

Element's ID is used to uniquely identify the elements when it is added
to a set. Adding this parameter is the best way to implement
Network::operator=, Network::assign and copy constructor.
These functions now work correctly (fixed a bug when links were binding
elements in a wrong way).
This change had also fixed a bug in the ant algorithm which caused the release version to work
incorrectly.

Signed-off-by: Artem Plakunov <artacc@lvk.cs.msu.su>