Mathematica 9 is now available
Services & Resources / Wolfram Forums
-----
 /
MathGroup Archive
1999
*January
*February
*March
*April
*May
*June
*July
*August
*September
*October
*November
*December
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 1999

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

Search the Archive

dummy index list

  • To: mathgroup at smc.vnet.net
  • Subject: [mg20256] dummy index list
  • From: "Arturas Acus" <acus at itpa.lt>
  • Date: Sun, 10 Oct 1999 00:04:08 -0400
  • Sender: owner-wri-mathgroup at wolfram.com

Dear Group,

I have 2 questions:
1) I want the fastest way to select dummy symbols
from some expression. Suppose we have a list of 
dummy indices {a,-b,c, -d}. What is the fastest way to
get rid of the minus sign? 

Here is my solution:
testlist={a,-b,c, -d};
Map[Cases[Flatten[#,Infinity,Times],_Symbol]&,testlist]

However I am not satisfied and believe there should
be a simple solution for such a simple task. I will use
this function very often in future, so it should be
as fast as possible.

2) I am not a professional programmer, so I am
very interesting in algorithm speed estimates
(there was a lot of such estimates published
recently in this group).
Do some tutorials on the web exist on this subject?
At the moment I am interesting in Mathematica SameQ 
algorithm asymptotic (theoretic).
Is it n or log(n) or some other?
How one can know or guess this? Probably 
there are some tables for various basic operations, 
for example, like 
1.the best selection algorithm can be done at speed ??  
2. the list intersection algorithm is ??
3 the union can be done at ??

and so on. Thanks.



                                     
Dr. Arturas Acus
Institute of Theoretical
Physics and Astronomy
Gostauto 12, 2600,Vilnius
Lithuania 


E-mail: acus at itpa.lt
   Fax: 370-2-225361
   Tel: 370-2-612906


  • Prev by Date: Re: Replacing Part of a Matrix
  • Next by Date: Finding roots of complex eqs.
  • Previous by thread: Re: Help Needed: How to use a Notebook from an external Program via Mathlink?
  • Next by thread: Re: dummy index list