Previous Page Next Page Contents

rectform -- the domain of expressions being splitted into real and imaginary part

Introduction

rectform is the domain of arithmetical expressions being splitted into their real and imaginary part (if possible), i.e., an expression z of this domain is kept in the form Re(z) + I*Im(z), if possible.

Creating Elements

rectform(z)

Parameters

z - an arithmetical expression

Details

Operands

An element z of rectform consists of three operands:

  1. the real part of z,
  2. the imaginary part of z,
  3. the part of z, for that the real and imaginary part cannot be computed (possibly the integer 0, if there are not such subexpressions).


Related Domains

DOM_COMPLEX

Important Operations

You can apply (almost) each function to elements of rectform, functions which mainly expect arithmetical expressions as their input.

For example, you may add or multiply those elements, or apply functions such as expand and diff to them. The result of such an operation, which is not explicitely overloaded by a method of rectform (see below), is an element of rectform.

This ``automatic overloading'' works as follows: Each argument of the operation, which is an element of rectform, is converted to an expression using the method "expr" (see below). Then, the operation is applied and the result is re-converted to an element of rectform.

Use the function expr to convert an element of rectform to an arithmetical expression (as an element of a kernel domain).

The functions Re and Im return the real and imaginary part of elements of rectform.

Result of Evaluation

Evaluating an object of type rectform returns itself.

Function Call

Calling an element of rectform as a function yields the object itself, regardless of the arguments. The arguments are not evaluated.

Method _mult: multiply elements

Method _plus: add elements

Method _power: raise an element to a certain power

Method conjugate: the complex conjugate

Method float: floating point approximation

Method Re: the real part

Method Im: the imaginary part

Method iszero: test on zero

Method has: existence of an object

Method nops: the number of operands

Method op: extract an operand

Method subs: substitute subexpressions

Method subsex: substitute subexpressions (extended)

Method convert: convert an object to this domain

Method convert_to: convert an element of this domain to other domains

Method expr: convert an element of this domain to a kernel domain

Method expr2text: convert an element of this domain to a string

Method testtype: type testing

Method TeX: LaTeX formatting

Method length: length of an object

Method print: pretty-print routine




Do you have questions or comments?


Copyright © SciFace Software GmbH & Co. KG 2000