Adjusting vertex and network class to polymorphism

The vertex class now have operator() as a virtual function
so it can return the correct type.
Network Now returns the correct type for operator()
Adding a comment on vertex virtual function