Skip to main content
General cleanup
Source Link
m_goldberg
  • 108.1k
  • 16
  • 104
  • 259

So in my search to fine tune Mathematica to what works for me, I found a nice setting that helps separate variable declaration between notebooks. Under Global Preferences, searching for CellContext and changing from "Global'*" to Notebook does this. Sweet, but now I am having trouble clearing all the variables. ClearAll["Global``*"]no longer works, and so I figured, since that's the setting I changed, maybe it would now beClearAll[Notebook]. However, this doesn't work either and warns that Notebook` is protected.

Maybe there is a better method of operation instead of the path i'mI'm attempting to go down. I use Mathematica to do all of my Physics homework in. Soin; between each problem iI usually do a ClearAll so i'mI'm not contaminating possible variables between problems with wrong values.

So in my search to fine tune Mathematica to what works for me, I found a nice setting that helps separate variable declaration between notebooks. Under Global Preferences, searching for CellContext and changing from "Global'*" to Notebook does this. Sweet, but now I am having trouble clearing all the variables. ClearAll["Global``*"]no longer works, and so I figured, since that's the setting I changed, maybe it would now beClearAll[Notebook]. However, this doesn't work either and warns that Notebook` is protected.

Maybe there is a better method of operation instead of the path i'm attempting to go down. I use Mathematica to do all of my Physics homework in. So between each problem i usually do a ClearAll so i'm not contaminating possible variables between problems with wrong values.

So in my search to fine tune Mathematica to what works for me, I found a nice setting that helps separate variable declaration between notebooks. Under Global Preferences, searching for CellContext and changing from "Global'*" to Notebook does this. Sweet, but now I am having trouble clearing all the variables. ClearAll["Global``*"]no longer works, and so I figured, since that's the setting I changed, maybe it would now beClearAll[Notebook]. However, this doesn't work either and warns that Notebook` is protected.

Maybe there is a better method of operation instead of the path I'm attempting to go down. I use Mathematica to do all of my Physics homework in; between each problem I usually do a ClearAll so I'm not contaminating possible variables between problems with wrong values.

General cleanup
Source Link
m_goldberg
  • 108.1k
  • 16
  • 104
  • 259

ClearAll just for current notebook

So in my search to fine tune mathematicaMathematica to what works for me, I found a nice setting that helps separate variable declaration between notebooks. UnderUnder Global Preferences, searching for CellContext and changing from "Global'" to Notebook does this. Sweet, but now I am having trouble clearing all the variables. ClearAll["Global`"] no longer works, and so i figured since that's the setting i changed"Global'*" to Notebook does this. Sweet, maybe it wouldbut now be ClearAll[Notebook]I am having trouble clearing all the variables. However this doesn't work either and warns that Notebook ClearAll["Global``*"]no longer works, and so I figured, since that's the setting I changed, maybe it would now beClearAll[Notebook]. However, this doesn't work either and warns that Notebook` is protected.

Maybe there is a better method of operation instead of the path i'm attempting to go down. I use MathematicaMathematica to do all of my Physics homework in. SoSo between each problem i usually do a ClearAllClearAll so i'm not contaminating possible variables between problems with wrong values.

ClearAll for current notebook

So in my search to fine tune mathematica to what works for me, I found a nice setting that helps separate variable declaration between notebooks. Under Global Preferences, searching for CellContext and changing from "Global'" to Notebook does this. Sweet, but now I am having trouble clearing all the variables. ClearAll["Global`"] no longer works, and so i figured since that's the setting i changed, maybe it would now be ClearAll[Notebook]. However this doesn't work either and warns that Notebook is protected.

Maybe there is a better method of operation instead of the path i'm attempting to go down. I use Mathematica to do all of my Physics homework in. So between each problem i usually do a ClearAll so i'm not contaminating possible variables between problems with wrong values.

ClearAll just for current notebook

So in my search to fine tune Mathematica to what works for me, I found a nice setting that helps separate variable declaration between notebooks. Under Global Preferences, searching for CellContext and changing from "Global'*" to Notebook does this. Sweet, but now I am having trouble clearing all the variables. ClearAll["Global``*"]no longer works, and so I figured, since that's the setting I changed, maybe it would now beClearAll[Notebook]. However, this doesn't work either and warns that Notebook` is protected.

Maybe there is a better method of operation instead of the path i'm attempting to go down. I use Mathematica to do all of my Physics homework in. So between each problem i usually do a ClearAll so i'm not contaminating possible variables between problems with wrong values.

Source Link
Erialos
  • 113
  • 1
  • 6

ClearAll for current notebook

So in my search to fine tune mathematica to what works for me, I found a nice setting that helps separate variable declaration between notebooks. Under Global Preferences, searching for CellContext and changing from "Global'" to Notebook does this. Sweet, but now I am having trouble clearing all the variables. ClearAll["Global`"] no longer works, and so i figured since that's the setting i changed, maybe it would now be ClearAll[Notebook]. However this doesn't work either and warns that Notebook is protected.

Maybe there is a better method of operation instead of the path i'm attempting to go down. I use Mathematica to do all of my Physics homework in. So between each problem i usually do a ClearAll so i'm not contaminating possible variables between problems with wrong values.