Skip to content

Conversation

@s-tikhomirov
Copy link
Contributor

The updated formula more precisely accounts for the fact that on the first step D new nodes learn about the message, and in all subsequent steps D-1 new nodes do. I consider a geometric sequence and use the formula for the partial sum of such sequence. In our case, the number of nodes that learn the message in total after n steps is 1 + D + D(D-1) + D(D-1)^2 + .... We can view it as 1 + <partial sum of a geometric sequence> with the first element D and coefficient (D-1). Re-shuffling the terms, I get (in Python notation):

    numerator = log(((n - 1) * (d - 2) / d) + 1)
    denominator = log(d - 1)
    h_max = ceil(numerator / denominator)

which is I use for for figure.

Note: we ignore the case of D=2 because it's an outlier: it corresponds to an arithmetic sequence, not geometric one. Example: a circular topology. Then, for N=1000, we'd need ~500 steps: each step infects just two new nodes. This is unrealistic for Waku, therefore I suggest we omit it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants