Skip to content
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

Update collection.cpp #4

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions collection.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -614,7 +614,7 @@ void collection::initSeeding(map<int, tdListEntry> &tdList) {
if (deltaR < 0) {
It->second.seed = tdListIt->second.rating;
int dayCount = boost::gregorian::date_period(tdListIt->second.lastRatingDate, tournamentDate).length().days();
It->second.sigma = sqrt(tdListIt->second.sigma * tdListIt->second.sigma + 0.0005 * 0.0005 * dayCount * dayCount);
It->second.sigma = sqrt(tdListIt->second.sigma * tdListIt->second.sigma + 0.001 * 0.001 * dayCount * dayCount);
}
// Is this a self promotion by more than three stones?
// If so, treat as a reseeding. Players must win at least one game
Expand All @@ -632,7 +632,7 @@ void collection::initSeeding(map<int, tdListEntry> &tdList) {
else {
It->second.seed = tdListIt->second.rating;
int dayCount = boost::gregorian::date_period(tdListIt->second.lastRatingDate, tournamentDate).length().days();
It->second.sigma = sqrt(tdListIt->second.sigma * tdListIt->second.sigma + 0.0005 * 0.0005 * dayCount * dayCount);
It->second.sigma = sqrt(tdListIt->second.sigma * tdListIt->second.sigma + 0.001 * 0.001 * dayCount * dayCount);
}
}
// cout << "Seed: " << It->second.id << '\t' << It->second.seed << '\t' << It->second.sigma << endl;
Expand Down