mod common; #[cfg(test)] mod tests{ use super::common::*; use erfa_sys::*; use rfa::all::ursa_rxr; #[test] pub fn rxr_test(){ let mut a = [[2.0; 3]; 3]; let mut b = [[1.0; 3]; 3]; let mut erfa_atb = [[0.0; 3]; 3]; unsafe{eraRxr(a.as_mut_ptr(), b.as_mut_ptr(), erfa_atb.as_mut_ptr())} let mut rfa_atb = [[0.0; 3]; 3]; ursa_rxr(&a, &b, &mut rfa_atb); for i in 0..3 { for j in 0..3 { assert!(rel_equal(rfa_atb[i][j], erfa_atb[i][j], 1E-14) ); } } } }