1
0
mirror of https://github.com/kalmarek/PropertyT.jl.git synced 2024-11-30 10:00:28 +01:00

use IntervalArithmetic instead of ValidatedNumerics

This commit is contained in:
kalmar 2017-06-25 09:28:44 +02:00
parent ff4f9e7857
commit ac18923631

View File

@ -1,9 +1,12 @@
import Base: rationalize
using ValidatedNumerics
ValidatedNumerics.setrounding(Interval, :accurate)
ValidatedNumerics.setformat(:standard)
# setprecision(Interval, 53) # slightly faster than 256
using IntervalArithmetic
IntervalArithmetic.setrounding(Interval, :accurate)
IntervalArithmetic.setformat(sigfigs=10)
IntervalArithmetic.setprecision(Interval, 53) # slightly faster than 256
import IntervalArithmetic
function EOI{T<:Number}(Δ::GroupRingElem{T}, λ::T)
return Δ*Δ - λ*Δ
@ -41,8 +44,6 @@ function correct_to_augmentation_ideal{T<:Rational}(sqrt_matrix::Array{T,2})
return sqrt_corrected
end
import ValidatedNumerics
function (±){T<:Number}(X::AbstractArray{T}, tol::Real)
r{T}(x::T) = (x == zero(T)? @interval(0) : x ± tol)
return r.(X)