forum.alglib.net

ALGLIB forum
It is currently Mon Dec 23, 2024 11:07 pm

All times are UTC


Forum rules


1. This forum can be used for discussion of both ALGLIB-related and general numerical analysis questions
2. This forum is English-only - postings in other languages will be removed.



Post new topic Reply to topic  [ 3 posts ] 
Author Message
 Post subject: FFTC1D changes variables Delphi
PostPosted: Tue May 23, 2017 2:42 pm 
Offline

Joined: Tue May 23, 2017 2:30 pm
Posts: 3
I am using procedure FFTC1D in Delphi 7.0.
The problem I have is the following:
this procedure changes variables not being the outputvariable of the procedure.

So executing FFT.FFTC1D(W,N); changes variable Inp!

Extra:
I am not using explicit pointers nor directive Absolute.

Note:
I have seen the procedure FFTC1D is using a lot of Move-functions and I think one of them is done incorrect?!

Please Help.


Attachments:
FF1CD.txt [2.04 KiB]
Downloaded 832 times
Top
 Profile  
 
 Post subject: Re: FFTC1D changes variables Delphi
PostPosted: Wed May 24, 2017 4:49 pm 
Offline
Site Admin

Joined: Fri May 07, 2010 7:06 am
Posts: 927
FFTC1D performs inplace conversion of input array. Look, it has no other way of telling about its results except for replacing W.

As for Inp variable - you did not performed true copying of Inp to W, you just copied references. So, W and Inp point to same array.


Top
 Profile  
 
 Post subject: Re: FFTC1D changes variables Delphi
PostPosted: Thu May 25, 2017 7:35 am 
Offline

Joined: Tue May 23, 2017 2:30 pm
Posts: 3
Thank you Sergey, I dit not realize that TComplex1DArray is a pointer.
After reprogramming the module with FFTC1D it is working fine now.

Problem solved.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group