2017-01-13 18:42:43 +01:00
|
|
|
|
using Combinatorics
|
|
|
|
|
|
|
|
|
|
using JuMP
|
|
|
|
|
import SCS: SCSSolver
|
|
|
|
|
import Mosek: MosekSolver
|
|
|
|
|
|
|
|
|
|
push!(LOAD_PATH, "./")
|
|
|
|
|
using SemiDirectProduct
|
|
|
|
|
using GroupAlgebras
|
|
|
|
|
include("property(T).jl")
|
|
|
|
|
|
|
|
|
|
const N = 4
|
|
|
|
|
|
|
|
|
|
const VERBOSE = true
|
|
|
|
|
|
|
|
|
|
function permutation_matrix(p::Vector{Int})
|
|
|
|
|
n = length(p)
|
|
|
|
|
sort(p) == collect(1:n) || throw(ArgumentError("Input array must be a permutation of 1:n"))
|
|
|
|
|
A = eye(n)
|
|
|
|
|
return A[p,:]
|
|
|
|
|
end
|
|
|
|
|
|
2017-01-16 21:25:14 +01:00
|
|
|
|
SymmetricGroup(n) = [nthperm(collect(1:n), k) for k in 1:factorial(n)]
|
2017-01-13 18:42:43 +01:00
|
|
|
|
|
|
|
|
|
# const SymmetricGroup = [permutation_matrix(x) for x in SymmetricGroup_perms]
|
|
|
|
|
|
2017-01-16 21:25:14 +01:00
|
|
|
|
function E(i, j; dim::Int=N)
|
2017-01-13 18:42:43 +01:00
|
|
|
|
@assert i≠j
|
|
|
|
|
k = eye(dim)
|
|
|
|
|
k[i,j] = 1
|
|
|
|
|
return k
|
|
|
|
|
end
|
|
|
|
|
|
2017-01-16 21:25:14 +01:00
|
|
|
|
function eltary_basis_vector(i; dim::Int=N)
|
2017-01-13 18:42:43 +01:00
|
|
|
|
result = zeros(dim)
|
|
|
|
|
if 0 < i ≤ dim
|
|
|
|
|
result[i] = 1
|
|
|
|
|
end
|
|
|
|
|
return result
|
|
|
|
|
end
|
|
|
|
|
|
2017-01-16 21:25:14 +01:00
|
|
|
|
v(i; dim=N) = eltary_basis_vector(i,dim=dim)
|
2017-01-13 18:42:43 +01:00
|
|
|
|
|
2017-01-16 21:25:14 +01:00
|
|
|
|
ϱ(i,j::Int,n=N) = SemiDirectProductElement(E(i,j,dim=n), v(j,dim=n))
|
|
|
|
|
λ(i,j::Int,n=N) = SemiDirectProductElement(E(i,j,dim=n), -v(j,dim=n))
|
2017-01-13 18:42:43 +01:00
|
|
|
|
|
2017-01-16 21:25:14 +01:00
|
|
|
|
function ɛ(i, n::Int=N)
|
2017-01-13 18:42:43 +01:00
|
|
|
|
result = eye(n)
|
|
|
|
|
result[i,i] = -1
|
|
|
|
|
return SemiDirectProductElement(result)
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
σ(permutation::Vector{Int}) =
|
|
|
|
|
SemiDirectProductElement(permutation_matrix(permutation))
|
|
|
|
|
|
2017-01-16 21:25:14 +01:00
|
|
|
|
# Standard generating set: 103 elements
|
|
|
|
|
|
|
|
|
|
function generatingset_ofAutF(n::Int=N)
|
2017-01-13 18:42:43 +01:00
|
|
|
|
indexing = [[i,j] for i in 1:n for j in 1:n if i≠j]
|
|
|
|
|
ϱs = [ϱ(ij...) for ij in indexing]
|
|
|
|
|
λs = [λ(ij...) for ij in indexing]
|
|
|
|
|
ɛs = [ɛ(i) for i in 1:N]
|
|
|
|
|
σs = [σ(perm) for perm in SymmetricGroup(n)]
|
|
|
|
|
S = vcat(ϱs, λs, ɛs, σs);
|
|
|
|
|
S = unique(vcat(S, [inv(x) for x in S]));
|
|
|
|
|
return S
|
|
|
|
|
end
|
|
|
|
|
|
2017-01-16 21:26:10 +01:00
|
|
|
|
#=
|
|
|
|
|
Note that the element
|
|
|
|
|
α(i,j,k) = ϱ(i,j)*ϱ(i,k)*inv(ϱ(i,j))*inv(ϱ(i,k)),
|
|
|
|
|
which surely belongs to ball of radius 4 in Aut(F₄) becomes trivial under the representation
|
|
|
|
|
Aut(F₄) → GL₄(ℤ)⋉ℤ⁴ → GL₅(ℂ).
|
|
|
|
|
Moreover, due to work of Potapchik and Rapinchuk [1] every real representation of Aut(Fₙ) into GLₘ(ℂ) (for m ≤ 2n-2) factors through GLₙ(ℤ)⋉ℤⁿ, so will have the same problem.
|
|
|
|
|
|
|
|
|
|
We need a different approach!
|
|
|
|
|
=#
|
|
|
|
|
|
2017-01-13 18:42:43 +01:00
|
|
|
|
const ID = eye(N+1)
|
|
|
|
|
|
2017-01-16 21:25:14 +01:00
|
|
|
|
const S₁ = generatingset_ofAutF(N)
|
2017-01-13 18:42:43 +01:00
|
|
|
|
|
|
|
|
|
matrix_S₁ = [matrix_repr(x) for x in S₁]
|
|
|
|
|
|
|
|
|
|
const TOL=10.0^-7
|
|
|
|
|
|
|
|
|
|
matrix_S₁[1:10,:][:,1]
|
|
|
|
|
|
|
|
|
|
Δ, cm = prepare_Laplacian_and_constraints(matrix_S₁)
|
|
|
|
|
|
|
|
|
|
#solver = SCSSolver(eps=TOL, max_iters=ITERATIONS, verbose=true);
|
|
|
|
|
solver = MosekSolver(MSK_DPAR_INTPNT_CO_TOL_REL_GAP=TOL,
|
|
|
|
|
# MSK_DPAR_INTPNT_CO_TOL_PFEAS=1e-15,
|
|
|
|
|
# MSK_DPAR_INTPNT_CO_TOL_DFEAS=1e-15,
|
|
|
|
|
# MSK_IPAR_PRESOLVE_USE=0,
|
|
|
|
|
QUIET=!VERBOSE)
|
|
|
|
|
|
|
|
|
|
# κ, A = solve_for_property_T(S₁, solver, verbose=VERBOSE)
|
|
|
|
|
|
|
|
|
|
product_matrix = readdlm("SL₃Z.product_matrix", Int)
|
|
|
|
|
L = readdlm("SL₃Z.Δ.coefficients")[:, 1]
|
|
|
|
|
Δ = GroupAlgebraElement(L, product_matrix)
|
|
|
|
|
|
|
|
|
|
A = readdlm("matrix.A.Mosek")
|
|
|
|
|
κ = readdlm("kappa.Mosek")[1]
|
|
|
|
|
|
|
|
|
|
# @show eigvals(A)
|
|
|
|
|
@assert isapprox(eigvals(A), abs(eigvals(A)), atol=TOL)
|
|
|
|
|
@assert A == Symmetric(A)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
const A_sqrt = real(sqrtm(A))
|
|
|
|
|
|
|
|
|
|
SOS_EOI_fp_L₁, Ω_fp_dist = check_solution(κ, A_sqrt, Δ)
|
|
|
|
|
|
|
|
|
|
κ_rational = rationalize(BigInt, κ;)
|
|
|
|
|
A_sqrt_rational = rationalize(BigInt, A_sqrt)
|
|
|
|
|
Δ_rational = rationalize(BigInt, Δ)
|
|
|
|
|
|
|
|
|
|
SOS_EOI_rat_L₁, Ω_rat_dist = check_solution(κ_rational, A_sqrt_rational, Δ_rational)
|