[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: About resize() function
From: |
Jaroslav Hajek |
Subject: |
Re: About resize() function |
Date: |
Fri, 24 Oct 2008 11:19:39 +0200 |
On Fri, Oct 24, 2008 at 11:03 AM, David Bateman
<address@hidden> wrote:
> Jaroslav Hajek wrote:
>>
>> On Fri, Oct 24, 2008 at 10:24 AM, José Luis García Pallero
>> <address@hidden> wrote:
>>
>>>
>>> Ok, but the fact that some elements are not preserved if the new matrix
>>> is
>>> samaller is logical. I think that the help of the function is quite
>>> confused.
>>>
>>
>> I agree. Also, the behaviour when given a single dimension argument is
>> not logical - IMHO, it should do a vector resize (similarly to what
>> assigning to a non-existent vector element does). I intend to patch
>> resize soon, after I finish the patch I'm now working on, improving
>> the speed of dense indexing and cleaning up the indexing code in
>> Array<T>.
>>
>> regards,
>>
>>
>
> If you do check that if you have the Octave-forge comms toolbox installed
> something like
>
> m = 2;
> n = 2.^m;
> a = gf (floor(randn(10,10,n), m);
> b = tril (a)
>
> resize is used in tril and is used so that metadata in the input matrix (for
> the galois field about the primitive polynomial of the field), is preserved
> during the operation.
>
OK, so what? I'm not saying that resize is not useful, I'm just saying that
resize (x, m) should not mean the same as resize (x, m, m). resize
(zeros (3, 1), 4) should, IMHO, give zeros (4, 1), not zeros (4, 4) as
it gives now. That makes no sense to me.
> Regards
> David
>
>
>
> --
> David Bateman address@hidden
> Motorola Labs - Paris +33 1 69 35 48 04 (Ph) Parc Les
> Algorithmes, Commune de St Aubin +33 6 72 01 06 33 (Mob) 91193
> Gif-Sur-Yvette FRANCE +33 1 69 35 77 01 (Fax)
> The information contained in this communication has been classified as:
> [x] General Business Information [ ] Motorola Internal Use Only [ ] Motorola
> Confidential Proprietary
>
>
--
RNDr. Jaroslav Hajek
computing expert
Aeronautical Research and Test Institute (VZLU)
Prague, Czech Republic
url: www.highegg.matfyz.cz
- About resize() function, José Luis García Pallero, 2008/10/23
- Re: About resize() function, Bill Denney, 2008/10/23
- Re: About resize() function, José Luis García Pallero, 2008/10/24
- Re: About resize() function, Carlo de Falco, 2008/10/24
- Re: About resize() function, Jaroslav Hajek, 2008/10/24
- Re: About resize() function, David Bateman, 2008/10/24
- Re: About resize() function,
Jaroslav Hajek <=
- Re: About resize() function, David Bateman, 2008/10/24
- Re: About resize() function, Jaroslav Hajek, 2008/10/24