public void TestQuire8Sub() { var qA = Quire8.Create(); qA -= (1, 1); var pA = qA.ToPosit(); Assert.That(pA, Is.EqualTo(Posit8.MinusOne)); }
public void TestQuire8Add() { var qA = Quire8.Create(); qA += (1, 1); var pA = qA.ToPosit(); Assert.That(pA, Is.EqualTo(Posit8.One)); }
public static quire8_t q8_fdp_sub(quire8_t q, in posit8_t a, in posit8_t b)
public static bool IsZero(Quire8 a) => a.m_value == 0;
public static bool IsZeroOrNaR(Quire8 q) { return((q.m_value & ((1u << 31) - 1)) == 0); }
public static bool IsNaR(Quire8 a) => a.m_value == Quire8.NaR.m_value;
static bool isQ8Zero(quire8_t q) => q.m_value == 0;
static bool isNaRQ8(quire8_t q) => q.m_value == 0x80000000;