Framework for optimizing Network topology based on graph theory in Software-Defined Networking (SDN)