symmpart               package:Matrix               R Documentation

_S_y_m_m_e_t_r_i_c _P_a_r_t _a_n_d _S_k_e_w(_s_y_m_m_e_t_r_i_c) _P_a_r_t _o_f _a _M_a_t_r_i_x

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

     symmpart(x) computes the symmetric part '(x + t(x))/2' and the
     skew symmetric part '(x - t(x))/2' of a square matrix 'x'. Note
     that 'x == symmpart(x) + skewpart(x)' for all square matrices.

_U_s_a_g_e:

     symmpart(x)
     skewpart(x)

_A_r_g_u_m_e_n_t_s:

       x: a _square_ matrix; either traditional of class '"matrix"',
          or typically, inheriting from the 'Matrix' class.

_V_a_l_u_e:

     'symmpart()' returns a symmetric matrix, inheriting from
     'symmetricMatrix' iff 'x' inherited from 'Matrix'.

     'skewpart()' returns a skew-symmetric matrix, typically of the
     same class as 'x' (or the closest general one, see
     'generalMatrix').

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

     m <- Matrix(1:4, 2,2)
     symmpart(m)
     skewpart(m)

     stopifnot(all(m == symmpart(m) + skewpart(m)))

