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
Click For Summary
SUMMARY

This discussion focuses on managing memory usage while plotting 3D functions in Mathematica version 8. Users report significant RAM consumption during evaluations, leading to system instability. Suggested solutions include adjusting the $HistoryLength variable to a modest value and ensuring adequate RAM, with 16GB recommended for optimal performance. Additionally, users are advised to set swap space equal to their RAM to mitigate crashes during intensive calculations.

PREREQUISITES
  • Familiarity with Mathematica version 8
  • Understanding of memory management concepts
  • Knowledge of system swap space configuration
  • Experience with 3D function plotting
NEXT STEPS
  • Research how to configure $HistoryLength in Mathematica
  • Learn about optimizing memory usage in Mathematica
  • Explore techniques for effective 3D plotting in Mathematica
  • Investigate system swap space settings for performance enhancement
USEFUL FOR

This discussion is beneficial for Mathematica users, particularly those involved in 3D plotting, as well as system administrators and developers looking to optimize memory usage in computational tasks.

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.
 

Similar threads

  • · Replies 5 ·
Replies
5
Views
3K
  • · Replies 11 ·
Replies
11
Views
3K
  • · Replies 6 ·
Replies
6
Views
2K
  • · Replies 7 ·
Replies
7
Views
5K
  • · Replies 2 ·
Replies
2
Views
4K
  • · Replies 1 ·
Replies
1
Views
3K
  • · Replies 1 ·
Replies
1
Views
10K
  • · Replies 6 ·
Replies
6
Views
2K
  • · Replies 3 ·
Replies
3
Views
9K
  • · Replies 2 ·
Replies
2
Views
3K