[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
beginner question: returning matrix and other
From: |
Jeff Abrahamson |
Subject: |
beginner question: returning matrix and other |
Date: |
Wed, 22 Jun 2005 10:48:30 -0400 |
User-agent: |
Mutt/1.5.9i |
I have a function that wants to return a matrix and a scalar. The
most obvious way to do this doesn't work. Am I missing something?
Using cell's seems overkill.
octave:45> a=ones(2,2)
a =
1 1
1 1
octave:46> b=3
b = 3
octave:47> [a,b]
error: number of rows must match (1 != 2) near line 47, column 4
--
Jeff
Jeff Abrahamson <http://www.purple.com/jeff/> +1 215/837-2287
GPG fingerprint: 1A1A BA95 D082 A558 A276 63C6 16BF 8C4C 0D1D AE4B
-------------------------------------------------------------
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
-------------------------------------------------------------
- beginner question: returning matrix and other,
Jeff Abrahamson <=