Skip to content

[BUG] bisect returning ValueError: f(a) and f(b) must have different signs #79

@jayGG83

Description

@jayGG83

Im trying to use inverse_rain_attenuation function from ITU-R P.530 but I'm getting this error:

File "./lib/link_budget.py", line 341, in inverse_rain_attenuation return bisect(func_bisect, 0.000001, 100) File ".venv/lib/python3.10/site-packages/scipy/optimize/_zeros_py.py", line 557, in bisect r = _zeros._bisect(f, a, b, xtol, rtol, maxiter, args, full_output, disp) ValueError: f(a) and f(b) must have different signs

Here is an example:

from itur.models.itu530 import inverse_rain_attenuation
f = 22.5   # Link frequency
d = 2.6  # Distance
el = 60  # Elevation angle constanf 60 degrees
Ap = 30  #Fade depth
lat = 50.3515944444
lon = 10.9511027778
inverse_rain_attenuation(lat, lon, d, f, el, Ap, tau=90, R001=None)

Thanks in advance

Metadata

Metadata

Labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions