@@ -107,7 +107,7 @@ def _betainc_naive(a, b, x):
107
107
def _betainc_even_partial_numerator (iteration , a , b , x , dtype ):
108
108
"""Even partial numerator used in the continued fraction for betainc."""
109
109
# This function computes the partial numerator d_{2m} that is specified
110
- # here: https://dlmf.nist.gov/8.17# E23
110
+ # here: https://dlmf.nist.gov/8.17. E23
111
111
one = tf .constant (1. , dtype = dtype )
112
112
two = tf .constant (2. , dtype = dtype )
113
113
@@ -126,7 +126,7 @@ def _betainc_even_partial_numerator(iteration, a, b, x, dtype):
126
126
def _betainc_odd_partial_numerator (iteration , a , b , x , dtype ):
127
127
"""Odd partial numerator used in the continued fraction for betainc."""
128
128
# This function computes the partial numerator d_{2m + 1} that is specified
129
- # here: https://dlmf.nist.gov/8.17# E23
129
+ # here: https://dlmf.nist.gov/8.17. E23
130
130
one = tf .constant (1. , dtype = dtype )
131
131
two = tf .constant (2. , dtype = dtype )
132
132
@@ -283,7 +283,7 @@ def _betainc_der_continued_fraction(a, b, x, dtype, use_continued_fraction):
283
283
# This continued fraction expansion of betainc converges rapidly
284
284
# for x < (a - 1) / (a + b - 2). For x >= (a - 1) / (a + b - 2),
285
285
# we can obtain an equivalent computation by using the symmetry
286
- # relation given here: https://dlmf.nist.gov/8.17# E4
286
+ # relation given here: https://dlmf.nist.gov/8.17. E4
287
287
# betainc(a, b, x) = 1 - betainc(b, a, 1 - x)
288
288
use_symmetry_relation = (x >= (a - one ) / (a + b - two ))
289
289
a_orig = a
@@ -317,7 +317,7 @@ def _betainc_der_power_series(a, b, x, dtype, use_power_series):
317
317
"""Returns the partial derivatives of betainc with respect to a and b."""
318
318
# This function evaluates betainc(a, b, x) by its series representation:
319
319
# x ** a * 2F1(a, 1 - b; a + 1; x) / (a * B(a, b)) ,
320
- # where 2F1 is defined here: http://dlmf.nist.gov/15.2.i
320
+ # where 2F1 is the Gauss series as defined here: http://dlmf.nist.gov/15.2.i
321
321
# We apply this function when the input (a, b, x) satisfies at least one
322
322
# of the following conditions:
323
323
# C1: (x < a / (a + b)) & (b * x <= 1) & (x <= 0.95)
@@ -334,7 +334,7 @@ def _betainc_der_power_series(a, b, x, dtype, use_power_series):
334
334
safe_x = tf .where (use_power_series , x , half )
335
335
336
336
# When the condition C1 is false, we apply the symmetry relation given
337
- # here: https://dlmf.nist.gov/8.17# E4
337
+ # here: https://dlmf.nist.gov/8.17. E4
338
338
# betainc(a, b, x) = 1 - betainc(b, a, 1 - x)
339
339
use_symmetry_relation = (safe_x >= safe_a / (safe_a + safe_b ))
340
340
safe_a_orig = safe_a
0 commit comments