public void computeRoutingTables(int iterations,boolean splitHorizon){
			String msg = "Calculating "+iterations+" iteration(s).";
			if(splitHorizon){ 
				msg += "\nSplit Horizon enabled.";	
			}
			else {
				msg += "\nSplit Horizon disabled.";
			}
			System.out.println(msg);
			
			for(int i=0;i<iterations;i++){
				boolean updated = false;
				this.currentIteration++;
				System.out.println("iteration: "+(i+1));
				for(Node n : nodes){
					updated = n.updateRoutingTable(); 	
				}
				if(!updated && i==0){ //after the first iteration, nothing has changed. So already stable
					System.out.println("Network already stable. ");
					return;
				}
				if(!updated){ //no changed to any routing table were made in the last iteration
					System.out.println("Network converged at "+i+".");
					return;
				}
			}
		}