12-16-2008 04:49 PM
12-16-2008 04:54 PM
12-16-2008 05:11 PM
Hello Altenbach
I have attached my VI. I was able to make it for only one column from each array. I need it for all the columns. How can that be made?
12-16-2008 05:37 PM
Sorry, it is still not clear what kind of output you want. Can you point to a website explaining the algorithm?
So far you're not "calculating" anything, just shuffling data around in different arrangments.
Again, your first FOR loop in unecessary. Simply remove it and things will still be exactly the same. (the complex primitive accepts almost anything (scalar, 1D, 2D, etc.)).
Where is the FFT array coming from? If you right-shift the size array by one bit, you don't need to divide and round to -inf at all, no orange needed. 🙂
12-16-2008 06:00 PM
welll .. the algorithm is a kind of my own.
see attachment
12-16-2008 07:16 PM - edited 12-16-2008 07:16 PM
Well, easiest would be if you would modify my old bilinear interpolation tool to accept complex inputs and give complex outputs. Shouldn't be too difficult.
Then you would just code as follows:
All clear?
12-17-2008 07:30 AM - edited 12-17-2008 07:35 AM
Hello Altenbach
Thnx for your help. I have already seen your bilinear interpola demo some few week ago. I tried it that way but the result which i want does not come. Now at th emoment i have achieved a VI that formulates the required output, but this is only a small portion. That means the final output of the attached VI "Sub Array in FFT Array" is only due to the first column of Real part & first column of imaginary part arrays. I want such output( which I obtained) for every columns of both Real part & Imaginary part arrays. The size of appended array ( number of columns may be very large at times). Is there a possibilty to get such an output array...
12-17-2008 10:59 AM
Your code is simply a mees and makes very little sense. There is way too much code! 🙂
12-17-2008 02:14 PM - edited 12-17-2008 02:15 PM
Hello Altenbach
Ya.. I know.. mine is a mess.. thats because am just a beginner.. Hope that i improve later...
a)Complex numbers are splitted in to Re & Im parts and each Re & Im part is rounded to nearest + infinity & nearest - Infiinity. That is for each complex number we get 4 other complex number. That is for example for 0.606763 +0.440839 i see "Attachment1".There are many complex numbers. For each complex number this is performed.
b) Now these 4 complex numbers are used to find 4 similar points in FFT Array. For that the Re & Im parts of each of these 4 complex numbers are taken and added to index of middle element of FFT array and are considered as the indices of req point in FFT array. That means, we get a number of set of 4 complex numbers like say [ 1+2i,3+4i,6+7i,9+5i]. Re & Im parts of these numbers are taken and used as indices (1,2),(3,4)(6,7)(9,5). Then elements from the FFT array with these indices are exracted. These 4 points ( a number of set of 4 points are obtained) are then interpolated.
These are the final values which i need.
12-17-2008 03:20 PM - edited 12-17-2008 03:21 PM
Nghtcrwlr wrote:Yes for each complex point in 2D array, i need to find 4 closest points in (from) FFT array. I am doing this as follows:
Well, you don't need to jump through all these hoops! As I said, my code already does that.
Nghtcrwlr wrote:I am trying to use some of your code in interpolation. But the problem is I have already made a method for interpolation of 4 points.
Here's a quick example how you would get the four closest elements as a 2x2 array for each complex fractional coordinate. Just add your own interpolation code.
Here's how the bilinear interpolation would look like modified for complex inputs and outputs (draft, please verify correct operation!).
What kind of interpolation do you actually want?