# FilterNormalForm

Jump to: navigation, search
 Other toolboxes required FilterNormalForm Computes the filter normal form of an operator none IsSeparableOperatorSchmidtDecompositionOperatorSinkhorn Entanglement and separability

FilterNormalForm is a function that computes the filter normal form of a bipartite operator RHO (see Section IV.D of [1] for an introductory discussion of the filter normal form). Note that if RHO is not full rank, it may not have a filter normal form and hence an error may be produced by this function.

## Syntax

• XI = FilterNormalForm(RHO)
• [XI,GA,GB] = FilterNormalForm(RHO)
• [XI,GA,GB,FA,FB] = FilterNormalForm(RHO,DIM)
• [XI,GA,GB,FA,FB] = FilterNormalForm(RHO,DIM,TOL)

## Argument descriptions

### Input arguments

• RHO: An positive semidefinite operator (typically a density matrix) that acts on a bipartite Hilbert space. This operator will have its filter normal form computed.
• DIM (optional, default has RHO acting on two subsystems of equal size): A vector containing the dimensions of the two subsystems on which RHO acts.
• TOL (optional, default sqrt(eps)): The numerical tolerance used when computing the filter normal form.

### Output arguments

• XI: A vector containing the coefficients of the filter normal form of RHO, as defined in [1].
• GA,GB (optional): Cells of mutually orthonormal matrices in the filter normal form of RHO.
• FA,FB (optional): The local filtering operations used to convert RHO into its filter normal form.

To be explicit, the relationship between RHO and the output arguments is that kron(FA,FB)*RHO*kron(FA,FB)' == (eye(length(RHO)) + TensorSum(XI,GA,GB))/length(RHO). In usual math notation, this means that

$$(F_A \otimes F_B)\rho(F_A \otimes F_B)^\dagger = \frac{1}{d_A d_B}\big(I + \displaystyle\sum_{k} \xi_k G_k^A \otimes G_k^B\big).$$

## Examples

### Finding and verifying the filter normal form

The following code computes the filter normal form of a random density matrix. The fact that FA and FB implement a local filter to this form is then verified (within reasonable numerical error).

>> rho = RandomDensityMatrix(9);
>> [xi,GA,GB,FA,FB] = FilterNormalForm(rho);
>> norm((eye(9) + TensorSum(xi,GA,GB))/9 - kron(FA,FB)*rho*kron(FA,FB)')

ans =

6.8088e-016

### Using the filter normal form to detect entanglement

As noted in [1], the coefficients XI of the filter normal form provide useful information about the entanglement of RHO. For example, if both subsystems have the same dimension D then we can conclude that RHO is entangled if sum(XI) > D^2 - D. Thus the following code generates a random two-qutrit density matrix and then determines that it is entangled:

>> d = 3;
>> rho = RandomDensityMatrix(d^2);
>> xi = FilterNormalForm(rho);
>> [sum(xi), d^2-d]

ans =

6.3611    6.0000

### Low-rank states may not have a filter normal form

It is known[2] that all full-rank density matrices have a filter normal form. However, low-rank density matrices may not have a filter normal form (although they usually do) – an error will be produced by this script when low-rank problems occur. The following code generates a random rank-2 density matrix in $$M_3 \otimes M_3$$ just fine, but is unable to compute the filter normal form of a low-rank state that is constructed specifically so that it does not have a filter normal form:

>> xi = FilterNormalForm(RandomDensityMatrix(9,0,2)); % no errors will come from this
>> rho = kron(diag([1/2,1/2,0]),eye(3)/3);
>> xi = FilterNormalForm(rho);
Error using FilterNormalForm (line 68)
The state RHO can not be transformed into a filter normal form. This is often the case if RHO is not of full rank.

## Source code

Click on "expand" to the right to view the MATLAB source code for this function.

1. %%  FILTERNORMALFORM    Computes the filter normal form of an operator
2. %   This function has one required argument:
3. %     RHO: a density matrix
4. %
5. %   XI = FilterNormalForm(RHO) is a vector of the coefficients in RHO's
6. %   filter normal form (see Section IV.D of [1]), which are useful for
7. %   showing that RHO is entangled.
8. %
9. %   The filter normal form is not guaranteed to exist if RHO is not full
10. %   rank. If a filter normal form can not be found, an error is returned.
11. %
12. %   This function has two optional input arguments:
13. %     DIM (default has both subsystems of equal dimension)
14. %     TOL (default sqrt(eps))
15. %
16. %   This function has four optional output arguments:
17. %     GA,GB: cells of mutually orthonormal matrices
18. %     FA,FB: invertible matrices
19. %
20. %   [XI,GA,GB,FA,FB] = FilterNormalForm(RHO,DIM,TOL) returns XI, GA, GB,
21. %   FA, FB such that (eye(length(RHO)) + TensorSum(XI,GA,GB))/length(RHO)
22. %   equals kron(FA,FB)*RHO*kron(FA,FB)'. In other words, FA and FB are
23. %   matrices implementing the local filter, XI is a vector of coefficients
24. %   in the filter normal form, and GA and GB are cells of matrices in the
25. %   tensor-sum decomposition of the filter normal form.
26. %
27. %   DIM is a 1-by-2 vector containing the dimensions of the subsystems on
28. %   which RHO acts. TOL is the numerical tolerance used when constructing
29. %   the filter normal form.
30. %
31. %   URL: http://www.qetlab.com/FilterNormalForm
32. %
33. %   References:
34. %   [1] O. Gittsovich, O. Guehne, P. Hyllus, and J. Eisert. Unifying several
35. %   separability conditions using the covariance matrix criterion. Phys.
36. %   Rev. A, 78:052319, 2008. E-print: arXiv:0803.0757 [quant-ph]
37. 
38. %   requires: OperatorSchmidtDecomposition.m, OperatorSinkhorn.m,
39. %             opt_args.m, PartialTrace.m, PermuteSystems.m,
40. %             SchmidtDecomposition.m, Swap.m
41. %
42. %   author: Nathaniel Johnston (nathaniel@njohnston.ca)
43. %   package: QETLAB
44. %   last updated: October 3, 2014
45. 
46. function [xi,GA,GB,FA,FB] = FilterNormalForm(rho,varargin)
47. 
48. lrho = length(rho);
49. 
50. % set optional argument defaults: dim=sqrt(length(rho)), tol=sqrt(eps)
51. [dim,tol] = opt_args({ round(sqrt(lrho)), sqrt(eps) },varargin{:});
52. 
53. % allow the user to enter a single number for dim
54. if(length(dim) == 1)
55.     dim = [dim,lrho/dim];
56.     if abs(dim(2) - round(dim(2))) >= 2*lrho*eps
57.         error('FilterNormalForm:InvalidDim','If DIM is a scalar, it must evenly divide length(RHO); please provide the DIM array containing the dimensions of the subsystems.');
58.     end
59.     dim(2) = round(dim(2));
60. end
61. 
62. try
63.     [sigma,F] = OperatorSinkhorn(rho,dim);
64. catch err
65.     % Operator Sinkhorn didn't converge.
66.     if(strcmpi(err.identifier,'OperatorSinkhorn:LowRank'))
67.         error('FilterNormalForm:NoFNF','The state RHO can not be transformed into a filter normal form. This is often the case if RHO is not of full rank.');
68.     else
69.         rethrow(err);
70.     end
71. end
72. 
73. % Do some post-processing to make the output more useful and consistent
74. % with the literature.
75. pd = prod(dim);
76. [xi,GA,GB] = OperatorSchmidtDecomposition(sigma - trace(sigma)*eye(pd)/pd,dim);
77. xi = pd*xi;
78. FA = F{1};
79. FB = F{2};

## References

1. O. Gittsovich, O. Gühne, P. Hyllus, and J. Eisert. Unifying several separability conditions using the covariance matrix criterion. Phys. Rev. A, 78:052319, 2008. E-print: arXiv:0803.0757 [quant-ph]
2. J. M. Leinaas, J. Myrheim, and E. Ovrum. Geometrical aspects of entanglement. Phys. Rev. A, 74:012313, 2006. E-print: arXiv:quant-ph/0605079