FiPy only keeps one old time step in memory at a time and only if you have
the hasOld=True flag set on the variable. The only way I know to do what
you want is to create a set of files named by the time step where each one
contains one set of formatted data.

On Fri, Nov 14, 2014, 2:05 AM Kyle Briton Lawlor <klawlor...@gmail.com>
wrote:

> Hi all,
>
> I have been slamming my head on the wall trying to figure out how to
> access the data from each time step in the 2D-diffusion example.
>
> I’ve tried defining an array:
> phis=[]
>
> Then solving with:
> for step in range(steps):
> eq.solve(var=phi,dt=timeStepDuration)
> phis.append(phi)
>
> The result of this though is just an array full of the final solution. I
> tried putting the append before solving, in the loop, but there is no
> difference. However, when I use "print phi” where the append function is,
> it prints out the distinct solutions for each time-step. I would ideally
> like to write out one tsv-file with all the data, to visualize elsewhere.
>
> Any help will be greatly appreciated!
> Still, looking for more clues in my first email.
>
> Thanks,
> Kyle
>
>
> On Nov 13, 2014, at 10:08 PM, Kyle Briton Lawlor <klawlor...@gmail.com>
> wrote:
>
> Thanks for the response.
>
> I am using MacPorts.
> How do I install that package? I can’t find it by itself on MacPorts.
>
> Kyle.
>
> On Nov 13, 2014, at 9:37 PM, L.Bryce Whitson Jr. <lwhits...@gmail.com>
> wrote:
>
> Kyle,
>
> It looks like you are missing the installation of the tvtk package that
> FiPy utilizes. Are you using the Enthought Python distribution or MacPorts?
> Either way, you should be able to find that package and install it. Once
> that is done, I think everything will work. This is just my initial
> thoughts though.
>
> - - - - - - - - - - - - - - - - -
> L.Bryce Whitson Jr.
> lwhits...@gmail.com
>
> On Thu, Nov 13, 2014 at 8:30 PM, Kyle Briton Lawlor <klawlor...@gmail.com>
> wrote:
>
>> Hi all,
>>
>> I am a graduate student beginning to work with FiPy. I am running into
>> some issues with getting the program and its dependencies configured
>> properly. I am not sure if this is the right place to ask these types of
>> questions, let me know if there is somewhere else I could go to find
>> answers. So I will keep things short and I admit I am relatively new to
>> programming, so I have probably done some silly things here.
>>
>> I am using a Mac OS X 10.9.5. I have installed FiPy via MacPorts
>> (py27-fipy).
>> When I run test I get the following output:
>> “Ran 352 tests in 28.032s … Failed (failures=8)… Skipped 83 dockets
>> examples because ‘tvtk’ package cannot be imported”
>>
>> I worked through the 1D-Diffusion example. I had no troubles compiling
>> anything there (including the Viewer()).
>>
>> So I am now trying to work through the 2D-Diffusion in a square.
>> When it comes to viewing I am getting the following error:
>> "Import Error: Failed to import a viewer: [“matplotlib: ufunc ‘isfinite’
>> not supported for the input types, and the inputs could not be safely
>> coerced to any supported types according to the casting rule ‘’safe’’,
>> ‘gist: __call__() takes at least 2 arguments (1 given)’,’gnu plot:
>> __call__() takes at least 2 arguments(1 given)’, ‘mayavi: No module named
>> enthought.tvtk.api’]”
>>
>> My line of code for the viewing segment is:
>> if __name__=='__main__':
>>   viewer=Viewer(vars=phi,datamin=0.,datamax=1.)
>>   viewer.plot()
>> (resulting in the above error.)
>>
>> I am sure there is at least one dumb thing I am doing here. Any pointers
>> or help will be much appreciated. I hope there is a simple solution. I can
>> explain more of what I tried to do to fix this, but I’ll wait to hear back.
>>
>> Thanks,
>> Kyle
>> _______________________________________________
>> fipy mailing list
>> fipy@nist.gov
>> http://www.ctcms.nist.gov/fipy
>>   [ NIST internal ONLY: https://email.nist.gov/mailman/listinfo/fipy ]
>>
>
> _______________________________________________
> fipy mailing list
> fipy@nist.gov
> http://www.ctcms.nist.gov/fipy
>  [ NIST internal ONLY: https://email.nist.gov/mailman/listinfo/fipy ]
>
>
>
> _______________________________________________
> fipy mailing list
> fipy@nist.gov
> http://www.ctcms.nist.gov/fipy
>   [ NIST internal ONLY: https://email.nist.gov/mailman/listinfo/fipy ]
>
_______________________________________________
fipy mailing list
fipy@nist.gov
http://www.ctcms.nist.gov/fipy
  [ NIST internal ONLY: https://email.nist.gov/mailman/listinfo/fipy ]

Reply via email to