MathGroup Archive 1995

[Date Index] [Thread Index] [Author Index]

Search the Archive

interchanging elements in a list

  • To: mathgroup at christensen.cybernetics.net
  • Subject: [mg1993] interchanging elements in a list
  • From: Jack Goldberg <jackgold at math.lsa.umich.edu>
  • Date: Wed, 6 Sep 1995 23:50:09 -0400

Hi Group;

Am I the only Mma user to wonder why the obvious list 
command  Interchange  is missing from Mma?  It is easy 
enough to programm but why should we have to?  Interchange 
is not a name used anywhere else in Mma (?), it is a natural list operation,
it is important in Gaussian Elimination...

Presumably,

	Interchange[list_List,n,m] 

should yield  list  with the nth and mth entries interchanged. 
Of course, Interchange might well be designed to handle other heads
besides List and perhaps even have some level specs as options.

Jack Goldberg
Univ. of Michigan  

 


  • Prev by Date: Q: D[EllipticK[k],k] ?
  • Next by Date: Lemke-Algorithm in Mathematica-Code
  • Previous by thread: Re: Q: D[EllipticK[k],k] ?
  • Next by thread: Re: interchanging elements in a list