Re: cube operations - Mailing list pgsql-general

From Filip Rembiałkowski
Subject Re: cube operations
Date
Msg-id 92869e660705161445x2b665fb9qc2e10da277d2c1ef@mail.gmail.com
Whole thread Raw
In response to cube operations  (ABHANG RANE <arane@indiana.edu>)
List pgsql-general
2007/5/16, ABHANG RANE <arane@indiana.edu>:
> Hi,
> I have a array column which has 12 real values in it. Basically these
> values represent co-ordinates in 12 dimensions for a substance. My main
> need is to find substances similar to a particular compound. Now I can
> do by calculating differences with each array in the whole table. But
> the table has millions of rows. So I need some kinda higher dimensional
> index. I have read about the cube operation in postgre, can it be
> extended to 12 dimensions or something like that.

Don't know if this helps, but have a look at intarray:
http://developer.postgresql.org/cvsweb.cgi/pgsql/contrib/intarray/
If you feel brave you could take this code and try to write some
proximity- or similarity-checking functions in C to speedup the
calculations.

Also consider representing values by integers, since integer
operations are much faster.


--
Filip Rembiałkowski

pgsql-general by date:

Previous
From: Rich Shepard
Date:
Subject: Re: Postgres Printed Manuals
Next
From: PFC
Date:
Subject: Re: Performance issues of one vs. two split tables.