def test_m(m): a=flint.fmpz_mat( m ) dG = flint.det(a) dB = flint.det_20140704( a ) if dG==dB: #sys.stdout.write('.') return print 'test failed, det good/bad=%s/%s' % (dG,dB) print m assert 0
def test_m(m,s): a=flint.fmpz_mat( m ) i = is_singular(a) if s and i: return d = flint.det_20140704( a ) if d: assert i==0 else: assert i
def test_m(m,i_m_first): global t_FLINT, t_RAZIN a=flint.fmpz_mat( m ) if i_m_first: t0=time.time() dG = flint.det(a) t1=time.time() dB = flint.det_20140704( a ) t2=time.time() t_FLINT += t1-t0 t_RAZIN += t2-t1 else: t0=time.time() dB = flint.det_20140704( a ) t1=time.time() dG = flint.det(a) t2=time.time() t_FLINT += t2-t1 t_RAZIN += t1-t0 if dG==dB: return print 'test failed, det good/bad=%s/%s' % (dG,dB) print m.__repr__() assert 0