added isConnected(g,v1,v2)
added isComponent and modified isSubgraph