Skip to content

Commit 462c8d7

Browse files
committed
Improve normal form liap
1 parent 9161340 commit 462c8d7

File tree

1 file changed

+1
-6
lines changed

1 file changed

+1
-6
lines changed

src/solvers/liap/nfgliap.cc

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -38,12 +38,7 @@ class StrategicLyapunovFunction : public FunctionOnSimplices {
3838
: m_game(p_start.GetGame()), m_profile(p_start)
3939
{
4040
m_scale = m_game->GetMaxPayoff() - m_game->GetMinPayoff();
41-
if (m_scale == 0.0) {
42-
m_scale = 1.0;
43-
}
44-
else {
45-
m_scale = 1.0 / m_scale;
46-
}
41+
m_scale = (m_scale == 0.0) ? 1.0 : 1.0 / m_scale;
4742
}
4843
~StrategicLyapunovFunction() override = default;
4944

0 commit comments

Comments
 (0)