How can you get the list of

*To*: mathgroup at smc.vnet.net*Subject*: [mg91940] How can you get the list of*From*: Peng_Wang <a.pengwang at gmail.com>*Date*: Sat, 13 Sep 2008 05:56:49 -0400 (EDT)*References*: <gadcrg$rqi$1@smc.vnet.net> <48CA7353.7010105@gmail.com>

Jean Thanks for your answer. I find ?Global`* is useful. And I work out like this: Begin["a`"] Y=H[Ky,Ly] End[] Names["a`*"]//MatrixForm Sincerely Weber -----=E9=82=AE=E4=BB=B6=E5=8E=9F=E4=BB=B6----- =E5=8F=91=E4=BB=B6=E4=BA=BA: Jean-Marc Gulliet = [mailto:jeanmarc.gulliet at gmail.com] =E5=8F=91=E9=80=81=E6=97=B6=E9=97=B4: 2008=E5=B9=B49=E6=9C=8812=E6=97=A5 = 21:49 =E6=94=B6=E4=BB=B6=E4=BA=BA: Weber; mathgroup at smc.vnet.net =E4=B8=BB=E9=A2=98: Re: How can you get the list of all used variables = and functions in Weber wrote: > How can you get the list of all used variables and functions in > Mathematica? Is that possible? Depending on what you intend to do with the result, you could use ? or Names. For instance, the following will give you all the user defined functions and variables (located in the context Global by default) In[1]:= f[x_] := x^2 In[2]:= g[x_, y_] := x^2 + y^2 In[3]:= ?Global`* Global` f g x y In[4]:= lst = Names["Global`*"] Out[4]= {"f", "g", "lst", "x", "y"} In[5]:= Definition /@ lst // TableForm Out[5]//TableForm= 2 f[x_] := x 2 2 g[x_, y_] := x + y lst = {f, g, lst, x, y} Null Null Regards, -- Jean-Marc