Finite graphs and networks : an introduction with applications