Closed tbode closed 12 years ago
This patch was added because DeleteDuplicates doesn't exist in Mathematica 6. I found the following from StackOverflow which should work on version 6 and later:
UnsortedUnion[x__List] := Tally[Join@x][[All, 1]]
You could replace the deleteDuplicates function with that. Can you try it and check that it works for you, and then we can commit it? I'd rather not make people upgrade their Mathematica version unless it's really necessary, though we haven't made much of an effort to think about this much so far.
The replacement
avoids the reordering of SymmetricDecreasing tensor components. Thanks.
You're welcome! Actually I would probably put this in the definition of deleteDuplicates instead, which is a function which tries to emulate DeleteDuplicates (available in v7 and later).
Works for me. Please push when you can (I don't have write access).
I've replaced the definition of deleteDuplicates with the definition of UnsortedUnion above, and verified that this introduces no changes in McLachlan. Committed in 4afe013.
The last patch to the main branch of Kranc breaks thorns whose Kranc scripts designate a tensor as SymmetricDecreasing. The sorting action included in DeleteDuplicates breaks the order of tensor component declarations in the resulting interface.ccl file for these tensors. Is this really necessary?