All Projects → Chris00 → ocaml-interval

Chris00 / ocaml-interval

Licence: LGPL-3.0 license
An interval library for OCaml

Programming Languages

ocaml
1615 projects
c
50402 projects - #5 most used programming language

Projects that are alternatives of or similar to ocaml-interval

OpenSkyStacker
Multi-platform stacker for deep-sky astrophotography.
Stars: ✭ 80 (+471.43%)
Mutual labels:  scientific-computing
aprenda-python
Aprendizado, dicas e projetos sobre Python
Stars: ✭ 22 (+57.14%)
Mutual labels:  scientific-computing
PyRates
Open-source, graph-based Python code generator and analysis toolbox for dynamical systems (pre-implemented and custom models). Most pre-implemented models belong to the family of neural population models.
Stars: ✭ 33 (+135.71%)
Mutual labels:  scientific-computing
jigsaw-python
Python bindings for JIGSAW: a Delaunay-based unstructured mesh generator.
Stars: ✭ 24 (+71.43%)
Mutual labels:  scientific-computing
flambeau
Nim bindings to libtorch
Stars: ✭ 60 (+328.57%)
Mutual labels:  scientific-computing
mdct
A fast MDCT implementation using SciPy and FFTs
Stars: ✭ 42 (+200%)
Mutual labels:  scientific-computing
datajoint-python
Relational data pipelines for the science lab
Stars: ✭ 140 (+900%)
Mutual labels:  scientific-computing
payton
Payton! Kickstart any 3D OpenGL + GTK Ideas in a few seconds!
Stars: ✭ 45 (+221.43%)
Mutual labels:  scientific-computing
Numerical-Algorithms
Numerical Experiments
Stars: ✭ 15 (+7.14%)
Mutual labels:  scientific-computing
numericalgo
numericalgo is a set of numerical methods implemented in Golang.
Stars: ✭ 29 (+107.14%)
Mutual labels:  scientific-computing
ose-course-data-science
course on data science for economists
Stars: ✭ 81 (+478.57%)
Mutual labels:  scientific-computing
Geoweaver
a web system to allow users to automatically record history and manage complicated scientific workflows in web browsers involving the online spatial data facilities, high-performance computation platforms, and open-source libraries.
Stars: ✭ 32 (+128.57%)
Mutual labels:  scientific-computing
numo-gsl
GSL interface for Ruby/Numo::NArray
Stars: ✭ 18 (+28.57%)
Mutual labels:  scientific-computing
AutoPas
Autopas is a node-level auto-tuned particle simulation library developed in the context of the TaLPas project.
Stars: ✭ 19 (+35.71%)
Mutual labels:  scientific-computing
pystella
A code generator for grid-based PDE solving on CPUs and GPUs
Stars: ✭ 18 (+28.57%)
Mutual labels:  scientific-computing
graphest
A faithful graphing calculator
Stars: ✭ 42 (+200%)
Mutual labels:  interval-arithmetic
ELLIPTIc
ELLIPTIc: The Extensible LIbrary for Physical simulaTIons
Stars: ✭ 14 (+0%)
Mutual labels:  scientific-computing
SciCompforChemists
Scientific Computing for Chemists text for teaching basic computing skills to chemistry students using Python, Jupyter notebooks, and the SciPy stack. This text makes use of a variety of packages including NumPy, SciPy, matplotlib, pandas, seaborn, NMRglue, SymPy, scikit-image, and scikit-learn.
Stars: ✭ 65 (+364.29%)
Mutual labels:  scientific-computing
nelson
Nelson numerical interpreter
Stars: ✭ 42 (+200%)
Mutual labels:  scientific-computing
gossa
The Go/Go+ Interpreter
Stars: ✭ 53 (+278.57%)
Mutual labels:  scientific-computing

Continuous Integration

Interval

This is an interval arithmetic library for OCaml. Here is a small example in the REPL:

# #require "interval.top";;
...
# open Interval_crlibm;;
# let v = I.singleton 1.;;
val v : Interval_crlibm.I.t = [1, 1]
# I.sin v;;
- : Interval_crlibm.I.t = [0.841471, 0.841471]
# I.Precision.set (Some 16);;
- : unit = ()
# I.sin v;;
- : Interval_crlibm.I.t = [0.8414709848078965, 0.8414709848078966]

Several OPAM packages are provided by this repository:

  • interval_base: basic interval library that defines the datatype Interval.t and uses Intel assembly if possible or C99 instructions to perform arithmetic operations (module Interval).

  • interval_crlibm: relies on crlibm to implement the interval operations. CRlibm provides proved correctly-rounded operations, so this is the library of choice for computer assisted proofs.

  • interval_intel: use Intel FPU instructions with directed rounding to implement interval operations. However, the Intel FPU operations may not always be correctly rounded for, say, trigonometric functions.

    interval_intel uses assembly code to compute all operations with proper rounding, and currently ONLY works on Intel processors. The package has been developed for Linux systems but works on MacOSX and Windows when compiled with GCC.

  • interval is a meta-package installing all the packages above. It also provides interval.top used above.

Note that ocamlopt does float constant propagation in round to the nearest mode which may invalidate interval computations. Use the compiler flag -no-float-const-prop to deactivate it.

Happy interval programming...

Installation

The easier way to install this library is to use OPAM:

opam install interval

interval is a meta-package that will install all packages mentioned above.

If you cloned this repository, first install dune and type make in the main directory. This will compile the libraries, the examples and run basic tests. You can compile the examples with The programs of the examples will be in _build/default/examples/.

Documentation

To documentation is build using dune build @doc and will be in _build/default/_doc/ in HTML format. You can also consult the interfaces of

or online. It is extremely wise to read the whole documentation, even if you intend to only use the Interval_intel module.

Some examples are available in the examples/ directory. There is a B_AND_B sub-directory with an example of a branch-and-bound algorithm that uses interval arithmetics for function optimization (the example is for the Griewank function, but you can substitute any function you like).

Tests

Tests are available in the tests/ directory. They are mainly for debugging purpose and quite complicated. You may run them (make tests) to check that everything is working properly for your machine. The test program runs also a speed test for your particular architecture.

Bug reports should be open at https://github.com/Chris00/ocaml-interval/issues

Remark: This library was originally published on Jean-Marc Alliot website but was moved to Github with the permission of the authors.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].