## `Type::AlgebraicConstant` -- a type representing algebraic constants

#### Introduction

`Type::AlgebraicConstant` represents algebraic constants.

#### Call(s)

`testtype(obj,` Type::AlgebraicConstant)

#### Parameters

`obj` | - | any MuPAD object

#### Returns

see `testtype`

#### Related Functions

`testtype`, `Type::Constant`

#### Details

- In MuPAD, algebraic constants are characterized as follows: a complex number is an algebraic constant, if both its real part and its imaginary part are rational. Sums and products of algebraic constants are again algebraic constants. Further, rational powers of algebraic constants are again algebraic constants.

  Taken together, these rules characterize algebraic constants over the rationals defined as usual, i.e., as roots of polynomial expressions.

- This type does not represent a property: it cannot be used in `assume` to mark an identifier as an algebraic constant.

#### Example 1

The following number is composed of radicals involving rational numbers and therefore is an algebraic constant:

    >> testtype((3^(1/2)*I + 1/8)^(1/7), Type::AlgebraicConstant)

                                       TRUE

The following objects are not algebraic constants:

    >> testtype(2^I, Type::AlgebraicConstant),
       testtype(PI, Type::AlgebraicConstant)

                                   FALSE, FALSE

#### Example 2

Symbolic objects cannot represent algebraic constants:

    >> testtype(x, Type::AlgebraicConstant)

                                       FALSE

#### Example 3

The following call selects the algebraic constants in an expression:

    >> select(x + PI + 2^(1/2) + I, testtype, Type::AlgebraicConstant)

                                      1/2
                                     2    + I

#### Changes

- no changes

Do you have questions or comments?
Copyright © SciFace Software GmbH & Co. KG 2000