[Scilab-users] Advice from Scilab community

Carrico, Paul paul.carrico at esterline.com
Tue Oct 22 13:58:16 CEST 2013


Dear All

 

I'm asking here an advice from the community in order to find a (fast
and clean) solution ; I've the following issue :

-          I've a (n x 4) matrix where n may be huge (several hundred
thousand of lines is common )

-          I need to find and to remove the line wich has the same
numbers (but different in order)

-          I know that there's only one occurrence ... thus when it has
been found, not necessary to continue

 

Example :

 

A = [

X  X  X      X 

X  X  X      X 

1 9 1000 994423

X  X  X      X 

X  X  X      X 

X  X  X      X 

1000 994423 1 9  ... or 994423 1 9 1000 ... or 9 1000 994423 ... only 3
possible permutations

X  X  X      X 

X  X  X      X 

X  X  X      X 

]

 

Any suggestion that avoids the use of (intensive ugly) loops ?

 

 

NB: 

additional question : 

-          If t = [1 2 3 4]

-          If v = [1 2 3 4]

-          If z = [0 2 3 9]

-          Then (t == v) provides [T T T T]

-          Then (z == v) provides [F T T F]

-           .... Is it possible to have a single Boolean with all the
cells met the requirement (T) and when it's not the case (F) ?

 

Thanks in advance

 

Paul

 

 


--------------------------------------------------------------------------------


Le présent mail et ses pièces jointes sont confidentiels et destinés à la personne ou aux personnes visée(s) ci-dessus. Si vous avez reçu cet e-mail par erreur, veuillez contacter immédiatement l'expéditeur et effacer le message de votre système. Toute divulgation, copie ou distribution de cet e-mail est strictement interdite.

This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. If you have received this email in error, please contact the sender and delete the email from your system. If you are not the named addressee you should not disseminate, distribute or copy this email.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.scilab.org/pipermail/users/attachments/20131022/2b19c2cf/attachment.htm>


More information about the users mailing list