I urgently need help with below, have two questions (one based on the original algorithm and a second set of questions based on what I want to do) and would greatly appreciate if someone could help me with them:
I have an implementation of a greedy routing algorithm (computer networking) and need to discuss the complexity. With the original greedy routing algorithm, devices (nodes) offload data (packets) to one of their neighbour nodes by choosing the neighbour node that makes the greatest forward progress towards the destination i.e. achieves the greatest distance.
Based on what Iíve read the complexity is described as follows:
For a node u with a set of neighbours N(u), the complexity of calculating the distance from u to any uís neighbours is O(|N(u)|). If is the Δ average node degree, the computational complexity of the algorithm for each node can be generalised as O(Δ 2). Question 1: I think this should be O(Δ) not O( Δ2). Am I correct?
So Iíve modified the algorithm so that not only will a node u will still check the distance to all of its neighbours but if one of those neighbours is a non-moving node (lets call it r), u checks the distance between r and all of rís non moving neighbours Nr(r). Question 2: How do I represent this with O notation? O(Δ + x) where x is the average non moving neighbour degree? (Side note I donít think this is correct given that node u would usually only have one/two non moving neighbours or indeed often none at all).
Many thanks in advance.