InSeparableBall
InSeparableBall | |
Checks whether or not an operator is in the ball of separability centered at the maximally-mixed state | |
Other toolboxes required | none |
---|---|
Related functions | IsAbsPPT IsSeparable |
Function category | Ball of separability |
InSeparableBall is a function that determines whether or not a density matrix is contained within the ball of states that are separable centered at the maximally-mixed state (more generally, it determines whether or not a positive semidefinite operator is within the ball of separability centered at an appropriately-scaled identity matrix). The size of this ball of separability was computed in ^{[1]}.
Syntax
- ISB = InSeparableBall(X)
Argument descriptions
- X: A bipartite density matrix (or any bipartite positive semidefinite operator).
Examples
The only states acting on $\mathbb{C}^m \otimes \mathbb{C}^n$ in the separable ball that do not have full rank are those with exactly 1 zero eigenvalue, and the $mn-1$ non-zero eigenvalues equal to each other. The following code highlights this fact when $m = n = 2$:
>> U = RandomUnitary(4); >> lam = [1,1,1,0]/3; >> rho = U*diag(lam)*U'; % random density matrix with eigenvalues [1,1,1,0]/3 >> InSeparableBall(rho) ans = 1 >> lam2 = [1.01,1,0.99,0]/3; >> rho2 = U*diag(lam2)*U'; % random density matrix with eigenvalues [1.01,1,0.99,0]/3 >> InSeparableBall(rho2) ans = 0
Source code
Click on "expand" to the right to view the MATLAB source code for this function.
%% INSEPARABLEBALL Checks whether or not an operator is in the ball of separability centered at the maximally-mixed state
% This function has one required input argument:
% X: a positive semidefinite matrix, or a vector of the eigenvalues of
% a positive semidefinite matrix
%
% ISB = InSeparableBall(X) is either 1 or 0, indicating that X is or is
% not contained within the ball of separable operators centered at the
% identity matrix/maximally-mixed state. The size of this ball was
% derived in [1].
%
% URL: http://www.qetlab.com/InSeparableBall
%
% References:
% [1] L. Gurvits and H. Barnum. Largest separable balls around the
% maximally mixed bipartite quantum state. Phys. Rev. A, 66:062311,
% 2002. E-print: arXiv:quant-ph/0204159
% requires: nothing
% author: Nathaniel Johnston (nathaniel@njohnston.ca)
% package: QETLAB
% last updated: November 14, 2014
function isb = InSeparableBall(X)
sz = size(X);
len = max(sz);
% If X is a vector, turn it into a matrix (we could instead turn every
% matrix into a vector of eigenvalues, but that would make the computation
% take O(n^3) time, instead of the current method, which is O(n^2)).
if(min(sz) == 1) % X is a vector of eigenvalues
X = sparse(diag(X));
end
% If X has trace 0 or less it can't possibly be in the separable ball.
if(trace(X) < len*eps)
isb = 0;
return;
end
X = X/trace(X);
% The following check relies on the fact that we scaled X so that
% trace(X) = 1. The following condition is then exactly the Gurvits-Barnum
% condition.
isb = (norm(X/norm(X,'fro')^2 - speye(len),'fro') <= 1);
References
- ↑ L. Gurvits and H. Barnum. Largest separable balls around the maximally mixed bipartite quantum state. Phys. Rev. A, 66:062311, 2002. E-print: arXiv:quant-ph/0204159