use version of products from PropertyT
This commit is contained in:
parent
b3bc17cba2
commit
88d2e2549b
19
SL.jl
19
SL.jl
@ -44,25 +44,8 @@ function SL_generatingset(n::Int, p::Int)
|
|||||||
return unique(S), one(G)
|
return unique(S), one(G)
|
||||||
end
|
end
|
||||||
|
|
||||||
function products{T}(U::AbstractVector{T}, V::AbstractVector{T})
|
|
||||||
result = Vector{T}()
|
|
||||||
for u in U
|
|
||||||
for v in V
|
|
||||||
push!(result, u*v)
|
|
||||||
end
|
|
||||||
end
|
|
||||||
return unique(result)
|
|
||||||
end
|
|
||||||
|
|
||||||
function ΔandSDPconstraints(Id, S, radius)
|
function ΔandSDPconstraints(Id, S, radius)
|
||||||
sizes = Vector{Int}()
|
B, sizes = PropertyT.generate_balls(Id, S, radius=2*radius)
|
||||||
S = vcat([Id], S)
|
|
||||||
B = S
|
|
||||||
push!(sizes,length(B))
|
|
||||||
for i in 2:2*radius
|
|
||||||
B = products(S, B);
|
|
||||||
push!(sizes, length(B))
|
|
||||||
end
|
|
||||||
println("Generated balls of sizes $sizes")
|
println("Generated balls of sizes $sizes")
|
||||||
basis = B[1:sizes[radius]]
|
basis = B[1:sizes[radius]]
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user