mirror of
https://github.com/kalmarek/PropertyT.jl.git
synced 2024-11-14 14:15:28 +01:00
allow check_distance_to_positive_cone return Interval
This commit is contained in:
parent
b20cd02d5b
commit
dbed75103e
@ -167,6 +167,9 @@ function check_property_T(name::String, generating_set::Function,
|
||||
|
||||
if κ > 0
|
||||
spectral_gap = check_distance_to_positive_cone(Δ, κ, A, tol=tol, rational=false)
|
||||
if isa(spectral_gap, Interval)
|
||||
spectral_gap = spectral_gap.lo
|
||||
end
|
||||
if spectral_gap > 0
|
||||
Kazhdan_κ = sqrt(2*spectral_gap/S)
|
||||
Kazhdan_κ = Float64(trunc(Kazhdan_κ, 12))
|
||||
|
@ -144,11 +144,11 @@ function check_distance_to_positive_cone(Δ::GroupAlgebraElement, κ, A;
|
||||
A_sqrt_ℚ_augⁱⁿᵗ = Float64.(A_sqrt_ℚ_aug) ± δ
|
||||
t = @timed Interval_dist_to_Σ² = distance_to_cone(κ_ℚ, A_sqrt_ℚ_augⁱⁿᵗ, Δ_ℚ)
|
||||
info(logger, timed_msg(t))
|
||||
info(logger, "The Augmentation-projected actual distance (to positive cone) ≥ $(@sprintf("%.10f", Interval_dist_to_Σ².lo))")
|
||||
info(logger, "The Augmentation-projected actual distance (to positive cone) ∈ $(Interval_dist_to_Σ²)")
|
||||
info(logger, "------------------------------------------------------------")
|
||||
|
||||
if Interval_dist_to_Σ².lo ≤ 0 || !rational
|
||||
return Interval_dist_to_Σ².lo
|
||||
return Interval_dist_to_Σ²
|
||||
else
|
||||
info(logger, "Checking Projected SOS decomposition in exact rational arithmetic...")
|
||||
t = @timed ℚ_dist_to_Σ² = distance_to_cone(κ_ℚ, A_sqrt_ℚ_aug, Δ_ℚ)
|
||||
|
Loading…
Reference in New Issue
Block a user