From 2c14a842deb68db2e3d929550f21416f501a9c05 Mon Sep 17 00:00:00 2001
From: Vincent Texier <vit@free.fr>
Date: Sat, 13 Jun 2015 10:49:33 +0200
Subject: [PATCH] Fix actual growth rate calculation in informations using
 N(t-1)

---
 res/i18n/ts/fr_FR.ts                 | 7 ++++++-
 src/cutecoin/gui/informations_tab.py | 4 ++--
 2 files changed, 8 insertions(+), 3 deletions(-)

diff --git a/res/i18n/ts/fr_FR.ts b/res/i18n/ts/fr_FR.ts
index 15f90e31..f74627f3 100644
--- a/res/i18n/ts/fr_FR.ts
+++ b/res/i18n/ts/fr_FR.ts
@@ -887,7 +887,7 @@ Revoking your UID can only success if it is not already validated by the network
     <message>
         <location filename="../../../src/cutecoin/gui/informations_tab.py" line="72"/>
         <source>Actual growth c = UD(t)/[M(t-1)/N(t)]</source>
-        <translation>Croissance actuelle c = DU(t)/[M(t -1)/N(t)]</translation>
+        <translation type="obsolete">Croissance actuelle c = DU(t)/[M(t -1)/N(t)]</translation>
     </message>
     <message>
         <location filename="../../../src/cutecoin/gui/informations_tab.py" line="72"/>
@@ -1071,6 +1071,11 @@ Revoking your UID can only success if it is not already validated by the network
         <source>UD(t+1) = MAX { UD(t) ; c * M(t) / N(t+1) }</source>
         <translation type="obsolete">DU(t+1) = MAX { DU(t) ; c * M(t) / N(t+1) }</translation>
     </message>
+    <message>
+        <location filename="../../../src/cutecoin/gui/informations_tab.py" line="72"/>
+        <source>Actual growth c = UD(t)/[M(t-1)/N(t-1)]</source>
+        <translation type="unfinished">Croissance actuelle c = DU(t)/[M(t -1)/N(t-1)]</translation>
+    </message>
 </context>
 <context>
     <name>MainWindow</name>
diff --git a/src/cutecoin/gui/informations_tab.py b/src/cutecoin/gui/informations_tab.py
index 93db5e17..14d42f3d 100644
--- a/src/cutecoin/gui/informations_tab.py
+++ b/src/cutecoin/gui/informations_tab.py
@@ -91,9 +91,9 @@ class InformationsTabWidget(QWidget, Ui_InformationsTabWidget):
                     localized_mass_per_member,
                     self.tr('Monetary Mass per member M(t)/N(t) in'),
                     self.get_referential_diff_name(),
-                    block['dividend'] / (block_t_minus_1['monetaryMass'] / block['membersCount']),
+                    block['dividend'] / (block_t_minus_1['monetaryMass'] / block_t_minus_1['membersCount']),
                     params['dt'] / 86400,
-                    self.tr('Actual growth c = UD(t)/[M(t-1)/N(t)]'),
+                    self.tr('Actual growth c = UD(t)/[M(t-1)/N(t-1)]'),
                     QLocale.toString(
                         QLocale(),
                         QDateTime.fromTime_t(block['medianTime'] + params['dt']),
-- 
GitLab