When I used Mathematica in graduate school, I would ubiquitously specialize
a variable and then later "un"specialize it. Specifically, for example, I would write
v:= x^3;
Then, later, when I wanted the symbol "v" to be left symbolically, I would redefine it
with nothing following the definition
v:=;
I forgot the exact syntax, but it was something like this.
But, I cannot find this feature in Maple. Yet I badly need it.
Currently, for me to recover the use of a symbolic variable name like 'v',
I have to CLOSE DOWN MY DOCUMENT and REOPEN IT!
Secondly, in Mathematica, I easily evaluated the "independent" variable to a value
and then could get the value for the dependent variable. The syntax was something like:
e.g. v:=x^3;
x/.->3;
v;
would return 27. Actually, in Mathematica, I believe the semicolons SUPPRESSED the output,
the reverse with Maple.
Finally, how DO I suppress output in Maple?
I hope (demand, since I paid for Maple out of my own pocket) that Maple can do
everything Mathematica can do.
Thank you for your help.
Comments
How do I recover
The simplest way to remove the assigned value from a symbolic variable is to assign the variable its name in 'quotes':
You could also use
> unassign('x');To evaluate an expression with certain values for some of the variables, you can use eval. In your example:
To suppress output, use a colon instead of a semicolon to end your command.
If you really need something that can do _everything_ Mathematica can do, I'm afraid the only way is to get Mathematica (and make sure you always have the latest version, and maybe some earlier versions too...) Maple and Mathematica both have their strengths and weaknesses.
Thank you!
Thank you, Robert Israel.
I meant to ask - where in the online help glossary is the syntax x:='x' explained?
I must make a habit of asking this, since this is what I am often really after
when I post a question on this board.
Obviously, I now know to look up 'eval' and 'unassign'.
where in the help
See "Unassigning a Name Using Unevaluation Quotes" on p. 319 of the User Manual.