-
Notifications
You must be signed in to change notification settings - Fork 462
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Exchangerate #2222
Exchangerate #2222
Conversation
consensus/misc/rewards.go
Outdated
// spaces = [{"K Qi": state["K Qi"], "K Quai": k_quai}, spaces[1]] | ||
// return spaces | ||
func CalculateKQuai(primeTerminus *types.WorkObject, header *types.WorkObjectHeader, beta0 *big.Int, beta1 *big.Int) *big.Int { | ||
kQuai := new(big.Int).Set(primeTerminus.ExchangeRate()) // in Its |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we can only calculate KQuai in Prime right? so its not prime terminus exchange rate, it should be the parent exchange rate
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
consensus/misc/rewards.go
Outdated
// return spaces | ||
func CalculateKQuai(primeTerminus *types.WorkObject, header *types.WorkObjectHeader, beta0 *big.Int, beta1 *big.Int) *big.Int { | ||
kQuai := new(big.Int).Set(primeTerminus.ExchangeRate()) // in Its | ||
d2 := LogBig(header.Difficulty()) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
do we not need d1 here ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you have it below, it would be nice to have this done based on the pseudo-code above, hard to follow otherwise, might be good to do it as part of clean up or think might be hard to debug as well
de72d16
to
62e4f15
Compare
606639c
to
a55ba0f
Compare
a55ba0f
to
df891a0
Compare
No description provided.