Implementation of the QKD cone introduced in the paper
First you need to install Julia. From within Julia, enter the package manager by typing ]. Then install ConicQKD:
pkg> add https://github.com/araujoms/ConicQKD.jlThis will automatically install all dependencies. The main one is the solver Hypatia, which this package extends.
Several examples are available in the examples folder. They are all formulated using the modeller JuMP. To constraint a quantum state ρ to belong to the QKD cone with CP maps Ghat and Zhat the syntax is
@constraint(model, [h; ρ_vec] in EpiQKDTriCone{T,R}(Ghat, Zhat, 1 + vec_dim; blocks))modelis the JuMP optimization model being usedhis a variable which will have the conditional entropy in base eρ_vecis a vectorization ofρin the svec format (we provided a functionsvecto compute it).Tis the floating point type to be used (e.g.Float64,Double64,Float128,BigFloat, etc.)Ris either equal toT, in order to optimize over real matrices, or equal toComplex{T}in order to optimize over complex matrices.GhatandZhatencode the CP maps as vectors of Kraus operators.vec_dimis the number of real parameters ofρ, i.e., either d^2 or d(d+1)/2 for the complex and real cases, respectively.blocksis an optional keyword argument specifying the block structure ofZhatas a vector of vectors. For example, ifZhatmaps a 4x4ρto a matrixMsuch that onlyM[1:2,1:2]andM[3:4,3:4]are nonzero, thenblocksshould be[1:2, 3:4]. If this argument is omitted the computation will be considerably slower.