SortAlphabeticalI

SortAlphabeticalI

SortAlphabeticalI[ list ] returns the positions of the elements of a list, in alphabetical order of the variable names.

Usages

SortAlphabeticalI[ list ]

SortAlphabeticalI[ list ] returns the positions (starting at 1) of the elements of list in the order that SortAlphabetical would give. Use it to sort a second list in the same order.

Example in out
a is at position 2, b at 3, c at 1. SortAlphabeticalI[ {c, a, b} ] {2, 3, 1}
Expressions are sorted by their variable. SortAlphabeticalI[ {y, 2x, x^2, a} ] {4, 2, 3, 1}
Details
  • The same rules and limitations apply as for SortAlphabetical: use it for variables and expressions with one variable.

See also: SortAlphabetical, SortI, Elm ([[ ]])