caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: "David McClain" <dmcclain1@mindspring.com>
To: <caml-list@inria.fr>
Subject: Fw: [Caml-list] Complex numbers in OCaml
Date: Thu, 29 Mar 2001 14:35:01 -0700	[thread overview]
Message-ID: <001301c0b898$1d482120$210148bf@dylan> (raw)


----- Original Message -----
From: "David McClain" <dmcclain1@mindspring.com>
To: "Xavier Leroy" <Xavier.Leroy@inria.fr>
Sent: Thursday, March 29, 2001 2:34 PM
Subject: Re: [Caml-list] Complex numbers in OCaml


> > As Markus mentioned, I'm considering extending the Bigarray module to
> > handle complex numbers as well.  This would help interfacing with
> > Fortran, and provide essentially the same data representation than in
> > C and Fortran.
>
> If you do this you need to be aware that:
>
> 1. Most C representations use arrays in which real and imaginary parts are
> in adjacent memory addresses, interleaved throughout the entire array, and
>
> 2. Most Fortran representations use separate arrays for the real parts and
> the imaginary parts.
>
> I say "most" based purely on my own personal experiences with all the glue
> code I have had to write to interface to the IMSL, NAG, MatLab, BLAS, and
> MKL code.
>
> My experiments here have shown me that there is a real speed penalty on
> Pentium II and III architectures for the separate array versions of code,
> contrasted with the interleaved structure versions. I can only assume that
> this has to do with data locality and cache performance.
>
> I ultimately gave up trying to come up with a "standard" array
> representation, except within my own little universe. I was quite
surprised
> to find that a data structure as fundamental as an array of numbers can
have
> so many different implementations.
>
> - DM
>

-------------------
To unsubscribe, mail caml-list-request@inria.fr.  Archives: http://caml.inria.fr


                 reply	other threads:[~2001-03-29 21:34 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='001301c0b898$1d482120$210148bf@dylan' \
    --to=dmcclain1@mindspring.com \
    --cc=caml-list@inria.fr \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).