Code for computing the complete (2-by-2) CS decomposition of a partitioned unitary matrix.


My CSD code is now included in LAPACK! To build from source, download the latest LAPACK release from Netlib. (See below.) The driver routines are SORCSD, DORCSD, CUNCSD, and ZUNCSD. The major support routines are SORBDB, DORBDB, CUNBDB, ZUNBDB, SBBCSD, DBBCSD, CBBCSD, and ZBBCSD.

Native Matlab code is also available. It is numerically stable but slow, and it places some artificial restrictions on the input. If you would like a copy, please send me an email (bsutton@rmc.edu).


  1. Brian D. Sutton. Stable computation of the CS decomposition: simultaneous bidiagonalization. Submitted for publication.
  2. Brian D. Sutton. Computing the complete CS decomposition. Numer. Algorithms. 50 (2009), no. 1, 33–65.
  3. Alan Edelman and Brian D. Sutton. The beta-Jacobi matrix model, the CS decomposition, and generalized singular value problems. Found. Comput. Math. 127 (2007), no. 6, 1121–1165.
  4. Brian D. Sutton. The Stochastic Operator Approach to Random Matrix Theory. Ph.D. thesis, Massachusetts Institute of Technology, 2005.


This material is based upon work supported by the National Science Foundation under Grant No. 0914559. Any opinions, findings and conclusions or recomendations expressed in this material are those of the author(s) and do not necessarily reflect the views of the National Science Foundation (NSF).


Copyright 2012, Brian Sutton.