[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Help with 2.9.9
From: |
David Bateman |
Subject: |
Re: Help with 2.9.9 |
Date: |
Tue, 28 Nov 2006 16:41:31 +0100 |
User-agent: |
Thunderbird 1.5.0.7 (X11/20060921) |
Vic Norton wrote:
> I have just installed Octave 2.9.9 on a Mac Power PC OS X 10.4 via High
> Performance Computing. So far it does not work.
>
> Problem 1. I don't know how to set the LOADPATH anymore. I had a .octavrc
> file in my home directory that read
> cd ~/octave;
> PS1 = "\\s> ";
> LOADPATH = [LOADPATH, ':~/octave/oct//:~/octave/m//'];
>
> This worked fine in Octave 2.73. Now I get the error messages
> error: `LOADPATH' undefined near line 3 column 13
> error: evaluating assignment expression near line 3, column 10
> error: near line 3 of file `/Users/vic/.octaverc'
> octave:1>
>
> Question 1. How do I set my LOADPATH now? How do I set PS1 to what I want?
>
Read the octave news its all explained there...
> Problem 2. Things were working fine in 2.73, but I switched to 2.9.9 in hopes
> of being able to solve triangular systems efficiently using the "matrix_type"
> fuction. My first test of the function was with this code:
> R = [
> 1 2
> 2 4
> ];
> matrix_type(R)
> matrix_type(R, 'upper')
>
R isn't upper triangular and so the behavior of the solvers will be
undefined if you flag a non upper triangular matrix as upper triangular.
In this case it'll work as the full matrix stores the zeros and the
lower half of the matrix won't be accessed during a solve. But this
definitely won't work for sparse matrices.. Also the syntax above is
wrong.. Octave assumes that functions pass by value and not by
reference. Therefore the function matrix_type can not set the type of
the matrix as given above. The correct form should be
R = matrix_type(R, 'upper')
> The response:
> ans = Positive Definite
> ans =
>
> 1 2
> 2 4
>
> warning: Invalid matrix type
>
> So far so bad! (1) Obviously the matrix is NOT postive definite.
>
The probe code for PD is stupid but fast. It probes for likely PD
matrices and then if the cholesky solver fails falls back an LU solver.
So the above is normal. Try "R\ ones(2,1); matrix_type(R)" and you'll
see that the matrix is now flagged as Singular.
> Question 2. How do you set the matrix_type?
>
> The documentation reads (in part)
> -- Loadable Function: A = matrix_type (A, 'upper', PERM)
> It seems to me that 'upper' IS a valid matrix type. And no, the problem is
> not because R is not upper triangular. The same error occurs if R = [ 1 0; 0
> 4]. And capitalizing the first letter to 'Upper' makes no difference either.
>
>
> Thanks for any advice you can give me. - Vic
>
> _______________________________________________
> Help-octave mailing list
> address@hidden
> https://www.cae.wisc.edu/mailman/listinfo/help-octave
>
>
--
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
- Help with 2.9.9, Vic Norton, 2006/11/28
- Re: Help with 2.9.9,
David Bateman <=
- Re: Help with 2.9.9, Vic Norton, 2006/11/28
- Re: Help with 2.9.9, David Bateman, 2006/11/28
- Re: Help with 2.9.9, John W. Eaton, 2006/11/28
- Re: Help with 2.9.9, Vic Norton, 2006/11/28
- Re: Help with 2.9.9, David Bateman, 2006/11/28
- Re: Help with 2.9.9, Quentin Spencer, 2006/11/28
- Re: Help with 2.9.9, Tom Holroyd (NIH/NIMH) [E], 2006/11/28