Wolfram ResearchProductsPurchasingServices & ResourcesAbout UsOur Sites
Mathematica Products
-----
 /
Mathematica
*Fast Dense Numerical Linear Algebra
*High-Speed Sparse Linear Algebra
*Large-Scale Linear Systems
*Big-Number Arithmetic
*64-Bit Platform Support
*Faster MathLink
*Numerical Solving of Differential Equations
*Numerical Equation Solving
*Fitting Data
*Numeric Optimization
*DSolve
*RSolve
*Reduce
*Resolve
*FindInstance
*Symbolic Global Optimization
*Wider Support For Domain Specifications
*Connection Technology
*Importing and Exporting
*Statistical Plots
*Collecting Expressions During Evaluation
*New Linear Algebra Functions
<Algebraic Number Objects
*Authoring and Presentation
*Summary of New Features
*Ask about this page

Algebraic Number Objects

See What's New in Wolfram Mathematica 6

Mathematica 5 brings high-performance algebraic number arithmetic within specified algebraic number fields. Mathematica has been providing representation of algebraic numbers as Root objects since Version 3. A Root object contains the minimal polynomial of the algebraic number and the root number--an integer indicating which of the roots of the minimal polynomial the Root object represents. This allows for unique representation of arbitrary complex algebraic numbers.

A disadvantage is that performing arithmetic operations in this representation is costly. If we restrict ourselves to computations within a fixed finite algebraic extension, Q(Theta), of rationals, we can use a more convenient representation of elements of Q(Theta), namely as polynomials in Theta. Within a fixed algebraic number field, the algebraic number arithmetic in the Algebraic object representation is much faster than in the Root object representation. Mathematica 5 contains extensive functionality related to algebraic number fields, available through the package NumberTheory`AlgebraicNumberFields`.

More Details PreviousNext

Suppose we have the following algebraic numbers:

{x, y, z} = {i, 2^(1/2), Root[#1^3 - 2 #1 + 3 &, 1]} ;

And want to compute values of (-2 y z (7 + x - y + z^2) + (6 + x^2 + 2 y) (-11 + x y + z^2))/(2 y z (-4 - x + 3 y z) - (6 + x^2 + 2 y) (2 - 2 x + z^3)).

A direct computation of the value using RootReduce takes a rather long time.

Timing[RootReduce[(-2 y z (7 + x - y + z^2) + (6 + x^2 + 2 y) (-11 + x y + z^2))/(2 y z (-4 - x + 3 y z) - (6 + x^2 + 2 y) (2 - 2 x + z^3))] ;]

{93.865 Second, Null}

A faster alternative is to first find a common algebraic number field containing {a, b, c}, which takes only a fraction of a second.

Timing[({x, y, z} = ToCommonField[{x, y, z}]) ;]

{0.11 Second, Null}

Arithmetic within the common number field is much faster.

Timing[(-2 y z (7 + x - y + z^2) + (6 + x^2 + 2 y) (-11 + x y + z^2))/(2 y z (-4 - x + 3 y z) - (6 + x^2 + 2 y) (2 - 2 x + z^3)) ;]

{0.11 Second, Null}


Related Links


Documentation from the Reference Guide Documentation from the Reference Guide
AlgebraicNumberFields
Algebraics
Root



Back to Top PreviousNext



 © 2008 Wolfram Research, Inc.  Terms of Use  Privacy Policy | [ja]