def c_bound_third_form(gibbs_risk, disagreement):
    """
    Compute the C-bound according to the Gibbs risk and
    the expected disagreement of a weighted set of voters.
    """
    return 1.0 - (1.0 - 2*gibbs_risk)**2 / (1.0 - 2*disagreement)