Skip to content

lorenzgillner/ThickIntervals.jl

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ThickIntervals.jl

This package provides a basic implementation of thick intervals for the Julia language. It builds on top of IntervalArithmetic.jl.

About

A thick interval is an interval with uncertain bounds; that is, the bounds are intervals themselves.

Installation

This package requires IntervalArithmetic.jl to function properly, so its prerequisites also apply.

You can install both packages using the following command in the Julia REPL:

using Pkg; Pkg.add(["IntervalArithmetic", "ThickIntervals"])

Usage

using ThickIntervals

Considering an interval $[a] = [1.5, 3.5]$ with an uncertainty of $\pm 0.5$ in both the lower and upper bound, we can construct a thick interval $⟦a⟧ = ⟦[1,2], [3,4]⟧$.

a = thickinterval(1, 2, 3, 4);

Given a second thick interval $⟦b⟧ = ⟦[2.25,2.75], [3.5,4.5]⟧$, we can construct it from two intervals as well.

b = thickinterval(interval(2.25, 2.75), interval(3.5, 4.5));

Currently, the basic arithmetic operations $\{+,-,\cdot,/\}$ are supported by this package, e.g.:

diff = a - b
# ⟦[-3.5, -1.5], [0.25, 1.75]⟧

About

Julia package for intervals with uncertain bounds

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages