Re: What atoms ought to be!

new topic     » goto parent     » topic index » view thread      » older message » newer message

Nick wrote:
>
> Hi, Rolf
> There are most of the complex number functions you mention, namely:
>
>   C, D = complex number, E = either complex or real.
>
>   C = c_mod(C)     -- modulus value, |C|
...
  <snip>
...
>   C = c_cotanh(C)  -- hyperbolic cotangent of C
>
> in the complex number math library available from the Fractal Factory
> home page, http://www.alphalink.com.au/~metcalfn/ in the downloads
> section.
>
> All functions in the library are also sequence-capable, with sequences
> of complex numbers being kept in the form {{Ar, Ai}, {Br, Bi}, {Cr,
> Ci}...} and so on.
>
> Euphoria is already well-suited to the task of manipulating complex
> numbers way more easily than other languages.  Building complex numbers
> into Euphoria proper could confuse the (reasonably?) clear concept of
                             ^^^^^^^
> objects for new users and such, and would only be of use to the smallest
^^^^^^^^^^^^^^^^^^                                  ^^^^^^^^      
                     > proportion of programmers.
...
  ^^^^^^^^^^

Beginners might run into the famous "sqrt(-1)" error, it would be
no more an error! To restrict atoms only to real numbers one could
introduce one of the following switches:

  "with complex"        -- to use all capabilities, or instead
  "without complex"     -- to restrict to real atoms as it's now.

How small the portion of programmers might be I just want to find
out by my posting: "What atoms ought to be!"

> ....                   I personally would be delighted by such an
                                               ^^^^^^^^^
> addition, but not suprised if Rob dismisses the idea out of hand.
>

Rob is now totally fixed to get the Linus version running. He needs
some time to think about this. We will see.

Nick, I looked into your c_xxx-functions. Except a few
(then easy to write) functions it would have been much easier with
complex atoms!! So, as you mentioned: It would be really a delightful
feature, and an 'euphorian' too!

Have a nice day, Rolf

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu