Re: Strong memory consumption by List-plotting functions
- To: mathgroup at smc.vnet.net
- Subject: [mg102331] Re: Strong memory consumption by List-plotting functions
- From: pfalloon <pfalloon at gmail.com>
- Date: Wed, 5 Aug 2009 05:56:17 -0400 (EDT)
- References: <h58ra7$q0l$1@smc.vnet.net>
On Aug 4, 6:25 pm, markus <markusg.p... at googlemail.com> wrote: > Hi again, > > it seems that functions like ListVectorPlot3D, ListContourPlot3D, and > similar ones, have a kind of memory leakage: each time one of these > functions is executed, the memory usage increases (as indicated by the > SystemMonitor). That is, after calling these functions, say 20 times, > with some larger dataset, all my RAM is used up and I have to restart > Mathematica. Using constructs like > g = ListVectorPlot[...] > ... > Clear[g] > also don't help. > > My system: Linux openSuse 10.3, Mathematica 7.01 > > is anybody else experiencing these problems? > -Markus The output of each evaluation is stored as Out[n], and by default "lives on" for the entire session. So each time you evaluate a large graphic you are accumulating memory usage, which sounds like the origin of the problem you're experiencing. If this is a problem for you, you can modify the system variable $HistoryLength to, say, 10, which means that only the most recent 10 outputs are stored in memory. If you need to do this "after the fact", you can do something like: Unprotect[Out]; Clear[Out]; which will clear all the outputs currently stored. Cheers, Peter.