Skip to content

Commit

Permalink
PrincipalSurd::operator< for not optimized values
Browse files Browse the repository at this point in the history
  • Loading branch information
ohhmm committed Oct 8, 2024
1 parent 9d7bbd8 commit bd492c4
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions omnn/math/PrincipalSurd.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -163,10 +163,13 @@ bool PrincipalSurd::operator <(const Valuable& other) const {
} else {
power = _2 * ps._2;
}
} else if(_2 == constants::one) {
return other < _1;
} else {
power = _2;
}

OptimizeOn on;
return (*this ^ power) < (other ^ power);
}

Expand Down

0 comments on commit bd492c4

Please sign in to comment.