|
From: | Paul Kienzle |
Subject: | Re: next problem |
Date: | Mon, 22 Dec 2003 23:08:22 -0500 |
On Dec 22, 2003, at 10:53 PM, Quentin Spencer wrote:
Rich Drewes wrote:As far as I can tell this isn't implemented yet. I ran into the same thing a couple of days ago, and sent a bug report to the bug-octave list. Actually, I found two bugs at the same time, because I also discovered that the statement a(:,:,1)=ones(1,1,2) crashes octave. Multidimensional array support has been added to octave only since 2.1.51, so bugs are still being worked out (all of the ones that affected my Matlab scripts are fixed in the CVS sources now). This may be fixed by the next release, so if you're not in a hurry, I'd say don't worry about rewriting your code yet.On Mon, 22 Dec 2003, Przemek Klosowski wrote:Can anyone explain to me why do I need the transpose, i.e. why, in Matlab, y(:,:,:,:)=[x, x, x, x] and y=[x, x, x, x] are different?I oversimplified my example problem. The real line I was having troubleconverting from Matlab looked more like this: octave:3> F=[1,2,3; 4,5,6; 7,8,9] octave:4> g(:,:,1,1)=F error: invalid number of indices (4) for indexed assignment error: assignment failed, or no method for `<unknown type> = matrix' error: evaluating assignment expression near line 4, column 11 The problem seems to be that Octave can't deal with (for example) assigning 2 dimensions of a 4 dimensional array. Matlab can, and ofcourse this idiom is all over the program I am trying to port. Can you suggest a convenient way of dealing with the issue of assigning certaindimensions of a higher-dimensional array? I can see elaborate ways ofworking around this, but a conveniently similar idiom would make portingmuch easier.
However, you are likely going to get there faster if you contribute in some way, such as documentation patches or test scripts. See thelist of available tests in cvs/octave/test/octave.test --- I don't see any
N-D tests there, but I haven't looked very hard. Paul Kienzle address@hidden ------------------------------------------------------------- Octave is freely available under the terms of the GNU GPL. Octave's home on the web: http://www.octave.org How to fund new projects: http://www.octave.org/funding.html Subscription information: http://www.octave.org/archive.html -------------------------------------------------------------
[Prev in Thread] | Current Thread | [Next in Thread] |