det                   package:base                   R Documentation

_C_a_l_c_u_l_a_t_e _t_h_e _D_e_t_e_r_m_i_n_a_n_t _o_f _a _M_a_t_r_i_x

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

     'det' calculates the determinant of a matrix. 'determinant' is a
     generic function that returns separately the modulus of the
     determinant, optionally on the logarithm scale, and the sign of
     the determinant.

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

     det(x, ...)
     determinant(x, logarithm = TRUE, ...)

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

       x: numeric matrix.

logarithm: logical; if 'TRUE' (default) return the logarithm of the
          modulus of the determinant.

     ...: Optional arguments.  At present none are used.  Previous
          versions of 'det' allowed an optional 'method' argument. This
          argument will be ignored but will not produce an error.

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

     For 'det', the determinant of 'x'.  For 'determinant', a list with
     components 

 modulus: a numeric value.  The modulus (absolute value) of the
          determinant if 'logarithm' is 'FALSE'; otherwise the
          logarithm of the modulus.

    sign: integer; either +1 or -1 according to whether the determinant
          is positive or negative.

_N_o_t_e:

     Often, computing the determinant is _not_ what you should be doing
     to solve a given problem.

     Prior to version 1.8.0 the 'det' function had a 'method' argument
     to allow use of either a QR decomposition or an
     eigenvalue-eigenvector decomposition.  The 'determinant' function
     now uses an LU decomposition and the 'det' function is simply a
     wrapper around a call to 'determinant'.

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

     (x <- matrix(1:4, ncol=2))
     unlist(determinant(x))
     det(x)

     det(print(cbind(1,1:3,c(2,0,1))))

