--- 
:name: dtrsyl
:md5sum: f236af47dea9bd90ec38f415953dc0a5
:category: :subroutine
:arguments: 
- trana: 
    :type: char
    :intent: input
- tranb: 
    :type: char
    :intent: input
- isgn: 
    :type: integer
    :intent: input
- m: 
    :type: integer
    :intent: input
- n: 
    :type: integer
    :intent: input
- a: 
    :type: doublereal
    :intent: input
    :dims: 
    - lda
    - m
- lda: 
    :type: integer
    :intent: input
- b: 
    :type: doublereal
    :intent: input
    :dims: 
    - ldb
    - n
- ldb: 
    :type: integer
    :intent: input
- c: 
    :type: doublereal
    :intent: input/output
    :dims: 
    - ldc
    - n
- ldc: 
    :type: integer
    :intent: input
- scale: 
    :type: doublereal
    :intent: output
- info: 
    :type: integer
    :intent: output
:substitutions: {}

:fortran_help: "      SUBROUTINE DTRSYL( TRANA, TRANB, ISGN, M, N, A, LDA, B, LDB, C, LDC, SCALE, INFO )\n\n\
  *  Purpose\n\
  *  =======\n\
  *\n\
  *  DTRSYL solves the real Sylvester matrix equation:\n\
  *\n\
  *     op(A)*X + X*op(B) = scale*C or\n\
  *     op(A)*X - X*op(B) = scale*C,\n\
  *\n\
  *  where op(A) = A or A**T, and  A and B are both upper quasi-\n\
  *  triangular. A is M-by-M and B is N-by-N; the right hand side C and\n\
  *  the solution X are M-by-N; and scale is an output scale factor, set\n\
  *  <= 1 to avoid overflow in X.\n\
  *\n\
  *  A and B must be in Schur canonical form (as returned by DHSEQR), that\n\
  *  is, block upper triangular with 1-by-1 and 2-by-2 diagonal blocks;\n\
  *  each 2-by-2 diagonal block has its diagonal elements equal and its\n\
  *  off-diagonal elements of opposite sign.\n\
  *\n\n\
  *  Arguments\n\
  *  =========\n\
  *\n\
  *  TRANA   (input) CHARACTER*1\n\
  *          Specifies the option op(A):\n\
  *          = 'N': op(A) = A    (No transpose)\n\
  *          = 'T': op(A) = A**T (Transpose)\n\
  *          = 'C': op(A) = A**H (Conjugate transpose = Transpose)\n\
  *\n\
  *  TRANB   (input) CHARACTER*1\n\
  *          Specifies the option op(B):\n\
  *          = 'N': op(B) = B    (No transpose)\n\
  *          = 'T': op(B) = B**T (Transpose)\n\
  *          = 'C': op(B) = B**H (Conjugate transpose = Transpose)\n\
  *\n\
  *  ISGN    (input) INTEGER\n\
  *          Specifies the sign in the equation:\n\
  *          = +1: solve op(A)*X + X*op(B) = scale*C\n\
  *          = -1: solve op(A)*X - X*op(B) = scale*C\n\
  *\n\
  *  M       (input) INTEGER\n\
  *          The order of the matrix A, and the number of rows in the\n\
  *          matrices X and C. M >= 0.\n\
  *\n\
  *  N       (input) INTEGER\n\
  *          The order of the matrix B, and the number of columns in the\n\
  *          matrices X and C. N >= 0.\n\
  *\n\
  *  A       (input) DOUBLE PRECISION array, dimension (LDA,M)\n\
  *          The upper quasi-triangular matrix A, in Schur canonical form.\n\
  *\n\
  *  LDA     (input) INTEGER\n\
  *          The leading dimension of the array A. LDA >= max(1,M).\n\
  *\n\
  *  B       (input) DOUBLE PRECISION array, dimension (LDB,N)\n\
  *          The upper quasi-triangular matrix B, in Schur canonical form.\n\
  *\n\
  *  LDB     (input) INTEGER\n\
  *          The leading dimension of the array B. LDB >= max(1,N).\n\
  *\n\
  *  C       (input/output) DOUBLE PRECISION array, dimension (LDC,N)\n\
  *          On entry, the M-by-N right hand side matrix C.\n\
  *          On exit, C is overwritten by the solution matrix X.\n\
  *\n\
  *  LDC     (input) INTEGER\n\
  *          The leading dimension of the array C. LDC >= max(1,M)\n\
  *\n\
  *  SCALE   (output) DOUBLE PRECISION\n\
  *          The scale factor, scale, set <= 1 to avoid overflow in X.\n\
  *\n\
  *  INFO    (output) INTEGER\n\
  *          = 0: successful exit\n\
  *          < 0: if INFO = -i, the i-th argument had an illegal value\n\
  *          = 1: A and B have common or very close eigenvalues; perturbed\n\
  *               values were used to solve the equation (but the matrices\n\
  *               A and B are unchanged).\n\
  *\n\n\
  *  =====================================================================\n\
  *\n"
