From 3c9ac57920efc657aeb1094a773c76ffd5af5064 Mon Sep 17 00:00:00 2001 From: brahim Date: Tue, 1 Aug 2023 14:13:59 +0200 Subject: [PATCH] Concentration computation in % is added : (Ctot_fine / Ctot) and (Ctot_sand / Ctot) --- Model/granulo_loader.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/Model/granulo_loader.py b/Model/granulo_loader.py index 80d51ef..b7ea7e0 100644 --- a/Model/granulo_loader.py +++ b/Model/granulo_loader.py @@ -32,10 +32,15 @@ class GranuloLoader: self._frac_vol_sand_cumul = np.cumsum(self._frac_vol_sand, axis=1) # Cumulated volume fraction (%) + # --- Compute % of fine and % of sand sediment in total concentration --- + + self._Ctot_fine_per_cent = 100 * self._Ctot_fine / (self._Ctot_fine + self._Ctot_sand) + self._Ctot_sand_per_cent = 100 * self._Ctot_sand / (self._Ctot_fine + self._Ctot_sand) + if __name__ == "__main__": GranuloLoader("/home/bmoudjed/Documents/3 SSC acoustic meas project/Graphical interface project/Data/Granulo_data/" "fine_sample_file.ods", "/home/bmoudjed/Documents/3 SSC acoustic meas project/Graphical interface project/Data/Granulo_data/" - "fine_sample_file.ods") + "sand_sample_file.ods")