Loading…

Method Name: cut_throat_flume_method_max_flowrate

Method ID: 0x4200

Method Label: Calculate Max Flowrate

Method Help: Calculates Maximum Flowrate (Qmax) value


  • {
  • float flowratecalculated;
  • float headconvertedcutthroat;
  • float cutthroatwidthconverted;
  • char disp_string1[135];
  • int slen1;
  • slen1 = 135;
  • _set_device_status(0xFF,0);
  • _set_xmtr_device_status(0xFF,0);
  • _set_all_resp_code(0);
  • _set_xmtr_all_resp_code(0);
  • _get_dictionary_string(19726337,disp_string1,slen1);
  • ACKNOWLEDGE(disp_string1);
  • _add_abort_method(4118);
  • if (Distance_Obj_unit == 44)
  • {
  • headconvertedcutthroat = span_Obj_value_0 * 0.3048;
  • }
  • else
  • if (Distance_Obj_unit == 45)
  • {
  • headconvertedcutthroat = span_Obj_value_0 * 1;
  • }
  • else
  • if (Distance_Obj_unit == 47)
  • {
  • headconvertedcutthroat = span_Obj_value_0 * 0.0254;
  • }
  • else
  • if (Distance_Obj_unit == 48)
  • {
  • headconvertedcutthroat = span_Obj_value_0 * 0.01;
  • }
  • else
  • if (Distance_Obj_unit == 49)
  • {
  • headconvertedcutthroat = span_Obj_value_0 * 0.001;
  • }
  • if ((cutthroat_length_meters == 1 || cutthroat_length_in == 1 || cutthroat_length_ft == 1 || cutthroat_length_mm == 1 || cutthroat_length_cm == 1) && (cutthroat_width_ft_1 == 1 || cutthroat_width_meters_1 == 1 || cutthroat_width_in_1 == 1 || cutthroat_width_cm_1 == 1 || cutthroat_width_mm_1 == 1))
  • {
  • cutthroatwidthconverted = 0.025;
  • flowratecalculated = 3.725 * (pow(cutthroatwidthconverted,1.025) * pow(headconvertedcutthroat,2.15));
  • }
  • if ((cutthroat_length_meters == 1 || cutthroat_length_in == 1 || cutthroat_length_ft == 1 || cutthroat_length_mm == 1 || cutthroat_length_cm == 1) && (cutthroat_width_ft_1 == 2 || cutthroat_width_meters_1 == 2 || cutthroat_width_in_1 == 2 || cutthroat_width_cm_1 == 2 || cutthroat_width_mm_1 == 2))
  • {
  • cutthroatwidthconverted = 0.051;
  • flowratecalculated = 3.725 * (pow(cutthroatwidthconverted,1.025) * pow(headconvertedcutthroat,2.15));


Please login for more