Browse Source

Added simple function with centrality determination

PeterParfenov 2 years ago
parent
commit
3f9204a322
1 changed files with 20 additions and 0 deletions
  1. 20 0
      Mult2Cent.c

+ 20 - 0
Mult2Cent.c

@@ -0,0 +1,20 @@
+//
+// Created by peter on 8/27/19.
+//
+
+// Based on 200 GeV Au+Au PHSD
+int cent8(int mult)
+{
+  int fcent;
+  if (mult >= 671) fcent = 0; // 0-10%
+  if (mult >= 402 && mult < 671) fcent = 1; //10-20%
+  if (mult >= 245 && mult < 402) fcent = 2; //20-30%
+  if (mult >= 146 && mult < 245) fcent = 3; //30-40%
+  if (mult >= 80 && mult < 146)  fcent = 4; //40-50%
+  if (mult >= 38 && mult < 80)   fcent = 5; //50-60%
+  if (mult >= 16 && mult < 38)   fcent = 6; //60-70%
+  if (mult >= 6 && mult < 16)    fcent = 7; //70-80%
+
+  return fcent;
+}
+