[Rd] fft
Ole Christensen
o.christensen@lancaster.ac.uk
Fri, 01 Mar 2002 11:06:14 +0000
This is a multi-part message in MIME format.
--------------583A5CD90029B2577BD50770
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Hi Martin
I tried your FFT stuff. Here is my report:
1. I observed similar behaviour as you did (on my Linux machine with
R-1.4.1)
2. Changing from malloc to S_alloc seems to remove the problem (see
attachment).
I remember I had a similar problem long time ago (which caused me to
change from malloc to S_alloc everywhere) when calling the same function
twice (as you have). As far as I remember this problem was present on
Linux but not on Solaris. I could try running your test functions on
Solaris, but first I have to install a new R-version there (R-1.3.0 is
probably too old for this ?).
Hope this sheds a little light on the problem, but we are not there yet
(I do not understand the reason for the difference between S_alloc and
malloc).
Ole
Martin.Schlather@uni-bayreuth.de wrote:
>
> Hi,
>
> I have problems when calling fft_factor and fft_work directly in my
> C-code. Martin Maechler already told me that I should not do this --
> anyway, the code works fine if the length of the vector is a multiple
> of 2,3,5.
> If the length of the vector has different form I get, in some cases, a
> segmentation fault when work and iwork are freed (I use C's malloc to
> allocate memory for work and iwork). No or less problems occur if I
> allocate more memory than stated in src/appl/fft.c.
>
> However R's fft in called in R does not fail.
>
> I would be grateful if anybody would tell me why this happens or to
> which fact I did not pay attention.
> Please find attached the package containing the relevant files.
> Details can be found in tests/test.R
>
> Many thanks in advance.
> Martin
>
> --
> Martin Schlather email: Martin.Schlather@uni-bayreuth.de
> Abteilung Bodenphysik phone: +49 (0)921 55 2193
> Univ. Bayreuth Fax : +49 (0)921 55 2246
> D -- 95440 Bayreuth, Germany http://www.geo.uni-bayreuth.de/~martin/
>
> ------------------------------------------------------------------------
> Name: FFT_0.0.0.tar.gz
> FFT_0.0.0.tar.gz Type: Unix Tape Archive (application/x-tar)
> Encoding: base64
--
Ole F. Christensen
Department of Mathematics and Statistics
Fylde College, Lancaster University
Lancaster, LA1 4YF, England
--------------583A5CD90029B2577BD50770
Content-Type: application/x-gzip;
name="FFT_0.0.1.tar.gz"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a/j/271X10jfIX47/leXf8P
es5A/l8Q1xsOPB3/dwHL0HcFW0D2s4hiZyxi4IODQScLOhFPytvOLCnJPhXBvLp3w7mtdWle
D5f0q7l8gUKO63XWOgXOFbQoc/gMkP2Y/pwKOXQ/M8eTas633e25BaNqCjw0tO11aVKoQzju
J3tO6aIa9pxP5iKazEo6YzAmZH8f8hJz3tDu4UsT+g10KxXtR61fu5ev3rRMsjZjqmXVfV3G
RMiCIloQlR/9v5MmGcpU51qJSWL5Vt9rrGXm02fnFycmCVUqWs7x5LqZCWhhtDA3h+GoZeVl
bNBJbsgUd83UndAyxdbvY2aEZpUna8xZLDGY5jsxTqg7GaJ4n6YshyQt1CE+uXOU1+YljWAs
b7sZGJJwQotgbgINJYW8kqST9Jqp68hc7piqu0rBaMYKNpWYzjFcsFnMErQKmWVDWkYFyYQ8
rzohSYI0km/9g4MjSER6I1/QGJcirGsVUSY8NCR1W1LJWy0cj+QvS60bKfQ9oty4yzXCd+5h
33l/p2bk3xL+ZOFLuX/OatQdG4UoTWZQ8JgRtBpGC1WwNeJZK2o8eAKVNFzLsTAsO6qMamR3
H6UiVKeSl9dKdnKZhaVNa72G+0KZA9wtdYD7Tb/m58+UsrxH/L/r/89evzj519e8/1v1//7Q
7Vf//6un878GDRo0aNCgQYMGDRo0aNCgQYMGDRo0aNCgQYMGDRo0aNCgQYMGDb8HvwE4vgnp
AFAAAA==
--------------583A5CD90029B2577BD50770--
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-devel mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !) To: r-devel-request@stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._