Handbook
Glossary
real-part ( z -- x )
Factor handbook
»
The language
»
Numbers
»
Complex numbers
Prev:
complex
Next:
imaginary-part ( z -- y )
Vocabulary
math
Inputs
z
a
number
Outputs
x
a
real
Word description
Outputs the real part of a complex number. This acts as the identity on real numbers.
Examples
USING: math prettyprint ; C{ 1 2 } real-part .
1
Definition
IN:
math
GENERIC:
real-part
( z -- x )
Methods
USING:
accessors
math
;
M:
complex
real-part
real>>
;
inline
USING:
math
;
M:
real
real-part
;
inline