<p>In this chapter <span class="SimpleMath">p</span> is always a (fixed) prime integer.</p>
<p>The <span class="SimpleMath">p</span>-adic numbers <span class="SimpleMath">Q_p</span> are the completion of the rational numbers with respect to the valuation <span class="SimpleMath">ν_p( p^v ⋅ a / b) = v</span> if <span class="SimpleMath">p</span> divides neither <span class="SimpleMath">a</span> nor <span class="SimpleMath">b</span>. They form a field of characteristic 0 which nevertheless shows some behaviour of the finite field with <span class="SimpleMath">p</span> elements.</p>
<p>A <span class="SimpleMath">p</span>-adic numbers can be represented by a <q><span class="SimpleMath">p</span>-adic expansion</q> which is similar to the decimal expansion used for the reals (but written from left to right). So for example if <span class="SimpleMath">p = 2</span>, the numbers <span class="SimpleMath">1</span>, <span class="SimpleMath">2</span>, <span class="SimpleMath">3</span>, <span class="SimpleMath">4</span>, <span class="SimpleMath">1/2</span>, and <span class="SimpleMath">4/5</span> are represented as <span class="SimpleMath">1(2)</span>, <span class="SimpleMath">0.1(2)</span>, <span class="SimpleMath">1.1(2)</span>, <span class="SimpleMath">0.01(2)</span>, <span class="SimpleMath">10(2)</span>, and the infinite periodic expansion <span class="SimpleMath">0.010110011001100...(2)</span>. <span class="SimpleMath">p</span>-adic numbers can be approximated by ignoring higher powers of <span class="SimpleMath">p</span>, so for example with only 2 digits accuracy <span class="SimpleMath">4/5</span> would be approximated as <span class="SimpleMath">0.01(2)</span>. This is different from the decimal approximation of real numbers in that <span class="SimpleMath">p</span>-adic approximation is a ring homomorphism on the subrings of <span class="SimpleMath">p</span>-adic numbers whose valuation is bounded from below so that rounding errors do not increase with repeated calculations.</p>
<p>In <strong class="pkg">GAP</strong>, <span class="SimpleMath">p</span>-adic numbers are always represented by such approximations. A family of approximated <span class="SimpleMath">p</span>-adic numbers consists of <span class="SimpleMath">p</span>-adic numbers with a fixed prime <spanclass="SimpleMath">p</span> and a certain precision, and arithmetic with these numbers is done with this precision.</p>
<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">‣ PurePadicNumberFamily</code>( <var class="Arg">p</var>, <var class="Arg">precision</var> )</td><td class="tdright">( function )</td></tr></table></div>
<p>returns the family of pure <span class="SimpleMath">p</span>-adic numbers over the prime <var class="Arg">p</var> with <var class="Arg">precision</var> <q>digits</q>. That is to say, the approximate value will differ from the correct value by a multiple of <span class="SimpleMath">p^digits</span>.</p>
<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">‣ PadicNumber</code>( <var class="Arg">fam</var>, <var class="Arg">rat</var> )</td><td class="tdright">( operation )</td></tr></table></div>
<p>returns the element of the <span class="SimpleMath">p</span>-adic number family <var class="Arg">fam</var> that approximates the rational number <var class="Arg">rat</var>.</p>
<p><span class="SimpleMath">p</span>-adic numbers allow the usual operations for fields.</p>
<p>See <code class="func">PadicNumber</code> (<a href="chap68.html#X7C6F2F018084AFC4"><span class="RefLink">68.2-2</span></a>) for other methods for <code class="func">PadicNumber</code>.</p>
<h4>68.2 <span class="Heading">Extensions of the p-adic Numbers</span></h4>
<p>The usual Kronecker construction with an irreducible polynomial can be used to construct extensions of the <span class="SimpleMath">p</span>-adic numbers. Let <span class="SimpleMath">L</span> be such an extension. Then there is a subfield <span class="SimpleMath">K < L</span> such that <span class="SimpleMath">K</span> is an unramified extension of the <span class="SimpleMath">p</span>-adic numbers and <span class="SimpleMath">L/K</span> is purely ramified.</p>
<p>(For an explanation of <q>ramification</q> see for example <a href="chapBib.html#biBneukirch">[Neu92, Section II.7]</a>, or another book on algebraic number theory. Essentially, an extension <span class="SimpleMath">L</span> of the <span class="SimpleMath">p</span>-adic numbers generated by a rational polynomial <span class="SimpleMath">f</span> is unramified if <span class="SimpleMath">f</span> remains squarefree modulo <span class="SimpleMath">p</span> and is completely ramified if modulo <span class="SimpleMath">p</span> the polynomial <span class="SimpleMath">f</span> is a power of a linear factor while remaining irreducible over the <span class="SimpleMath">p</span>-adic numbers.)</p>
<p>The representation of extensions of <span class="SimpleMath">p</span>-adic numbers in <strongclass="pkg">GAP</strong> uses the subfield <span class="SimpleMath">K</span>.</p>
<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">‣ PadicExtensionNumberFamily</code>( <var class="Arg">p</var>, <var class="Arg">precision</var>, <varclass="Arg">unram</var>, <var class="Arg">ram</var> )</td><td class="tdright">( function )</td></tr></table></div>
<p>An extended <span class="SimpleMath">p</span>-adic field <span class="SimpleMath">L</span> is given by two polynomials <span class="SimpleMath">h</span> and <span class="SimpleMath">g</span> with coefficient lists <var class="Arg">unram</var> (for the unramified part) and <var class="Arg">ram</var> (for the ramified part). Then <span class="SimpleMath">L</span> is isomorphic to <span class="SimpleMath">Q_p[x,y]/(h(x),g(y))</span>.</p>
<p>This function takes the prime number <var class="Arg">p</var> and the two coefficient lists <var class="Arg">unram</var> and <var class="Arg">ram</var> for the two polynomials. The polynomial given by the coefficients in <var class="Arg">unram</var> must be a cyclotomic polynomial and the polynomial given by <var class="Arg">ram</var> must be either an Eisenstein polynomial or <span class="SimpleMath">1+x</span>. <em>This is not checked by <strong class="pkg">GAP</strong>.</em></p>
<p>Every number in <span class="SimpleMath">L</span> is represented as a coefficient list w. r. t. the basis <span class="SimpleMath">{ 1, x, x^2, ..., y, xy, x^2 y, ... }</span> of <span class="SimpleMath">L</span>. The integer <var class="Arg">precision</var> is the number of <q>digits</q> that all the coefficients have.</p>
<p><em>A general comment:</em></p>
<p>The polynomials with which <code class="func">PadicExtensionNumberFamily</code> is called define an extension of <span class="SimpleMath">Q_p</span>. It must be ensured that both polynomials are really irreducible over <span class="SimpleMath">Q_p</span>! For example <span class="SimpleMath">x^2+x+1</span> is <em>not</em> irreducible over <span class="SimpleMath">Q_p</span>. Therefore the <q>extension</q> <code class="code">PadicExtensionNumberFamily(3, 4, [1,1,1], [1,1])</code> contains non-invertible <q>pseudo-p-adic numbers</q>. Conversely, if an <q>extension</q> contains noninvertible elements then one of the defining polynomials was not irreducible.</p>
<p><code class="func">PadicNumber</code> creates a <span class="SimpleMath">p</span>-adic number in the <span class="SimpleMath">p</span>-adic numbers family <var class="Arg">fam</var>. The first form returns the <span class="SimpleMath">p</span>-adic number corresponding to the rational <var class="Arg">rat</var>.</p>
<p>The second form takes a pure <span class="SimpleMath">p</span>-adic numbers family <var class="Arg">purefam</var> and a list <var class="Arg">list</var> of length two, and returns the number <span class="SimpleMath">p</span><code class="code">^</code><var class="Arg">list</var><code class="code">[1] * </code><var class="Arg">list</var><code class="code">[2]</code>. It must be guaranteed that no entry of <var class="Arg">list</var><code class="code">[2]</code> is divisible by the prime <span class="SimpleMath">p</span>. (Otherwise precision will get lost.)</p>
<p>The third form creates a number in the family <var class="Arg">extfam</var> of a <span class="SimpleMath">p</span>-adic extension. The second argument must be a list <var class="Arg">list</var> of length two such that <var class="Arg">list</var><code class="code">[2]</code> is the list of coefficients w.r.t. the basis <span class="SimpleMath">{ 1, ..., x^{f-1} ⋅ y^{e-1} }</span> of the extended <span class="SimpleMath">p</span>-adic field and <var class="Arg">list</var><code class="code">[1]</code> is a common <span class="SimpleMath">p</span>-part of all these coefficients.</p>
<p><span class="SimpleMath">p</span>-adic numbers admit the usual field operations.</p>
<p>Depending on the actual representation of quotients, precision may seem to <q>vanish</q>. For example in <code class="code">PadicExtensionNumberFamily(3, 5, [1,1,1], [1,1])</code> the number <code class="code">(1.2000, 0.1210)(3)</code> can be represented as <code class="code">[ 0, [ 1.2000, 0.1210 ] ]</code> or as <code class="code">[ -1, [ 12.000, 1.2100 ] ]</code> (here the coefficients have to be multiplied by <span class="SimpleMath">p^{-1}</span>).</p>
<p>So there may be a number <code class="code">(1.2, 2.2)(3)</code> which seems to have only two digits of precision instead of the declared 5. But internally the number is stored as <code class="code">[ -3, [ 0.0012, 0.0022 ] ]</code> and so has in fact maximum precision.</p>
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung ist noch experimentell.