Questions on assigning and unassigning definitions to names that represent them, including issues raised by context and localization. Use tag [assignment] for issues relating to Set versus SetDelayed.

learn more… | top users | synonyms

0
votes
1answer
50 views

Maximization of a 3-variable function

So I define a 3-variable function $h$ and I want to find the maximum of $h$ in a region $\mathcal{R}$: ...
4
votes
0answers
120 views

Context “Unique to This Notebook” makes variables black even if they're not defined?

I'm trying to use this technique to keep variables separated between different notebooks. It seems to be working fine, except that variables turn black as soon as they are evaluated — any ideas why ...
3
votes
0answers
77 views

What's reliable way of finding declared but undefined functions/symbols in several interrelated packages?

I have many packages some of which use some of others. I have many symbols defined in them. Is there a reliable way of finding declared/exported but undefined functions/symbols in several ...
1
vote
0answers
100 views

Variable scope in nested NMaximize, NMaxValue

I'm trying to use NMaxValue inside other statements (FindRoot and NMinimize). Those statements should bind variable names, but I'm getting weird warnings which seem to indicate that the variables ...
0
votes
0answers
37 views

How to hide global variables in package?

in the package I'm writing I have a list of global variables which should not be visible from a notebook. Here's an extract of the package: ...
0
votes
0answers
82 views

Local variable names - Is there an easy way?

I apologize first, because this has been asked, like in Treat all variables as local in a module [duplicate] Variable scope similar to other languages But I don't get how to use them. Some codes ...
0
votes
0answers
36 views

Subscripts to a variable; why a letter shoud come before a digit?

I noticed that I cannot create a variable $f_{2s}$ since Mathematica seems to leave a space between the subscripts 2 and s ...
0
votes
0answers
97 views

How to define a variable as a function of another variable?

I want to define a variable q which is a function of t. And I want to define another variable ...