Mathematica symbols are the ultimate atoms of symbolic data. Every symbol has a unique name, exists in a certain Mathematica context or namespace, and can have a variety of types of values and attributes.

learn more… | top users | synonyms (2)

14
votes
6answers
728 views

How to clear all variables except one?

I have a lot of variables: $a,b,c,d, \ldots $ I want to clear the values of all of them except $b$. It's really lengthy to write Clear[a]; Clear[c]; ... Is ...
18
votes
5answers
579 views

How do I reassign canonical ordering of symbols?

I have a big polynomial that evaluates to: $$A^2 e^2 \phi ^- \phi ^++A e \phi ^- \phi ^+ c_{2 w} g_Z+\frac{1}{2} A e g h W^- \phi ^+ +\ll13\gg,$$ which is supposed to represent some terms in the ...
5
votes
2answers
186 views

Delete contexts from a string representation of a symbol

I want to delete the string representing the context of a symbol. For info I need such a functionality in my ShowIt function defined here I'd like to know how I ...
30
votes
1answer
685 views

Local variables in Module leak into the Global context

From the Mathematica documentation on Module: Module allows you to set up local variables with names that are local to the module. But after using ...
8
votes
2answers
536 views

List of Mathematica textual symbols

Context I am using Mathematica to create live documents - documents that are both interactive and show mathematical derivations. Now, I'm aware that there are certain symbols that are available via: ...
12
votes
2answers
372 views

Defining symbol shortcuts in the Front End

I was wondering (because I could not find any documentation on this) if it is possible to do shorthand abbreviations for domains or could one define them? E.g. In[1]:= Element[p,Complexes] ...
26
votes
1answer
462 views

What is the story with Removed symbols?

The system function Remove evidently exists primarily to turn a fatal problem into an annoying one, by giving the user a (rather blunt) instrument with which to ...
8
votes
1answer
392 views

How to properly DumpSave & Get Global`s symbols inside packages while not touching Global context?

For efficiency reasons I prefer to use DumpSave instead of Save. For ease of access I prefer to save symbols in ...
19
votes
5answers
1k views

How to pass a symbol name to a function with any of the Hold attributes?

Given a function with the attribute HoldFirst, HoldAll or similar, and a variable, list, how ...
15
votes
2answers
473 views

Automated testing for compatibility with older Mathematica versions

I have several packages which I actively develop and maintain. I try to stay up to date with new releases of Mathematica and usually update within a couple of months of a new version coming out. As a ...
0
votes
1answer
334 views

Symbolic Optimisation

I'm trying to solve symbolically the following optimisation: $$ \min_{q_uu}\ \Biggl[ q_u q_{uu}\psi B_{uu} + q_u q_{ud}\psi B_{ud} + q_d q_{du}\psi B_{ud} + q_d q_{dd}\psi B_{dd} $$ $$ + ...
10
votes
2answers
684 views

How to unload automatically loaded packages?

I know that this has been discussed here (How do I clear all user defined symbols?), but my case is somewhat different. How does one unload packages during runtime that were loaded with the start of ...
2
votes
2answers
491 views

Single dot textual form

How do I render a letter with a single dot above it? I see \[DoubleDot] and \[TripleDot] are readily available, but what about ...
23
votes
2answers
1k views

How can I use the Klingon alphabet symbols?

Mathematica apparently supports the Klingon alphabet: MemberQ[$CharacterEncodings, "Klingon"] True UnicodeFontMapping.tr excerpt: ...
35
votes
2answers
1k views

Is there a way to separate variables between multiple notebooks?

I often correct homework by checking the calculations in Mathematica. Sometimes you would like to have two solutions open at once. However often defined symbols such as ...
22
votes
5answers
7k views

How do I clear all user defined symbols?

Is there some way to do this other than going to Evaluation -> Quit kernel and firing a new one up?
10
votes
2answers
465 views

How do you programatically load data into symbols?

I am trying to convert a list of string names into symbols, which will then be used to store data. I have 24 files (where the name of each file is a member of the list mentioned above) that I need to ...
13
votes
3answers
192 views

How can I test properties of a symbol from the string name without the symbol completely evaluating

Suppose I have a few symbols, one of which has a value: {abc1, abc2 = 5, abc3}; I can use Names to get the list of names, as ...
16
votes
4answers
653 views

How can I randomly generate a unique, unused symbol?

In a previous question on collecting terms for a multivariable polynomial, I answered with a solution that required a unused symbol to be used for a temporary substitution and back substitution. It ...