Comments (4)
The matter is that python doesn't show all the digits. If you print the lower and upper bound of your interval, you should have correct values
>>> c = pyIbex.exp(Interval(1))
>>> Interval.lb(c)
2.7182818284590433
>>> Interval.ub(c)
2.718281828459048
from pyibex.
Yes, as you can see, the interval boundaries cover a different interval than is written in the console. In these examples the intervals are disjoint, but should be subsets. Another example:
>>> 2 * pyIbex.asin(Interval(0, 1))
[0, 3.14159]
The interval covers π internally, which is good, but the output suggests that π is not contained in the interval.
from pyibex.
Thanks for reporting the issue.
I will work on that.
from pyibex.
The method str and repr can be overloaded to show more digits.
For instance with
def myPrint(itv):
return "[%3.16f, %3.16f]" % (itv.lb(), itv.ub())
Interval.__str__ = myPrint
print(Interval(2.3442, 21.3212) )
>>> [2.3441999999999998, 21.3212000000000010]
from pyibex.
Related Issues (13)
- Several arithmetic errors HOT 2
- clarify version number HOT 1
- Create a function from minibex file
- MSVisual Studio Build fails
- win64 error HOT 2
- include ibex and pybind version number
- FILIB_LIBRARY problème durant installation HOT 15
- Dependency on VIBes
- [install] linux "make install" HOT 1
- [doc] Add direct link to boost 1_58_0
- Can't pip install HOT 5
- libboost_python-py34.so.1.55.0 not found HOT 7
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pyibex.