Can you give us an example of your solution?

-Mark

Kim van der Linde wrote:


Kim van der Linde wrote:



Mark R. Diggory wrote:

This is the sort of thing that defeats the purpose of having the RealMatrix package. Such computations could be used to abuse the contents of the internal data structure effectively breaking the original Matrix.

We need a more OO strategy for capturing the requirements of your example. I believe it should be Functional in nature (like Functors).



The version I gave was the simple one, where there is a fast and simple way around. In a earlier piece of the code, the diffMatrix is actually generated outside a 3000 iteration loop and reused everytime. This reduces the memory overhead, I rather do not create 3000 matrix objects as most of them are eliminated quickly as worse than an previous one. I have encountered that in some cases, the GC is not capable of removing them sufficiently fast (it has the lowest thread priority) and that slows down the processing as the memory stay filled with garbage.


I just through of a simple way to do the same without the getDataRef method, which is actually dead simple now that I got it. So, no objections from my side anymore.

Kim

-- Mark Diggory Software Developer Harvard MIT Data Center http://www.hmdc.harvard.edu

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to