Skip to content

Conversation

@0xstan
Copy link

@0xstan 0xstan commented Mar 11, 2022

What I did

Fixed a mistake in code comments. Missing an item from the formula.

How I did it

Modify code comments with adding an item in formula.

+ (n+1)*D[j]**n/(n**n prod(x_i))

How to verify it

the correct newton's method formula is

There is an missing item in origin code comments.

@chanhosuh
Copy link

Actually the numerator isn't correct either.

The whole thing should be:
D[j+1] = (A * n**n * sum(x_i) + n * D[j]**(n+1) / (n**n prod(x_i))) / (A * n**n + (n+1)*D[j]**n/(n**n prod(x_i)) - 1)

To get the calculation in the code, you need to replace A * n**n by Ann and D[j]**(n+1)/(n**n prod(x_i)) by D_p.

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