# doc-cache created by Octave 4.0.0
# name: cache
# type: cell
# rows: 3
# columns: 2
# name: <cell-element>
# type: sq_string
# elements: 1
# length: 4
gsvd


# name: <cell-element>
# type: sq_string
# elements: 1
# length: 1835
 -- Loadable Function: S = gsvd (A, B)
 -- Loadable Function: [U, V, C, S, X [, R]] = gsvd (A, B)
     Compute the generalised singular value decomposition of (A, B):

          u' * a * x = [I 0; 0 c] * [0 r]
          v' * b * x = [0 s; 0 0] * [0 r]
          c * c + s * s = eye(columns(a))
          I and 0 are padding matrices of suitable size
          r is upper triangular

     The function 'gsvd' normally returns the vector of generalised
     singular values diag(r)./diag(s).  If asked for five return values,
     it computes U, V, and X. With a sixth output argument, it also
     returns r, The common upper triangular right term.  Other authors,
     like S. Van Huffel, define this transformation as the simulatenous
     diagonalisation of the input matrices, this can be achieved by
     multiplying x by the inverse of [I 0; 0 r].

     For example,

          gsvd (hilb (3), [1 2 3; 3 2 1])

     returns

          ans =

            0.1055705
            0.0031759

     and

          [u, v, c, s, x, r] = gsvd (hilb (3),  [1 2 3; 3 2 1])

     returns

          u =

            -0.965609   0.240893   0.097825
            -0.241402  -0.690927  -0.681429
            -0.096561  -0.681609   0.725317

          v =

            -0.41974   0.90765
            -0.90765  -0.41974

          c =

             0.10499   0.00000
             0.00000   0.00318

          s =
             0.99447   0.00000
             0.00000   0.99999
          x =

             0.408248   0.902199   0.139179
            -0.816497   0.429063  -0.386314
             0.408248  -0.044073  -0.911806

          r =
            -0.14093  -1.24345   0.43737
             0.00000  -3.90043   2.57818
             0.00000   0.00000  -2.52599


     The code is a wrapper to the corresponding Lapack dggsvd and zggsvd
     routines.


# name: <cell-element>
# type: sq_string
# elements: 1
# length: 63
Compute the generalised singular value decomposition of (A, B):



# name: <cell-element>
# type: sq_string
# elements: 1
# length: 6
pgmres


# name: <cell-element>
# type: sq_string
# elements: 1
# length: 519

 [x, resids] = pgmres (A, b, x0, rtol, maxit, m, P)

   Solves A x = b using the Preconditioned GMRES iterative method
   with restart a.k.a. PGMRES(m).

   rtol is the relative tolerance,
   maxit the maximum number of iterations,
   x0 the initial guess and 
   m is the restart parameter.

   A can be passed as a matrix or as a function handle or 
   inline function f such that f(x) = A*x.

   The preconditioner P can be passed as a matrix or as a function handle or 
   inline function g such that g(x) = P\x.




# name: <cell-element>
# type: sq_string
# elements: 1
# length: 52

 [x, resids] = pgmres (A, b, x0, rtol, maxit, m, P)





