1 #ifndef MagneticFieldHelpers_h
2 #define MagneticFieldHelpers_h
9 namespace magneticFieldHelpers {
13 int zeroFieldThreshold = 1000;
14 float nominalCurrents[5] = {9558,14416,16819,18268,19262} ;
15 int nominalFields[5] = {20,30,35,38,40} ;
16 if(current < zeroFieldThreshold)
return 0;
20 if(2*current < nominalCurrents[i]+nominalCurrents[i+1] )
21 return nominalFields[
i];
23 return nominalFields[
i];
42 #endif // MagneticFieldHelpers_h
int closerNominalField(float current)
Return the closer nominal field value (kGauss) to a given magnet current (A)