[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Memory exhausted when using \
From: |
Martin Helm |
Subject: |
Re: Memory exhausted when using \ |
Date: |
Mon, 16 Jul 2012 15:43:58 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:13.0) Gecko/20120601 Thunderbird/13.0 |
Am 16.07.2012 15:13, schrieb Mathieu Dubois:
> Le 16/07/2012 15:04, marco atzeri a écrit :
>> On 7/16/2012 2:55 PM, Markus Bergholz wrote:
>>> like that?
>>>
>>> octave:1> A=[246 710, 49 260]
>>> A =
>>>
>>> 246 710 49 260
>>>
>>> octave:2> B=[49 260, 1]
>>> B =
>>>
>>> 49 260 1
>>>
>>> octave:3> A \ B
>>> ans =
>>>
>>> 1.8994e-02 1.0079e-01 3.8764e-04
>>> 5.4820e-02 2.9088e-01 1.1188e-03
>>> 3.7834e-03 2.0075e-02 7.7212e-05
>>> 2.0075e-02 1.0652e-01 4.0970e-04
>>>
>>> octave:4>
>>>
>>> or am i wrong?
>>> but updating octave and use an up to date version is always a good
>>> idea!
>>>
>>> regards
>>> markus
>>>
>>>
>>> On Mon, Jul 16, 2012 at 2:43 PM, Mathieu Dubois
>>> wrote:
>>>> Hello,
>>>>
>>>> I was porting some code from Matlab to Octave but I'm facing a "memory
>>>> exhausted" error. I'm using Octave 3.2 on a i386 system (I may have
>>>> access
>>>> to more powerful systems but I would like to be able to run the
>>>> code on this
>>>> machine).
>>>>
>>>> This happens when using "\" to solve a linear system. The matrix A
>>>> is (246
>>>> 710, 49 260) and b is (49 260, 1).
>>>>
>>>> I have seen that Octave have other solvers for linear system. Do
>>>> you think
>>>> that may help?
>>>> Do you have any idea if upgrading to 3.6 could help?
>>>>
>>>> Thanks in advance,
>>>> Mathieu
>>
>> I suspect he means a matrix with dimension 246710 x 49260
>> a vector with 49260 x 1
>>
>> As the matrix is almost 10 Gb no surprise of memory exhausted
>>
>> Regards
>> Marco
> You're right Marco I mean a 246710 x 49260 matrix (I wrote the size of
> the matrix).
>
> The construction of A and b works because they are sparse. It's the
> division that don't work.
Try an iterative solver like pcg and check if it is fast enough it uses
less memory than the direct solvers (there are other iterative solvers
as well if pcg does not fit your needs)
http://www.gnu.org/software/octave/doc/interpreter/Iterative-Techniques.html
- Memory exhausted when using \, Mathieu Dubois, 2012/07/16
- Re: Memory exhausted when using \, Markus Bergholz, 2012/07/16
- Re: Memory exhausted when using \, marco atzeri, 2012/07/16
- Re: Memory exhausted when using \, Mathieu Dubois, 2012/07/16
- Re: Memory exhausted when using \,
Martin Helm <=
- Re: Memory exhausted when using \, Mathieu Dubois, 2012/07/16
- Re: Memory exhausted when using \, marco atzeri, 2012/07/16
- Re: Memory exhausted when using \, Mathieu Dubois, 2012/07/16
- Re: Memory exhausted when using \, Martin Helm, 2012/07/16
- Re: Memory exhausted when using \, Mathieu Dubois, 2012/07/16
- Re: Memory exhausted when using \, Martin Helm, 2012/07/16
- Re: Memory exhausted when using \, Martin Helm, 2012/07/17
- Re: Memory exhausted when using \, Mathieu Dubois, 2012/07/17
- Re: Memory exhausted when using \, Martin Helm, 2012/07/17
- Re: Memory exhausted when using \, Mathieu Dubois, 2012/07/19