def _evaluate_gear_box_torque_in(min_engine_on_speed, gear_box_torque,
    gear_box_speed_in, gear_box_speed_out, gear_box_efficiency_parameters):
    """
    Calculates torque required according to the temperature profile [N*m].
    """
    tgb, es, ws = gear_box_torque, gear_box_speed_in, gear_box_speed_out
    par = gear_box_efficiency_parameters
    if tgb < 0 < es and ws > 0:
        return (par['gbp01'] * tgb - par['gbp10'] * ws - par['gbp00']
            ) * ws / es
    elif es > min_engine_on_speed and ws > min_engine_on_speed:
        return (tgb - par['gbp10'] * es - par['gbp00']) / par['gbp01']
    return 0
