/// <summary> /// method for obtaining binary representation of double /// </summary> /// <param name="d">number to be represented</param> /// <returns>binary representation for d</returns> public static string GetBinaryRepresentationUnion(this double d) { InnerUnion sv = new InnerUnion(d); StringBuilder sb = new StringBuilder(""); long unity = 1; for (var i = 0; i < MaxLenght; i++) { sb.Append((sv.NL & (unity << (MaxLenght - 1 - i))) != 0 ? '1' : '0'); } return(sb.ToString()); }