zero_plus_switching_double Function

private function zero_plus_switching_double(weights, bVal, negSwitches, posSwitches) result(prob)

Arguments

Type IntentOptional Attributes Name
type(WeightObj_t), intent(in) :: weights
real(kind=dp), intent(in) :: bVal
real(kind=dp), intent(in) :: negSwitches
real(kind=dp), intent(in) :: posSwitches

Return Value real(kind=dp)


Contents


Source Code

    function zero_plus_switching_double(weights, bVal, negSwitches, posSwitches) result(prob)
        type(WeightObj_t), intent(in) :: weights
        real(dp), intent(in) :: bVal, negSwitches, posSwitches
        real(dp) :: prob

        real(dp) :: plus, zero

        zero = weights%proc%zero(negSwitches, posSwitches, bVal, weights%dat)
        plus = weights%proc%plus(posSwitches, bVal, weights%dat)

        prob = 1.0_dp - calcStayingProb(zero, plus, bVal)

    end function zero_plus_switching_double