added NaN test for trace_gen_inv_quad_form_ldlt
added NaN test for trace_inv_quad_form_ldlt