comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » remove duplicates WITHOUT sorting
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
remove duplicates WITHOUT sorting [message #52572] Mon, 12 February 2007 09:04
rpertaub@gmail.com is currently offline  rpertaub@gmail.com
Messages: 43
Registered: January 2007
Member
Hello All,
I have an array of 2xn which is a list of coordinates (x,y positions)
and I need to remove any duplicates in this array. Since they are x,y
coordinates I cannot really sort the array, hence cannot use the Uniq
function. Is there another way of doing this?
My array is similar to:
[2 30
4 5
3 9
51 19
12 15
3 9
11 22
32 33
14 25]

As you see index 4,5 is same as index 10,11. How do i rewrite this
array without duplicates? Is there a general way of doing this, as
some of my coordinates (to make matters even more complicated) are not
exactly the same, but are close (3,9) and (3.5,9) - But I think I can
figure this out with some if...then statements. Not sure how to remove
them though. Any help is appreciated!
Thank you,
Radha
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: remove duplicates WITHOUT sorting
Next Topic: Re: log output of an existing idl process

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Fri Oct 10 05:20:52 PDT 2025

Total time taken to generate the page: 0.55516 seconds