How can I manage memory usage while plotting 3D functions in Mathematica?

  • Context: Mathematica 
  • Thread starter Thread starter Curl
  • Start date Start date
  • Tags Tags
    Mathematica Ram
Join the discussion
Registration is free. Ask a follow-up in this thread, or start your own.
2 replies · 3K views
Curl
Messages
756
Reaction score
0
I'm trying to plot some 3D functions in mathematica, but each time I evaluate the cell, more and more RAM gets eaten up.

How do I clear the memory to keep this resonable? My PC almost crashed because I ate up all the memory. I tried ClearAll and ClearSystemCache[] and it didn't work.

I'm new with Mathematica. Also I am using version 8

thanks
 
Physics news on Phys.org
Try setting $HistoryLength to a modest value if you absolutely have to.

http://reference.wolfram.com/mathematica/ref/$HistoryLength.html

And as Greg said, having more memory than anyone tells you is reasonable will serve you well with Mathematica. 16Gig might be a reasonable amount today, only because we still don't see many boards that will accept 32 or 64 yet.

Set your swap space to be about the same amount as your memory and when Mathematica starts hammering the drive with swapping that is a clue you need to start paying attention to the calculation sizes.

Using memory is a good thing, not a bad thing, if memory isn't mostly committed to a task it is serving no purpose. Aim for perhaps 75% being used by Mathematica and peak at 180% with swapping.

If the machine is going to crash with that then figure out what is wrong with the machine and fix that.