triangularMatrix-class        package:Matrix        R Documentation

_V_i_r_t_u_a_l _C_l_a_s_s _o_f _T_r_i_a_n_g_u_l_a_r _M_a_t_r_i_c_e_s _i_n _p_a_c_k_a_g_e:_M_a_t_r_i_x

_D_e_s_c_r_i_p_t_i_o_n:

     The virtual class of triangular matrices,'"triangularMatrix"',
     from the package 'Matrix' contains numeric and logical, dense and
     sparse matrices, e.g., see the examples.

     The main use will be in methods (and C functions) that can deal
     with all triangular matrices.

_S_l_o_t_s:


     '_u_p_l_o': String (of class '"character"').  Must be either "U", for
          upper triangular, and "L", for lower triangular.

     '_d_i_a_g': String (of class '"character"').  Must be either '"U"',
          for unit triangular (diagonal is all ones), or '"N"' for
          non-unit.  The diagonal elements are not accessed internally
          when 'diag' is '"U"'. For 'denseMatrix' classes, they need to
          be allocated though, i.e., the length of the 'x' slot does
          not depend on 'diag'.

     '_D_i_m', '_D_i_m_n_a_m_e_s': The dimension (a length-2 '"integer"') and
          corresponding names (or 'NULL'), inherited from the 'Matrix',
          see there.

_E_x_t_e_n_d_s:

     Class '"Matrix"', directly.

_M_e_t_h_o_d_s:

     There's a C function 'triangularMatrix_validity()' called by the
     internal validity checking functions.

     Currently, 'Schur', 'isSymmetric' and 'as()' (i.e. 'coerce') have
     methods with 'triangularMatrix' in their signature.

_S_e_e _A_l_s_o:

     Classes 'symmetricMatrix', and, e.g., 'dtrMatrix' for numeric
     _dense_ matrices, or 'ltCMatrix' for a logical _sparse_ matrix
     subclass of '"triangularMatrix"'.

_E_x_a_m_p_l_e_s:

     showClass("triangularMatrix")

     ## The names of direct subclasses:
     scl <- getClass("triangularMatrix")@subclasses
     directly <- sapply(lapply(scl, slot, "by"), length) == 0
     names(scl)[directly]

