Logic for Gray-code Computation

Gray-code is a well-known binary number system where neighboring values differ in one digit only. Tsuiki (2002) has introduced Gray code to the field of real number computation. He assigns to each number a unique 1 perpendicular to-sequence, i.e., an infinite sequence of {-1, 1, perpendicular to} containing at most one copy of perpendicular to (meaning undefinedness). In this paper we take a logical and constructive approach to study real number computation based on Gray-code. Instead of Tsuiki's indeterministic multihead Type-2 machine, we use pre-Gray code, which is a representation of Gray-code as a sequence of constructors, to avoid the difficulty due to perpendicular to which prevents sequential access to a stream. We extract real number algorithms from proofs in an appropriate formal theory involving inductive and coinductive definitions. Examples are algorithms transforming pre-Gray code into signed digit code of real numbers, and conversely, the average for pre-Gray code and a translation of finite segments of pre-Gray code into its normal form. These examples are formalized in the proof assistant Minlog.

[1]  Ulrich Berger,et al.  From Coinductive Proofs to Exact Real Arithmetic , 2009, CSL.

[2]  J. Davenport Editor , 1960 .

[3]  E. Wiedmer,et al.  Computing with Infinite Objects , 1980, Theor. Comput. Sci..

[4]  KENJ I MIYAMOTO,et al.  Program extraction in exact real arithmetic , 2015, Math. Struct. Comput. Sci..

[5]  Hideki Tsuiki Real number computation with committed choice logic programming languages , 2005, J. Log. Algebraic Methods Program..

[6]  Kenji Miyamoto,et al.  Program extraction from coinductive proofs and its application to exact real arithmetic , 2013 .

[7]  Helmut Schwichtenberg,et al.  Proofs and Computations , 2012, Perspectives in logic.

[8]  Ulrich Berger,et al.  Proofs, Programs, Processes , 2011, Theory of Computing Systems.

[9]  Douglas S. Bridges,et al.  Constructivity in Mathematics , 2004 .

[10]  Ulrich Berger,et al.  Program Extraction from Normalization Proofs , 2006, Stud Logica.

[11]  Freek Wiedijk,et al.  The Seventeen Provers of the World , 2006 .

[12]  D. Dalen Review: Georg Kreisel, Godel's Intepretation of Heyting's Arithmetic; G. Kreisel, Relations Between Classes of Constructive Functionals; Georg Kreisel, A. Heyting, Interpretation of Analysis by Means of Constructive Functionals of Finite Types , 1971 .

[13]  Hideki Tsuiki,et al.  Streams with a Bottom in Functional Languages , 2005, ESOP.

[14]  Edwin Wiedmer Exaktes Rechnen mit reellen Zahlen und anderen unendlichen Objekten , 1977 .

[15]  Hideki Tsuiki,et al.  Real number computation through Gray code embedding , 2002, Theor. Comput. Sci..

[16]  Hideki Tsuiki,et al.  A Stream Calculus of Bottomed Sequences for Real Number Computation , 2013, MFPS.

[17]  Alberto Ciaffaglione,et al.  A Co-inductive Approach to Real Numbers , 1999, TYPES.

[18]  Chi Ming Chuang,et al.  Extraction of Programs for Exact Real Number Computation Using Agda , 2011 .