From johannes at zellner.org Tue Sep 1 00:43:50 2009 From: johannes at zellner.org (Dr. Johannes Zellner) Date: Tue, 1 Sep 2009 07:43:50 +0200 Subject: grid line style Message-ID: <103840bf0908312243n717802d7u1eaecf06e4adba0d@mail.gmail.com> Hi, how can I set the grid line style to a solid gray line? (octave 3.2 with gnuplot) -- Johannes -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090901/92a608f2/attachment.html From jwe at octave.org Tue Sep 1 01:02:37 2009 From: jwe at octave.org (John W. Eaton) Date: Tue, 1 Sep 2009 02:02:37 -0400 Subject: grid line style In-Reply-To: <103840bf0908312243n717802d7u1eaecf06e4adba0d@mail.gmail.com> References: <103840bf0908312243n717802d7u1eaecf06e4adba0d@mail.gmail.com> Message-ID: <19100.47357.934173.170780@segfault.lan> On 1-Sep-2009, Dr. Johannes Zellner wrote: | how can I set the grid line style to a solid gray line? (octave 3.2 with | gnuplot) Does gnuplot allow setting the line style for the grid lines? jwe From dbateman at dbateman.org Tue Sep 1 01:07:58 2009 From: dbateman at dbateman.org (David Bateman) Date: Tue, 01 Sep 2009 08:07:58 +0200 Subject: large sparse matrix In-Reply-To: <67814968-724A-4C38-89A7-01E2D4613C6D@gmail.com> References: <420ba0760908310753i7fe60591l9d4d657a6db9dade@mail.gmail.com> <25225293.post@talk.nabble.com> <4A9C2A53.2060607@dbateman.org> <67814968-724A-4C38-89A7-01E2D4613C6D@gmail.com> Message-ID: <4A9CBA3E.8060909@dbateman.org> Carlo de Falco wrote: > > On 31 Aug 2009, at 21:53, David Bateman wrote: >> >> Yes, but the configuration of SuiteSparse in terms of the pivot >> threshold is the default that TIm Davis sets for Octave and whatever >> mathworks chose to use for matlab. So don't expect exactly the behavior. > I see... > >> In Octave what does >> >> matrix_type(A) >> give? > > > >> matrix_type (A) > ans = Positive Definite > >> > >> If it doesn't flag your matrix as PD then there might be an issue >> with the detection of the matrix and PD and the solver used in Octave >> will be LU. > > on the other hand what surprises me is that: > > >> issparse (B) > ans = 1 > >> matrix_type (B) > ans = Rectangular > >> issparse (A) > ans = 1 > >> mat = [A B' spalloc(rows(A),1,0); B spalloc(rows(B),columns(A),1) > E'; spalloc(columns(A),1,1) E 0]; > >> matrix_type (mat) > ans = Full > >> issparse (mat) > ans = 1 > > why is mat marked as full??? > >> Also, what does the code >> >> [R, p, q] = chol(A); >> nnz(R) >> > >> work for Octave and Matlab? > I tried this in Octave, after 30 min it did not finish yet... > I will only be able to try it on Matlab tomorrow. > >> If so what is the value of NNZ of the factorization in both cases. >> >> Regards >> David > > > Thanks, > Carlo > What are the sizes of A, B and E? D. -- David Bateman dbateman at dbateman.org 35 rue Gambetta +33 1 46 04 02 18 (Home) 92100 Boulogne-Billancourt FRANCE +33 6 72 01 06 33 (Mob) From johannes at zellner.org Tue Sep 1 01:45:52 2009 From: johannes at zellner.org (Dr. Johannes Zellner) Date: Tue, 1 Sep 2009 08:45:52 +0200 Subject: grid line style In-Reply-To: <19100.47357.934173.170780@segfault.lan> References: <103840bf0908312243n717802d7u1eaecf06e4adba0d@mail.gmail.com> <19100.47357.934173.170780@segfault.lan> Message-ID: <103840bf0908312345m4ca8fc47kc3b0706f5762c490@mail.gmail.com> gnuplot> set grid lt 1 lc rgb '#aaaaaa' makes a solid gray grid. -- Johannes 2009/9/1 John W. Eaton > On 1-Sep-2009, Dr. Johannes Zellner wrote: > > | how can I set the grid line style to a solid gray line? (octave 3.2 with > | gnuplot) > > Does gnuplot allow setting the line style for the grid lines? > > jwe > -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090901/19c1c975/attachment.html From highegg at gmail.com Tue Sep 1 02:14:02 2009 From: highegg at gmail.com (Jaroslav Hajek) Date: Tue, 1 Sep 2009 09:14:02 +0200 Subject: large sparse matrix In-Reply-To: <67814968-724A-4C38-89A7-01E2D4613C6D@gmail.com> References: <420ba0760908310753i7fe60591l9d4d657a6db9dade@mail.gmail.com> <25225293.post@talk.nabble.com> <4A9C2A53.2060607@dbateman.org> <67814968-724A-4C38-89A7-01E2D4613C6D@gmail.com> Message-ID: <69d8d540909010014n5ad9cad7k19d310149dc2b141@mail.gmail.com> On Tue, Sep 1, 2009 at 1:12 AM, Carlo de Falco wrote: > > On 31 Aug 2009, at 21:53, David Bateman wrote: >> >> Yes, but the configuration of SuiteSparse in terms of the pivot >> threshold is the default that TIm Davis sets for Octave and whatever >> mathworks chose to use for matlab. So don't expect exactly the >> behavior. > I see... > >> In Octave what does >> >> matrix_type(A) >> give? > > > ?>> matrix_type (A) > ans = Positive Definite > ?>> > >> If it doesn't flag your matrix as PD then there might be an issue >> with the detection of the matrix and PD and the solver used in >> Octave will be LU. > > on the other hand what surprises me is that: > > ?>> issparse (B) > ans = ?1 > ?>> matrix_type (B) > ans = Rectangular > ?>> issparse (A) > ans = ?1 > ?>> mat = [A B' spalloc(rows(A),1,0); B spalloc(rows(B),columns(A),1) > E'; spalloc(columns(A),1,1) E 0]; > ?>> matrix_type (mat) > ans = Full > ?>> issparse (mat) > ans = ?1 > > why is mat marked as full??? > Full is what you get when nothing special about the matrix is discovered. Did you expect something else? The matrix is obviously not positive definite, as seen from its construction, and I can see no apparent other structure (triangularity or bandedness), though it of course depends on the values of A, B and E. hth -- RNDr. Jaroslav Hajek computing expert & GNU Octave developer Aeronautical Research and Test Institute (VZLU) Prague, Czech Republic url: www.highegg.matfyz.cz From carlo.defalco at gmail.com Tue Sep 1 02:57:37 2009 From: carlo.defalco at gmail.com (Carlo de Falco) Date: Tue, 1 Sep 2009 09:57:37 +0200 Subject: large sparse matrix In-Reply-To: <69d8d540909010014n5ad9cad7k19d310149dc2b141@mail.gmail.com> References: <420ba0760908310753i7fe60591l9d4d657a6db9dade@mail.gmail.com> <25225293.post@talk.nabble.com> <4A9C2A53.2060607@dbateman.org> <67814968-724A-4C38-89A7-01E2D4613C6D@gmail.com> <69d8d540909010014n5ad9cad7k19d310149dc2b141@mail.gmail.com> Message-ID: <44BC9295-727A-467B-956E-1FE4CD2F7F2B@gmail.com> On 1 Sep 2009, at 09:14, Jaroslav Hajek wrote: > On Tue, Sep 1, 2009 at 1:12 AM, Carlo de > Falco wrote: >> >> On 31 Aug 2009, at 21:53, David Bateman wrote: >>> >>> Yes, but the configuration of SuiteSparse in terms of the pivot >>> threshold is the default that TIm Davis sets for Octave and whatever >>> mathworks chose to use for matlab. So don't expect exactly the >>> behavior. >> I see... >> >>> In Octave what does >>> >>> matrix_type(A) >>> give? >> >> >> >> matrix_type (A) >> ans = Positive Definite >> >> >> >>> If it doesn't flag your matrix as PD then there might be an issue >>> with the detection of the matrix and PD and the solver used in >>> Octave will be LU. >> >> on the other hand what surprises me is that: >> >> >> issparse (B) >> ans = 1 >> >> matrix_type (B) >> ans = Rectangular >> >> issparse (A) >> ans = 1 >> >> mat = [A B' spalloc(rows(A),1,0); B spalloc(rows(B),columns(A),1) >> E'; spalloc(columns(A),1,1) E 0]; >> >> matrix_type (mat) >> ans = Full >> >> issparse (mat) >> ans = 1 >> >> why is mat marked as full??? >> > > Full is what you get when nothing special about the matrix is > discovered. Did you expect something else? The matrix is obviously not > positive definite, as seen from its construction, and I can see no > apparent other structure (triangularity or bandedness), though it of > course depends on the values of A, B and E. > > hth Well, the matrix is of course symmetric by construction, but I don't think there's much more... But actually the reason I was surprised that it is marked as "Full" is that I thought this mark had to do with its storage format. Maybe another name like, e.g., "Generic" would have been less misleading... Thnaks for the info! c. From carlo.defalco at gmail.com Tue Sep 1 03:04:17 2009 From: carlo.defalco at gmail.com (Carlo de Falco) Date: Tue, 1 Sep 2009 10:04:17 +0200 Subject: large sparse matrix In-Reply-To: <67814968-724A-4C38-89A7-01E2D4613C6D@gmail.com> References: <420ba0760908310753i7fe60591l9d4d657a6db9dade@mail.gmail.com> <25225293.post@talk.nabble.com> <4A9C2A53.2060607@dbateman.org> <67814968-724A-4C38-89A7-01E2D4613C6D@gmail.com> Message-ID: <420ba0760909010104x3c7385fdi39eab8d17440a06f@mail.gmail.com> 2009/9/1 Carlo de Falco : >> Also, what does the code >> >> [R, p, q] = chol(A); >> nnz(R) >> > >> work for Octave and Matlab? > > I tried this in Octave, after 30 min it did not finish yet... > I will only be able to try it on Matlab tomorrow. > >> If so what is the value of NNZ of the factorization in both cases. I killed the Octave after it had been running more than one hour and produced no result. In Matlab it ran in less than a second and the result was: >> [R,p,q]=chol(A); >> nnz (R) ans = 1368019 >> issparse (R) ans = 1 >> nnz(R)/prod(size(A)) ans = 7.035863106552923e-03 Thanks, c. From carlo.defalco at gmail.com Tue Sep 1 03:12:12 2009 From: carlo.defalco at gmail.com (Carlo de Falco) Date: Tue, 1 Sep 2009 10:12:12 +0200 Subject: large sparse matrix In-Reply-To: <420ba0760909010104x3c7385fdi39eab8d17440a06f@mail.gmail.com> References: <420ba0760908310753i7fe60591l9d4d657a6db9dade@mail.gmail.com> <25225293.post@talk.nabble.com> <4A9C2A53.2060607@dbateman.org> <67814968-724A-4C38-89A7-01E2D4613C6D@gmail.com> <420ba0760909010104x3c7385fdi39eab8d17440a06f@mail.gmail.com> Message-ID: On 1 Sep 2009, at 10:04, Carlo de Falco wrote: > 2009/9/1 Carlo de Falco : > >>> Also, what does the code >>> >>> [R, p, q] = chol(A); >>> nnz(R) >>> >> >>> work for Octave and Matlab? >> >> I tried this in Octave, after 30 min it did not finish yet... >> I will only be able to try it on Matlab tomorrow. >> >>> If so what is the value of NNZ of the factorization in both cases. > > I killed the Octave after it had been running more than one hour and > produced no result. > In Matlab it ran in less than a second and the result was: > >>> [R,p,q]=chol(A); >>> nnz (R) > ans = > 1368019 >>> issparse (R) > ans = > 1 >>> nnz(R)/prod(size(A)) > ans = > 7.035863106552923e-03 oops, what I actually meant to show here was >> nnz(R)/prod(size(R)) ans= 1.407374482251814e-02 > Thanks, c. From dbateman at dbateman.org Tue Sep 1 14:09:04 2009 From: dbateman at dbateman.org (David Bateman) Date: Tue, 01 Sep 2009 21:09:04 +0200 Subject: large sparse matrix In-Reply-To: <420ba0760909010104x3c7385fdi39eab8d17440a06f@mail.gmail.com> References: <420ba0760908310753i7fe60591l9d4d657a6db9dade@mail.gmail.com> <25225293.post@talk.nabble.com> <4A9C2A53.2060607@dbateman.org> <67814968-724A-4C38-89A7-01E2D4613C6D@gmail.com> <420ba0760909010104x3c7385fdi39eab8d17440a06f@mail.gmail.com> Message-ID: <4A9D7150.4000000@dbateman.org> Carlo de Falco wrote: > 2009/9/1 Carlo de Falco : > > >>> Also, what does the code >>> >>> [R, p, q] = chol(A); >>> nnz(R) >>> >>> >>> work for Octave and Matlab? >>> >> I tried this in Octave, after 30 min it did not finish yet... >> I will only be able to try it on Matlab tomorrow. >> >> >>> If so what is the value of NNZ of the factorization in both cases. >>> > > I killed the Octave after it had been running more than one hour and > produced no result. > In Matlab it ran in less than a second and the result was: > > >>> [R,p,q]=chol(A); >>> nnz (R) >>> > ans = > 1368019 > >>> issparse (R) >>> > ans = > 1 > >>> nnz(R)/prod(size(A)) >>> > ans = > 7.035863106552923e-03 > > Thanks, > c. > > Could you sent me the code to generate A,B,E and mat... I might have a better chance of figuring out the issue in that case.. Regards davis -- David Bateman dbateman at dbateman.org 35 rue Gambetta +33 1 46 04 02 18 (Home) 92100 Boulogne-Billancourt FRANCE +33 6 72 01 06 33 (Mob) From jwe at octave.org Tue Sep 1 14:58:44 2009 From: jwe at octave.org (John W. Eaton) Date: Tue, 1 Sep 2009 15:58:44 -0400 Subject: grid line style In-Reply-To: <103840bf0908312345m4ca8fc47kc3b0706f5762c490@mail.gmail.com> References: <103840bf0908312243n717802d7u1eaecf06e4adba0d@mail.gmail.com> <19100.47357.934173.170780@segfault.lan> <103840bf0908312345m4ca8fc47kc3b0706f5762c490@mail.gmail.com> Message-ID: <19101.31988.387738.731001@segfault.lan> On 1-Sep-2009, Dr. Johannes Zellner wrote: | gnuplot> set grid lt 1 lc rgb '#aaaaaa' | | makes a solid gray grid. OK, so it would be possible with the gnuplot backend. But what properties should affect the linestyle for the grid lines? I don't think Matlab has any that are independent of the line styles of the axes lines themselves. So we would need to come up with something, which is likelyt to introduce compatibility problems in the future. If you'd like to discuss the development of a feature like this in Octave, then plase start a thread on the maintainers list. Of course a workaround is to write your data to a file and use gnuplt directly... jwe From jthoo at yccd.edu Tue Sep 1 16:11:10 2009 From: jthoo at yccd.edu (John B. Thoo) Date: Tue, 1 Sep 2009 14:11:10 -0700 Subject: ode45 gives solution in the "Dark Side," but not in Octave Message-ID: <5674DAF1-8AED-4C51-A3BA-345713B9CA49@yccd.edu> Hi. I have a question about using ode45 in Octave 3.2.2 (and OdePkg on Mac OS X 10.4.11) vs. in the "Dark Side" 7.4.0 (R2007a) (on a server ... Linux?). My code can be found here at the moment: "run_twoway.m" executes the code. Both Octave and the Dark Side solve the problem (i.e., do not return an error) to produce a solution u, and both give > size (u) ans = 8192 102 However, while I can plot the solution in the Dark Side, in Octave I can plot only the first four frames. In fact, in Octave I get NaN + 0.00000i from u(:,5) on. Why is that? I would appreciate any hints. Thanks. ---John. From jwe at octave.org Tue Sep 1 17:00:18 2009 From: jwe at octave.org (John W. Eaton) Date: Tue, 1 Sep 2009 18:00:18 -0400 Subject: ode45 gives solution in the "Dark Side," but not in Octave In-Reply-To: <5674DAF1-8AED-4C51-A3BA-345713B9CA49@yccd.edu> References: <5674DAF1-8AED-4C51-A3BA-345713B9CA49@yccd.edu> Message-ID: <19101.39282.859417.679486@segfault.lan> On 1-Sep-2009, John B. Thoo wrote: | Hi. I have a question about using ode45 in Octave 3.2.2 (and OdePkg | on Mac OS X 10.4.11) vs. in the "Dark Side" 7.4.0 (R2007a) (on a | server ... Linux?). My code can be found here at the moment: | | | | "run_twoway.m" executes the code. | | Both Octave and the Dark Side solve the problem (i.e., do not return | an error) to produce a solution u, and both give | | > size (u) | ans = | | 8192 102 | | However, while I can plot the solution in the Dark Side, in Octave I | can plot only the first four frames. In fact, in Octave I get NaN + | 0.00000i from u(:,5) on. Why is that? | | I would appreciate any hints. Thanks. Have you tried using lsode in Octave instead of ode45 (which is not part of Octave, BTW). jwe From Mike.Coyne at PACCAR.com Wed Sep 2 10:54:30 2009 From: Mike.Coyne at PACCAR.com (Mike Coyne) Date: Wed, 2 Sep 2009 10:54:30 -0500 Subject: FW: mex files built with fortran having problmes linking in 3.2.2 Message-ID: From: Mike Coyne Sent: Tuesday, September 01, 2009 11:31 AM To: help-octave at octave.org Subject: mex files built with fortran having problmes linking in 3.2.2 I am having problems createing a "mex" file that can access the mx functions . A simple example is in the dist examples mkoctfile --mex myfevalf.f octave --quiet --eval myfevalf warning: mark_as_command is obsolete and will be removed from a future version of Octave error: /afs/pbcell/home/mcoyne/.gnome-desktop/octave-3.2.2/octave-3.2.2/example s/myfevalf.mex: undefined symbol: mxgetstring_ terminate called after throwing an instance of 'octave_execution_exception' panic: Aborted -- stopping myself... attempting to save variables to `octave-core'... save to `octave-core' complete Aborted the mxgetstring_ is the fortran call to the c++ mxGetString ? How do i build ? is there a library to link against? Or alteritibly what would be the correct wrapper function to generate the mxgetstring_ function calling the C++ mxGetString function? My platform is Rhel5 w/ gnu gcc/gfortran 4.4.1 From Thomas.Treichl at gmx.net Wed Sep 2 13:28:54 2009 From: Thomas.Treichl at gmx.net (Thomas Treichl) Date: Wed, 02 Sep 2009 20:28:54 +0200 Subject: ode45 gives solution in the "Dark Side," but not in Octave In-Reply-To: <5674DAF1-8AED-4C51-A3BA-345713B9CA49@yccd.edu> References: <5674DAF1-8AED-4C51-A3BA-345713B9CA49@yccd.edu> Message-ID: <4A9EB966.7050203@gmx.net> John B. Thoo schrieb: > Hi. I have a question about using ode45 in Octave 3.2.2 (and OdePkg > on Mac OS X 10.4.11) vs. in the "Dark Side" 7.4.0 (R2007a) (on a > server ... Linux?). My code can be found here at the moment: > > > > "run_twoway.m" executes the code. > > Both Octave and the Dark Side solve the problem (i.e., do not return > an error) to produce a solution u, and both give > > > size (u) > ans = > > 8192 102 > > However, while I can plot the solution in the Dark Side, in Octave I > can plot only the first four frames. In fact, in Octave I get NaN + > 0.00000i from u(:,5) on. Why is that? > > I would appreciate any hints. Thanks. > > ---John. Good question, I would say that you have a tricky problem and the solver gets into trouble ;) For a quick workaround: what happens if you use another solver like ode78? What about ode5r? I tried your example but get octave-3.2.0:10> run_twoway error: `heaviside' undefined near line 4 column 18 error: called from: error: /Users/Thomas/tmp/thoo/TwoWay/make_k.m at line 4, column 14 error: /Users/Thomas/tmp/thoo/TwoWay/run_twoway.m at line 20, column 3 Best regards Thomas From jwe at octave.org Wed Sep 2 14:00:13 2009 From: jwe at octave.org (John W. Eaton) Date: Wed, 2 Sep 2009 15:00:13 -0400 Subject: FW: mex files built with fortran having problmes linking in 3.2.2 In-Reply-To: References: Message-ID: <19102.49342.644.703561@segfault.lan> On 2-Sep-2009, Mike Coyne wrote: | From: Mike Coyne | Sent: Tuesday, September 01, 2009 11:31 AM | To: help-octave at octave.org | Subject: mex files built with fortran having problmes linking in 3.2.2 | | I am having problems createing a "mex" file that can access the mx | functions . | | A simple example is in the dist examples | mkoctfile --mex myfevalf.f | | octave --quiet --eval myfevalf | warning: mark_as_command is obsolete and will be removed from a future | version of Octave | error: | /afs/pbcell/home/mcoyne/.gnome-desktop/octave-3.2.2/octave-3.2.2/example | s/myfevalf.mex: undefined symbol: mxgetstring_ | terminate called after throwing an instance of | 'octave_execution_exception' | panic: Aborted -- stopping myself... | attempting to save variables to `octave-core'... | save to `octave-core' complete | Aborted | | the mxgetstring_ is the fortran call to the c++ mxGetString ? | How do i build ? is there a library to link against? Or alteritibly what | would be the correct wrapper function to generate the mxgetstring_ | function calling the C++ mxGetString function? | | My platform is Rhel5 w/ gnu gcc/gfortran 4.4.1 Octave doesn't provide Fortran bindings for the MEX interface. I consider this a missing feature, not a bug. I would of course welcome a patch to add them. But before submitting a patch, it would probably be best to discuss the implementation on the maintainers list. The example files are in the distribution because there was some (very incomplete) support for Fortran MEX files at one time, but it was removed when the C MEX interface was finished. I guess we forgot to remove the Fortran example files and/or make a note in the docs. jwe From dimitry at latinmail.com Wed Sep 2 14:25:56 2009 From: dimitry at latinmail.com (dimitry A.) Date: Wed, 02 Sep 2009 21:25:56 +0200 Subject: No subject Message-ID: <200909021926.n82JQ37M014807@mx1.cae.wisc.edu> An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090902/af5e844a/attachment.html From jthoo at yccd.edu Wed Sep 2 18:55:40 2009 From: jthoo at yccd.edu (John B. Thoo) Date: Wed, 2 Sep 2009 16:55:40 -0700 Subject: ode45 gives solution in the "Dark Side," but not in Octave In-Reply-To: <19101.39282.859417.679486@segfault.lan> References: <5674DAF1-8AED-4C51-A3BA-345713B9CA49@yccd.edu> <19101.39282.859417.679486@segfault.lan> Message-ID: <25EC71B0-6023-43E8-8A95-5488C5CEB9E6@yccd.edu> On Sep 1, 2009, at 3:00 PM, John W. Eaton wrote: > On 1-Sep-2009, John B. Thoo wrote: > > | Hi. I have a question about using ode45 in Octave 3.2.2 (and OdePkg > | on Mac OS X 10.4.11) vs. in the "Dark Side" 7.4.0 (R2007a) (on a > | server ... Linux?). My code can be found here at the moment: > | > | > | > | "run_twoway.m" executes the code. > | > | Both Octave and the Dark Side solve the problem (i.e., do not return > | an error) to produce a solution u, and both give > | > | > size (u) > | ans = > | > | 8192 102 > | > | However, while I can plot the solution in the Dark Side, in Octave I > | can plot only the first four frames. In fact, in Octave I get > NaN + > | 0.00000i from u(:,5) on. Why is that? > | > | I would appreciate any hints. Thanks. > > Have you tried using lsode in Octave instead of ode45 (which is not > part of Octave, BTW). I haven't tried lsode. The reason for my using ode45 is my advisor uses the Dark Side only, and we need to run the same code. Thanks. ---John. From jthoo at yccd.edu Wed Sep 2 18:58:14 2009 From: jthoo at yccd.edu (John B. Thoo) Date: Wed, 2 Sep 2009 16:58:14 -0700 Subject: ode45 gives solution in the "Dark Side," but not in Octave In-Reply-To: <4A9EB966.7050203@gmx.net> References: <5674DAF1-8AED-4C51-A3BA-345713B9CA49@yccd.edu> <4A9EB966.7050203@gmx.net> Message-ID: <19FD46E0-2D97-4FA3-BAA6-2938D34AB6A0@yccd.edu> On Sep 2, 2009, at 11:28 AM, Thomas Treichl wrote: > John B. Thoo schrieb: >> Hi. I have a question about using ode45 in Octave 3.2.2 (and >> OdePkg on Mac OS X 10.4.11) vs. in the "Dark Side" 7.4.0 (R2007a) >> (on a server ... Linux?). My code can be found here at the moment: >> >> "run_twoway.m" executes the code. >> Both Octave and the Dark Side solve the problem (i.e., do not >> return an error) to produce a solution u, and both give >> > size (u) >> ans = >> 8192 102 >> However, while I can plot the solution in the Dark Side, in Octave >> I can plot only the first four frames. In fact, in Octave I get >> NaN + 0.00000i from u(:,5) on. Why is that? >> I would appreciate any hints. Thanks. >> ---John. > > Good question, I would say that you have a tricky problem and the > solver gets into trouble ;) For a quick workaround: what happens if > you use another solver like ode78? What about ode5r? I tried your > example but get > > octave-3.2.0:10> run_twoway > error: `heaviside' undefined near line 4 column 18 > error: called from: > error: /Users/Thomas/tmp/thoo/TwoWay/make_k.m at line 4, column 14 > error: /Users/Thomas/tmp/thoo/TwoWay/run_twoway.m at line 20, > column 3 > > Best regards > > Thomas Hi, Thomas. The function "heaviside" is part of SpecFun package: I will try the other solvers you suggest. Thanks. ---John. From jwe at octave.org Wed Sep 2 19:30:34 2009 From: jwe at octave.org (John W. Eaton) Date: Wed, 2 Sep 2009 20:30:34 -0400 Subject: ode45 gives solution in the "Dark Side," but not in Octave In-Reply-To: <25EC71B0-6023-43E8-8A95-5488C5CEB9E6@yccd.edu> References: <5674DAF1-8AED-4C51-A3BA-345713B9CA49@yccd.edu> <19101.39282.859417.679486@segfault.lan> <25EC71B0-6023-43E8-8A95-5488C5CEB9E6@yccd.edu> Message-ID: <19103.3626.250351.795124@segfault.lan> On 2-Sep-2009, John B. Thoo wrote: | On Sep 1, 2009, at 3:00 PM, John W. Eaton wrote: | | > On 1-Sep-2009, John B. Thoo wrote: | > | > | Hi. I have a question about using ode45 in Octave 3.2.2 (and OdePkg | > | on Mac OS X 10.4.11) vs. in the "Dark Side" 7.4.0 (R2007a) (on a | > | server ... Linux?). My code can be found here at the moment: | > | | > | | > | | > | "run_twoway.m" executes the code. | > | | > | Both Octave and the Dark Side solve the problem (i.e., do not return | > | an error) to produce a solution u, and both give | > | | > | > size (u) | > | ans = | > | | > | 8192 102 | > | | > | However, while I can plot the solution in the Dark Side, in Octave I | > | can plot only the first four frames. In fact, in Octave I get | > NaN + | > | 0.00000i from u(:,5) on. Why is that? | > | | > | I would appreciate any hints. Thanks. | > | > Have you tried using lsode in Octave instead of ode45 (which is not | > part of Octave, BTW). | | I haven't tried lsode. The reason for my using ode45 is my advisor | uses the Dark Side only, and we need to run the same code. Thanks. Here's a simple wrapper for lsode that I think will provide a simple ode45 interface. It doesn't cover all the options, but it will probably work in a lot of cases, provided that you just need a solution, and not specifically a Runge-Kutta method. It shoudl be fairly easy to fix the interface if ti isn't compatible enough for you. jwe -------------- next part -------------- An embedded and charset-unspecified text was scrubbed... Name: ode45.m Url: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090902/6a2c382d/attachment.ksh From jthoo at yccd.edu Thu Sep 3 07:18:35 2009 From: jthoo at yccd.edu (John B. Thoo) Date: Thu, 3 Sep 2009 05:18:35 -0700 Subject: ode45 gives solution in the "Dark Side," but not in Octave In-Reply-To: <4A9EB966.7050203@gmx.net> References: <5674DAF1-8AED-4C51-A3BA-345713B9CA49@yccd.edu> <4A9EB966.7050203@gmx.net> Message-ID: <53FECAC2-F628-4A22-BC27-0ED9184EBCBB@yccd.edu> On Sep 2, 2009, at 11:28 AM, Thomas Treichl wrote: > John B. Thoo schrieb: >> Hi. I have a question about using ode45 in Octave 3.2.2 (and >> OdePkg on Mac OS X 10.4.11) vs. in the "Dark Side" 7.4.0 (R2007a) >> (on a server ... Linux?). My code can be found here at the moment: >> >> "run_twoway.m" executes the code. >> Both Octave and the Dark Side solve the problem (i.e., do not >> return an error) to produce a solution u, and both give >> > size (u) >> ans = >> 8192 102 >> However, while I can plot the solution in the Dark Side, in Octave >> I can plot only the first four frames. In fact, in Octave I get >> NaN + 0.00000i from u(:,5) on. Why is that? >> I would appreciate any hints. Thanks. >> ---John. > > Good question, I would say that you have a tricky problem and the > solver gets into trouble ;) For a quick workaround: what happens if > you use another solver like ode78? What about ode5r? I tried your > example but get > > octave-3.2.0:10> run_twoway > error: `heaviside' undefined near line 4 column 18 > error: called from: > error: /Users/Thomas/tmp/thoo/TwoWay/make_k.m at line 4, column 14 > error: /Users/Thomas/tmp/thoo/TwoWay/run_twoway.m at line 20, > column 3 > > Best regards > > Thomas Hi, Thomas. With ode78, I can plot up to three frames. ode5r gives an error: octave-3.2.2:11> run_twoway error: `ode5r' undefined near line 36 column 11 error: called from: error: /Users/jbthoo/Desktop/NumMethPractice/MHD/TwoWay/ run_twoway.m at line 36, column 9 octave-3.2.2:11> But you've given me an idea: I look in ~/octave/odepkg-0.6.7/, and see I also have ode23 and ode54. Unfortunately, With ode23, I can plot up to seven frames. With ode54, I can plot up to four frames. Thanks. ---John. From jwe at octave.org Thu Sep 3 07:21:16 2009 From: jwe at octave.org (John W. Eaton) Date: Thu, 3 Sep 2009 08:21:16 -0400 Subject: ode45 gives solution in the "Dark Side," but not in Octave In-Reply-To: <53FECAC2-F628-4A22-BC27-0ED9184EBCBB@yccd.edu> References: <5674DAF1-8AED-4C51-A3BA-345713B9CA49@yccd.edu> <4A9EB966.7050203@gmx.net> <53FECAC2-F628-4A22-BC27-0ED9184EBCBB@yccd.edu> Message-ID: <19103.46268.500179.796623@segfault.lan> On 3-Sep-2009, John B. Thoo wrote: | With ode78, I can plot up to three frames. ode5r gives an error: | | octave-3.2.2:11> run_twoway | error: `ode5r' undefined near line 36 column 11 | error: called from: | error: /Users/jbthoo/Desktop/NumMethPractice/MHD/TwoWay/ | run_twoway.m at line 36, column 9 | octave-3.2.2:11> | | But you've given me an idea: I look in ~/octave/odepkg-0.6.7/, and | see I also have ode23 and ode54. Unfortunately, | | With ode23, I can plot up to seven frames. | With ode54, I can plot up to four frames. Did you try my wrapper for lsode? I'm curious to know whether it can solve your problem. jwe From Thomas.Treichl at gmx.net Thu Sep 3 13:15:26 2009 From: Thomas.Treichl at gmx.net (Thomas Treichl) Date: Thu, 03 Sep 2009 20:15:26 +0200 Subject: ode45 gives solution in the "Dark Side," but not in Octave In-Reply-To: <19FD46E0-2D97-4FA3-BAA6-2938D34AB6A0@yccd.edu> References: <5674DAF1-8AED-4C51-A3BA-345713B9CA49@yccd.edu> <4A9EB966.7050203@gmx.net> <19FD46E0-2D97-4FA3-BAA6-2938D34AB6A0@yccd.edu> Message-ID: <4AA007BE.3010200@gmx.net> John B. Thoo schrieb: > Hi, Thomas. The function "heaviside" is part of SpecFun package: > > > > I will try the other solvers you suggest. Thanks. > > ---John. Ok, I was able to start your script - thanks for the hint. You're using fixed time steps (tspan) with the ode45 solver which is absolutely okay, but the next argument you use (w0) already is complex even before ode45 can do its first step, ie. the initial values already are complex. I don't expect that these values should be complex?! Here is what I see if I remove the semicolon at the end of the line w0=... octave-3.2.0:1> run_twoway w0 = -0.537882842739990 + 0.000000000000000i -0.537882789290712 + 0.000000000000000i -0.537882628942835 + 0.000000000000000i -0.537882361696230 + 0.000000000000000i -0.537881987550684 - 0.000000000000000i -0.537881506505897 - 0.000000000000000i -0.537880918561486 + 0.000000000000000i I think that this is the problem you have - ode45 thinks your problem is complex and then tries to solve your complex problem, which it is able to if the complex problem makes sense... So the origin of this problem seems to be somewhere else in your initialization routines. Can you confirm? Best regards Thomas PS. Just because of interest why you don't have ode5r, did you install OdePkg with the 'pkg' command or did you just unpack the *.tar.gz into some directory? ode5r should be there if you installed OdePkg (it is globally installed on my system but it can also be somewhere in your local home directory) octave-3.1.55:7> which ode5r `ode5r' is a function from the file /Users/Thomas/bin/Octave.app.3.2.0/Octave.app/Contents/Resources/libexec/octave/packages/odepkg-0.6.7/i386-apple-darwin8.11.1-api-v37/dldsolver.oct From jthoo at yccd.edu Thu Sep 3 13:33:48 2009 From: jthoo at yccd.edu (John B. Thoo) Date: Thu, 3 Sep 2009 11:33:48 -0700 Subject: ode45 gives solution in the "Dark Side," but not in Octave In-Reply-To: <19103.3626.250351.795124@segfault.lan> References: <5674DAF1-8AED-4C51-A3BA-345713B9CA49@yccd.edu> <19101.39282.859417.679486@segfault.lan> <25EC71B0-6023-43E8-8A95-5488C5CEB9E6@yccd.edu> <19103.3626.250351.795124@segfault.lan> Message-ID: <291B5407-2F95-4C63-AEC5-6C0129951092@yccd.edu> On Sep 2, 2009, at 5:30 PM, John W. Eaton wrote: > On 2-Sep-2009, John B. Thoo wrote: > > | On Sep 1, 2009, at 3:00 PM, John W. Eaton wrote: > | > | > On 1-Sep-2009, John B. Thoo wrote: > | > > | > | Hi. I have a question about using ode45 in Octave 3.2.2 (and > OdePkg > | > | on Mac OS X 10.4.11) vs. in the "Dark Side" 7.4.0 (R2007a) (on a > | > | server ... Linux?). My code can be found here at the moment: > | > | > | > | > | > | > | > | "run_twoway.m" executes the code. > | > | > | > | Both Octave and the Dark Side solve the problem (i.e., do not > return > | > | an error) to produce a solution u, and both give > | > | > | > | > size (u) > | > | ans = > | > | > | > | 8192 102 > | > | > | > | However, while I can plot the solution in the Dark Side, in > Octave I > | > | can plot only the first four frames. In fact, in Octave I get > | > NaN + > | > | 0.00000i from u(:,5) on. Why is that? > | > | > | > | I would appreciate any hints. Thanks. > | > > | > Have you tried using lsode in Octave instead of ode45 (which is > not > | > part of Octave, BTW). > | > | I haven't tried lsode. The reason for my using ode45 is my advisor > | uses the Dark Side only, and we need to run the same code. Thanks. > > Here's a simple wrapper for lsode that I think will provide a simple > ode45 interface. It doesn't cover all the options, but it will > probably work in a lot of cases, provided that you just need a > solution, and not specifically a Runge-Kutta method. It shoudl be > fairly easy to fix the interface if ti isn't compatible enough for > you. > > jwe > > function [t_out, x] = ode45 (f, t, x0, options) > > if (nargin == 3 || nargin == 4) > > global __ode45s_rhs_fcn__; > __ode45s_rhs_fcn__ = f; > > if (nargin == 4) > if (isfield (options, "RelTol") && ! isempty (options.RelTol)) > lsode_options ("relative tolerance", options.RelTol) > endif > if (isfield (options, "AbsTol") && ! isempty (options.AbsTol)) > lsode_options ("absolute tolerance", options.AbsTol) > endif > endif > > x = lsode (@__lsode_rhs__, x0, t); > t_out = t; > > else > print_usage (); > endif > > endfunction > > % > ---------------------------------------------------------------------- > > function xdot = __lsode_rhs__ (x, t) > > global __ode45s_rhs_fcn__; > > xdot = __ode45s_rhs_fcn__ (t, x); > > endfunction Hi, jwe. Thanks for taking time on this. I'm sorry, but I'm not familiar with using a "wrapper," so I haven't tried it, yet. Do I save the above to a .m file? Then how do I call on it? In any case, I tried lsode directly in my code, in which, making a guess for how to proceed, I replaced the lines in "run_twoway.m" options = odeset (); [t, w] = ode45 (@F, tspan, w0, options, k, lx, ltrunc, epsilon, mu); with the line [w, istate, msg] = lsode (@F, tspan, w0, k, lx, ltrunc, epsilon, mu); But when I executed the code, I got this: octave-3.2.2:5> run_twoway error: Invalid call to lsode. Correct usage is: -- Loadable Function: [X, ISTATE, MSG] = lsode (FCN, X_0, T, T_CRIT) Additional help for built-in functions and operators is available in the on-line version of the manual. Use the command `doc ' to search the manual index. Help and information about Octave is also available on the WWW at http://www.octave.org and via the help at octave.org mailing list. octave-3.2.2:5> Thanks again. ---John. From dasergatskov at gmail.com Thu Sep 3 17:09:05 2009 From: dasergatskov at gmail.com (Dmitri A. Sergatskov) Date: Thu, 3 Sep 2009 17:09:05 -0500 Subject: [OctDev] test_sparse.m fails on ppc64 build In-Reply-To: References: Message-ID: <892b16670909031509w39a3c627w158438ec186aba0b@mail.gmail.com> On Thu, Sep 3, 2009 at 3:27 PM, Orion Poplawski wrote: > Running make check on octave 3.2.2 build in Fedora Rawhide fails in > test_sparse.m on ppc64. > > Fixed test scripts: > ?test_args.m ............................................ PASS ? 26/26 > ..... > ?test_sparse.m ..........................................panic: Segmentation > fault -- stopping myself... > make[2]: *** [check] Segmentation fault > > > Fedora bug: https://bugzilla.redhat.com/show_bug.cgi?id=521142 > Build log: http://koji.fedoraproject.org/koji/getfile?taskID=1653016&name=build.log > > Any ideas? ?Any kind of test verbosity that can be turned on to help debug? > > Thanks! > > - Orion Poplawski > First of all i think it should go to octave mailing list rather than to octave-forge (cc accordingly). Second, the lapack/atlas libraries on Fedora 11 and rawhide are suspect (they are definitely broken on i386). Sometime ago somebody decided that some files from lapack that should be compiled without optimization (per lapack's docs) can be compiled with Os. This used to work for a while but now gcc got more aggressive and breaks those on some platforms (at least on i386 and may be on ppc). Sincerely, Dmitri. -- From asmund.skjaveland at bio.uio.no Fri Sep 4 06:40:25 2009 From: asmund.skjaveland at bio.uio.no (=?ISO-8859-1?Q?=C5smund_Skj=E6veland?=) Date: Fri, 04 Sep 2009 13:40:25 +0200 Subject: plotting NaN values as blank in pcolor plots Message-ID: <4AA0FCA9.4040102@ulrik.uio.no> When I plot an array using pcolor, the NaN fields are plotted as the lowest color in the colormap. How do I make them plot blank, like in matlab? Versions: gnuplot 4.2 patchlevel 4 (stock Ubuntu 9.04 package) GNU Octave, version 3.2.2 (self-compiled) -- ?smund Skj?veland -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 261 bytes Desc: OpenPGP digital signature Url : https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090904/bbe7167e/attachment.bin From marcio.alves.diniz at gmail.com Fri Sep 4 06:29:12 2009 From: marcio.alves.diniz at gmail.com (=?ISO-8859-1?Q?M=E1rcio_Diniz?=) Date: Fri, 4 Sep 2009 08:29:12 -0300 Subject: bfgsmin works for a version but not for the other Message-ID: <933ae1930909040429k72bae91eka94f6dac1765c7b9@mail.gmail.com> Hi there! I am using Octave 2.9.9 and the bfgsmin works well. However, the same code does not work when I try to run it in Octave 3.0.1 - the error message is "warning: bfgsmin: failure, exiting. Try different start values?" even though I am using the same starting values. Is there any difference between the bfgsmin versions? If not, what is the problem? Thanks in advance Marcio Diniz -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090904/3314840f/attachment.html From dennis.eder at etas.com Fri Sep 4 13:57:28 2009 From: dennis.eder at etas.com (dennis.eder at etas.com) Date: Fri, 4 Sep 2009 20:57:28 +0200 Subject: =?ISO-8859-1?Q?AUTO=3A_Dennis_Eder_ist_au=DFer_Haus_=28R=FCckkehr_am?= =?ISO-8859-1?Q?_08=2E09=2E2009=29?= Message-ID: Ich bin bis 08.09.2009 abwesend Hinweis: Dies ist eine automatische Antwort auf Ihre Nachricht " Help-octave Digest, Vol 42, Issue 5" gesendet am 04.09.2009 20:52:46. Diese ist die einzige Benachrichtigung, die Sie empfangen werden, w?hrend diese Person abwesend ist. From etienne at isr.ist.utl.pt Fri Sep 4 20:36:40 2009 From: etienne at isr.ist.utl.pt (etienne at isr.ist.utl.pt) Date: Fri, 04 Sep 2009 18:36:40 -0700 Subject: bfgsmin works for a version but not for the other In-Reply-To: <933ae1930909040429k72bae91eka94f6dac1765c7b9@mail.gmail.com> References: <933ae1930909040429k72bae91eka94f6dac1765c7b9@mail.gmail.com> Message-ID: <20090904183640.18194ipf08g8uruo@webmail.isr.ist.utl.pt> Hi Marcio, maybe your (new) octave and (older) octave-forge versions don't match? Hth, Etienne Quoting M?rcio Diniz (Fri, 4 Sep 2009 08:29:12 -0300): > Hi there! > I am using Octave 2.9.9 and the bfgsmin works well. However, the > same code does not work when I try to run it in Octave 3.0.1 - the > error message is "warning: bfgsmin: failure, exiting. Try different start > values?" even though I am using the same starting values. > Is there any difference between the bfgsmin versions? If not, what > is the problem? > Thanks in advance > Marcio Diniz -- http://www.isr.ist.utl.pt/~etienne ---------------------------------------------------------------- This message was sent using IMP, the Internet Messaging Program. From babelproofreader at gmail.com Sat Sep 5 10:09:36 2009 From: babelproofreader at gmail.com (babelproofreader) Date: Sat, 5 Sep 2009 08:09:36 -0700 (PDT) Subject: Moving polynomial fit Message-ID: <25309400.post@talk.nabble.com> I would like to write a script/function for use on a time series that will least squares fit a polynomial of a given degree to a moving window across the time series in the same way as a moving average computes an average of a moving window, the output of the script/function being a vector of the extreme right hand edge/last values of the fitted polynomial over the moving window. I have tried using the Savitsky-Golay filters from the Signals package but they are not suitable for my purposes as the end conditions mean that the values of the fitted polynomial at the right hand edges of the moving window are different from the values calculated when the data are no longer at the right hand edge. What in-built Octave functions should I consider using to achieve the above i.e. polyfit or some other function(s)? Also, as loops can be quite slow, is there a more efficient way of coding the above rather than having to resort to a for loop? -- View this message in context: http://www.nabble.com/Moving-polynomial-fit-tp25309400p25309400.html Sent from the Octave - General mailing list archive at Nabble.com. From macy at sfo.com Sat Sep 5 10:38:38 2009 From: macy at sfo.com (macy at sfo.com) Date: Sat, 5 Sep 2009 08:38:38 -0700 (PDT) Subject: Moving polynomial fit In-Reply-To: <25309400.post@talk.nabble.com> References: <25309400.post@talk.nabble.com> Message-ID: <1161.66.81.51.141.1252165118.squirrel@cp01.sfo.com> I had to do something like this for 2 minutes of streaming data once. The FOR loop took 20 minutes+ and the array process took 12 seconds! It went something like this: Multiply the original vector in such a way as to make a 'shifted' array. Where each line of the array is your original vector, but shifted slightly. Then, apply to the array in a single stomp and you should be there I had to expand the memory octave used, else kept crashing my system when the data files were up around 20MB Robert > I would like to write a script/function for use on a time series that will > least squares fit a polynomial of a given degree to a moving window across > the time series in the same way as a moving average computes an average of > a > moving window, the output of the script/function being a vector of the > extreme right hand edge/last values of the fitted polynomial over the > moving > window. I have tried using the Savitsky-Golay filters from the Signals > package but they are not suitable for my purposes as the end conditions > mean > that the values of the fitted polynomial at the right hand edges of the > moving window are different from the values calculated when the data are > no > longer at the right hand edge. What in-built Octave functions should I > consider using to achieve the above i.e. polyfit or some other > function(s)? > Also, as loops can be quite slow, is there a more efficient way of coding > the above rather than having to resort to a for loop? > > > -- > View this message in context: > http://www.nabble.com/Moving-polynomial-fit-tp25309400p25309400.html > Sent from the Octave - General mailing list archive at Nabble.com. From bpabbott at mac.com Sat Sep 5 12:23:11 2009 From: bpabbott at mac.com (Ben Abbott) Date: Sat, 05 Sep 2009 13:23:11 -0400 Subject: Moving polynomial fit In-Reply-To: <25309400.post@talk.nabble.com> References: <25309400.post@talk.nabble.com> Message-ID: On Sep 5, 2009, at 11:09 AM, babelproofreader wrote: > I would like to write a script/function for use on a time series > that will > least squares fit a polynomial of a given degree to a moving window > across > the time series in the same way as a moving average computes an > average of a > moving window, the output of the script/function being a vector of the > extreme right hand edge/last values of the fitted polynomial over > the moving > window. I have tried using the Savitsky-Golay filters from the Signals > package but they are not suitable for my purposes as the end > conditions mean > that the values of the fitted polynomial at the right hand edges of > the > moving window are different from the values calculated when the data > are no > longer at the right hand edge. What in-built Octave functions should I > consider using to achieve the above i.e. polyfit or some other > function(s)? > Also, as loops can be quite slow, is there a more efficient way of > coding > the above rather than having to resort to a for loop? There might be a better way ... Assuming you'd like to center your window about the data point of interest ... ---------------- begin: mwpolysmooth.m --------------- function ym = mwpolysmooth (x, y, order, window) % USAGE: ym = mwpolysmooth (x, y, order, window) xc = num2cell(x); idx = @(xc) find (abs (x - xc) < 0.5*window); n = cellfun (idx, xc, 'uniformoutput', false); mpfit = @(n) polyfit (x(n), y(n), order); pm = cellfun (mpfit, n, 'uniformoutput', false); nc = num2cell (1:numel(x)); mpval = @(n) polyval (pm{n}, x(n)); ym = cell2mat (cellfun (mpval, nc, 'uniformoutput', false)); end %!demo %! x = 0:0.1:10; %! y = rand (size(x)) + cos (x); %! window = 5; %! order = 2; %! ym = mwpolysmooth (x, y, order, window); %! clf %! plot (x, y, 's', x, ym) ---------------- end: mwpolysmooth.m --------------- Ben From humboldt.fleischer at gmail.com Sat Sep 5 14:09:02 2009 From: humboldt.fleischer at gmail.com (vHF) Date: Sat, 5 Sep 2009 12:09:02 -0700 (PDT) Subject: Supplying Jacobian to lsode Message-ID: <25311485.post@talk.nabble.com> Hi all, I am relatively new to Octave and my problem is most likely rather trivial, so I apologise in advance. I am trying to create an .m file that would have a definition of a system of ODEs and call the lsode solver with the Jacobian supplied. What I have now is: ***begin script*** u = linspace(0, 72, 72*60); init = [0; 10]; function res = f(x, u) res(1) = 2.0*x(2).*x(2) - 3.0*x(1); res(2) = -2.0*x(2).*x(2) + 6.0*x(1); endfunction; function res = jac(x, u) res(1) = -3.0; res(1,2) = 2.0*x(2); res(2,1) = 6.0; res(2,2) = -2.0*x(2); endfunction; x = lsode(["f"; "jac"], init, u); ***end script*** However, this fails with the following output: ***begin console output*** error: `x' undefined near line 5 column 16 error: evaluating binary operator `*' near line 5, column 15 error: evaluating binary operator `.*' near line 5, column 20 error: evaluating binary operator `-' near line 5, column 27 error: evaluating assignment expression near line 5, column 10 error: called from `f' error: evaluating assignment expression near line 16, column 40 error: called from `__lsode_fcn__U__' error: lsode: evaluation of user-supplied function failed error: lsode: inconsistent sizes for state and derivative vectors error: evaluating assignment expression near line 16, column 3 error: near line 16 of file `/home/marek/Desktop/octave/dimer.m' ***end console output*** What am I doing wrong? Thanks in advance, vHF -- View this message in context: http://www.nabble.com/Supplying-Jacobian-to-lsode-tp25311485p25311485.html Sent from the Octave - General mailing list archive at Nabble.com. From humboldt.fleischer at gmail.com Sat Sep 5 14:14:16 2009 From: humboldt.fleischer at gmail.com (vHF) Date: Sat, 5 Sep 2009 12:14:16 -0700 (PDT) Subject: Supplying Jacobian to lsode In-Reply-To: <25311485.post@talk.nabble.com> References: <25311485.post@talk.nabble.com> Message-ID: <25311528.post@talk.nabble.com> vHF wrote: > > res(1) = -3.0; > This obviously reads "res(1,1) = -3.0" in my script file. vHF -- View this message in context: http://www.nabble.com/Supplying-Jacobian-to-lsode-tp25311485p25311528.html Sent from the Octave - General mailing list archive at Nabble.com. From sraevsky at gmail.com Sun Sep 6 00:01:41 2009 From: sraevsky at gmail.com (Scott Raevsky) Date: Sat, 5 Sep 2009 22:01:41 -0700 Subject: Please help me change the prompt Message-ID: Hi, I just installed octave on Windows. Whenever I enter something into the prompt, I get the correct response and then on a newline the following string: "octave-3.2.2.exe:1:C:\Octave\3.2.2_gcc-4.3.0\bin". How do I stop this from printing to the screen every time I hit enter? It's really annoying! Thanks! -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090905/85b75af8/attachment.html From rcrummett at gmail.com Sun Sep 6 01:04:34 2009 From: rcrummett at gmail.com (Ron Crummett) Date: Sat, 5 Sep 2009 23:04:34 -0700 Subject: Please help me change the prompt In-Reply-To: References: Message-ID: create a file .octaverc in your starting directory with the following line: PS1 ("(your prompt here)"); for example, if you want your prompt to mimic the Matlab prompt, try PS1 (">> "); The .octaverc file can be used for other customizations as well. Hope it helps, -Ron On Sat, Sep 5, 2009 at 10:01 PM, Scott Raevsky wrote: > Hi, > > I just installed octave on Windows. Whenever I enter something into the > prompt, I get the correct response and then on a newline the following > string: "octave-3.2.2.exe:1:C:\Octave\3.2.2_gcc-4.3.0\bin". How do I stop > this from printing to the screen every time I hit enter? It's really > annoying! > > Thanks! > > > _______________________________________________ > Help-octave mailing list > Help-octave at octave.org > https://www-old.cae.wisc.edu/mailman/listinfo/help-octave > > -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090905/89d56fe4/attachment.html From jwe at octave.org Sun Sep 6 01:22:28 2009 From: jwe at octave.org (John W. Eaton) Date: Sun, 6 Sep 2009 02:22:28 -0400 Subject: Supplying Jacobian to lsode In-Reply-To: <25311485.post@talk.nabble.com> References: <25311485.post@talk.nabble.com> Message-ID: <19107.21796.715766.482519@segfault.lan> On 5-Sep-2009, vHF wrote: | I am relatively new to Octave and my problem is most likely rather trivial, | so I apologise in advance. | I am trying to create an .m file that would have a definition of a system of | ODEs and call the lsode solver with the Jacobian supplied. What I have now | is: | | ***begin script*** | u = linspace(0, 72, 72*60); | init = [0; 10]; | | function res = f(x, u) | res(1) = 2.0*x(2).*x(2) - 3.0*x(1); | res(2) = -2.0*x(2).*x(2) + 6.0*x(1); | endfunction; | | function res = jac(x, u) | res(1) = -3.0; | res(1,2) = 2.0*x(2); | res(2,1) = 6.0; | res(2,2) = -2.0*x(2); | endfunction; | | x = lsode(["f"; "jac"], init, u); | ***end script*** | | However, this fails with the following output: | | ***begin console output*** | error: `x' undefined near line 5 column 16 | error: evaluating binary operator `*' near line 5, column 15 | error: evaluating binary operator `.*' near line 5, column 20 | error: evaluating binary operator `-' near line 5, column 27 | error: evaluating assignment expression near line 5, column 10 | error: called from `f' | error: evaluating assignment expression near line 16, column 40 | error: called from `__lsode_fcn__U__' | error: lsode: evaluation of user-supplied function failed | error: lsode: inconsistent sizes for state and derivative vectors | error: evaluating assignment expression near line 16, column 3 | error: near line 16 of file `/home/marek/Desktop/octave/dimer.m' | ***end console output*** | | | What am I doing wrong? Try x = lsode ({@f, @jac}, init, u); instead. I think there is an error in your Jacobian. I think it should be -3 4*x(2) 6 -4*x(2) It would probably be slightly more efficient to write function res = f (x, u) res = zeros (2, 1); tmp = 2*x(2)^2; res(1) = tmp - 3.0*x(1); res(2) = -tmp + 6.0*x(1); endfunction; function res = jac (x, u) res = zeros (2, 2); tmp = 4.0*x(2); res(1,1) = -3.0; res(1,2) = tmp; res(2,1) = 6.0; res(2,2) = -tmp; endfunction; or perhaps function res = f (x, u) tmp = 2*x(2)^2; res = [tmp-3*x(1); -tmp+6*x(1)]; endfunction function res = jac (x, u) tmp = 4*x(2); res = [-3, tmp; 6, -tmp]; endfunction because your functions are repeatedly resizing the res vectors. BTW, this system appears to be unstable, and all the interesting behavior seems to happen before u = 1. jwe From tmacchant at yahoo.co.jp Sun Sep 6 03:59:53 2009 From: tmacchant at yahoo.co.jp (Tatsuro MATSUOKA) Date: Sun, 6 Sep 2009 17:59:53 +0900 (JST) Subject: Fwd: Re: Please help me change the prompt Message-ID: <20090906085953.16623.qmail@web3811.mail.bbt.yahoo.co.jp> --- Tatsuro MATSUOKA wrote: > Date:Sun, 6 Sep 2009 15:10:10 +0900 (JST) > From:Tatsuro MATSUOKA > Subject:Re: Please help me change the prompt > To:Scott Raevsky > > Hello > Please comment out line 74 of .....\Octave\3.2.2_gcc-4.3.0\share\octave\3.2.2\m\startup\octaverc > > 72: ## set default prompt > 73: > 74: PS1("\\s:\\#:\\w\n> "); > | > V > 74 # PS1("\\s:\\#:\\w\n> "); > > or change like > 74: PS1(">> "); > > Regards > > Tatsuro > --- Scott Raevsky wrote: > > > Hi, > > > > I just installed octave on Windows. Whenever I enter something into the > > prompt, I get the correct response and then on a newline the following > > string: "octave-3.2.2.exe:1:C:\Octave\3.2.2_gcc-4.3.0\bin". How do I stop > > this from printing to the screen every time I hit enter? It's really > > annoying! > > > > Thanks! > > > _______________________________________________ > > Help-octave mailing list > > Help-octave at octave.org > > https://www-old.cae.wisc.edu/mailman/listinfo/help-octave > > > > > -------------------------------------- > Thanks 10 years! Yahoo! Shopping and Yahoo! Auctions > http://pr.mail.yahoo.co.jp/ec10years/ > -------------------------------------- Thanks 10 years! Yahoo! Shopping and Yahoo! Auctions http://pr.mail.yahoo.co.jp/ec10years/ From humboldt.fleischer at gmail.com Sun Sep 6 06:13:19 2009 From: humboldt.fleischer at gmail.com (vHF) Date: Sun, 6 Sep 2009 04:13:19 -0700 (PDT) Subject: Supplying Jacobian to lsode In-Reply-To: <19107.21796.715766.482519@segfault.lan> References: <25311485.post@talk.nabble.com> <19107.21796.715766.482519@segfault.lan> Message-ID: <25316691.post@talk.nabble.com> Dear John, John W. Eaton-3 wrote: > > Try > > x = lsode ({@f, @jac}, init, u); > > instead. > Brilliant -- this works. John W. Eaton wrote: > > I think there is an error in your Jacobian. > ... > BTW, this system appears to be unstable, and all the interesting > behavior seems to happen before u = 1. > I should have mentioned that I submitted the smallest example I could think of, not the real thing. Now I am going back to 60+ equations, so your performance tips are also going to be very useful! Thanks, Marek (vHF) -- View this message in context: http://www.nabble.com/Supplying-Jacobian-to-lsode-tp25311485p25316691.html Sent from the Octave - General mailing list archive at Nabble.com. From febty82 at gmail.com Sun Sep 6 23:25:31 2009 From: febty82 at gmail.com (febty febriani) Date: Mon, 7 Sep 2009 13:25:31 +0900 Subject: how to change scale display in imagesc Message-ID: <1964ddb30909062125o2378fa17r84dcbe971ec94fd7@mail.gmail.com> Dear all, I plotted the attached figure with using imagesc. My question is how to change the scale display so that the y- scale from 0 to 0.5, not from 0.5 to 0 like the attached figure. Any thoughts are appreciated. Thanks very much.. Your sincerely, Febty -- ****** febty febriani Indonesian Institute of Sciences Research Center for Physics Kompleks PUSPIPTEK Serpong, Indonesia, 15314 -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090907/0e3c8385/attachment-0001.html -------------- next part -------------- A non-text attachment was scrubbed... Name: output20090101.png Type: image/png Size: 25746 bytes Desc: not available Url : https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090907/0e3c8385/attachment-0001.png From febty82 at gmail.com Mon Sep 7 00:17:32 2009 From: febty82 at gmail.com (febty febriani) Date: Mon, 7 Sep 2009 14:17:32 +0900 Subject: Fwd: how to change scale display in imagesc In-Reply-To: <1964ddb30909062125o2378fa17r84dcbe971ec94fd7@mail.gmail.com> References: <1964ddb30909062125o2378fa17r84dcbe971ec94fd7@mail.gmail.com> Message-ID: <1964ddb30909062217g2e3744ebwa24693bcc943f740@mail.gmail.com> Dear all, I plotted the attached figure with using imagesc. My question is how to change the scale display so that the y- scale from 0 to 0.5, not from 0.5 to 0 like the attached figure. Any thoughts are appreciated. Thanks very much.. Your sincerely, Febty -- ****** febty febriani Indonesian Institute of Sciences Research Center for Physics Kompleks PUSPIPTEK Serpong, Indonesia, 15314 -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090907/73b28ae8/attachment-0001.html -------------- next part -------------- A non-text attachment was scrubbed... Name: output20090101.png Type: image/png Size: 25746 bytes Desc: not available Url : https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090907/73b28ae8/attachment-0001.png From michael.creel at uab.es Mon Sep 7 04:40:10 2009 From: michael.creel at uab.es (Michael Creel) Date: Mon, 7 Sep 2009 02:40:10 -0700 (PDT) Subject: bfgsmin works for a version but not for the other In-Reply-To: <933ae1930909040429k72bae91eka94f6dac1765c7b9@mail.gmail.com> References: <933ae1930909040429k72bae91eka94f6dac1765c7b9@mail.gmail.com> Message-ID: <25327709.post@talk.nabble.com> M?rcio Diniz wrote: > > Hi there! > I am using Octave 2.9.9 and the bfgsmin works well. However, the same code > does not work when I try to run it in Octave 3.0.1 - the error message is > "warning: bfgsmin: failure, exiting. Try different start values?" even > though I am using the same starting values. > Is there any difference between the bfgsmin versions? If not, what is the > problem? > Thanks in advance > Marcio Diniz > > _______________________________________________ > Help-octave mailing list > Help-octave at octave.org > https://www-old.cae.wisc.edu/mailman/listinfo/help-octave > > Hi, The version of __bfgsmin.cc in Octave Forge had some problem, a fixed version was checked in this morning. You can get it at http://octave.svn.sourceforge.net/viewvc/octave/trunk/octave-forge/main/optim/src/__bfgsmin.cc?revision=6229&view=markup Just copy it over the version you have, and execute "mkoctfile __bfgsmin.cc" M. -- View this message in context: http://www.nabble.com/bfgsmin-works-for-a-version-but-not-for-the-other-tp25294160p25327709.html Sent from the Octave - General mailing list archive at Nabble.com. From ct529 at york.ac.uk Mon Sep 7 07:38:28 2009 From: ct529 at york.ac.uk (Corrado) Date: Mon, 7 Sep 2009 13:38:28 +0100 Subject: Matrix regression of distnce matrices + non negative least square Message-ID: <200909071338.28862.ct529@york.ac.uk> Dear friends, I would like to solve the following regression problem: y=c1 x1 + c2 x2 + .... + cn xn where the y, xi are all matrices and the ci are constants that need to be determined. The y, xi are distance matrices (symmetric). Obviously ci should be forced to positive or null (i.e. non negative). Any suggestion? I will be more than happy to share the results of my quest with the list or developers. -- Corrado Topi Global Climate Change & Biodiversity Indicators Area 18,Department of Biology University of York, York, YO10 5YW, UK Phone: + 44 (0) 1904 328645, E-mail: ct529 at york.ac.uk From highegg at gmail.com Mon Sep 7 08:39:04 2009 From: highegg at gmail.com (Jaroslav Hajek) Date: Mon, 7 Sep 2009 15:39:04 +0200 Subject: Matrix regression of distnce matrices + non negative least square In-Reply-To: <200909071338.28862.ct529@york.ac.uk> References: <200909071338.28862.ct529@york.ac.uk> Message-ID: <69d8d540909070639w19be493eke4b2d615b5400f2a@mail.gmail.com> On Mon, Sep 7, 2009 at 2:38 PM, Corrado wrote: > Dear friends, > > I would like to solve the following regression problem: > > y=c1 x1 + c2 x2 + .... + cn xn > > where the y, xi are all matrices and the ci are constants that need to be > determined. The y, xi are distance matrices (symmetric). Obviously ci should > be forced to positive or null (i.e. non negative). > > Any suggestion? > First convert the linear system into canonical form (matrix of coefficients and vector of rhs), then use lsqnonneg. Since the matrices are symmetric, extracting just lower/upper triangular parts will suffice. The best way how to do the first will depend on the dimensionality of your problem and how your data is stored. regards -- RNDr. Jaroslav Hajek computing expert & GNU Octave developer Aeronautical Research and Test Institute (VZLU) Prague, Czech Republic url: www.highegg.matfyz.cz From ct529 at york.ac.uk Mon Sep 7 09:21:39 2009 From: ct529 at york.ac.uk (Corrado) Date: Mon, 7 Sep 2009 15:21:39 +0100 Subject: Matrix regression of distnce matrices + non negative least square In-Reply-To: <69d8d540909070639w19be493eke4b2d615b5400f2a@mail.gmail.com> References: <200909071338.28862.ct529@york.ac.uk> <69d8d540909070639w19be493eke4b2d615b5400f2a@mail.gmail.com> Message-ID: <200909071521.39612.ct529@york.ac.uk> Dear Jaroslav, thanks for your help. I actually do not understand what you are suggesting: 1) The data would be stored in matrices, which I can easily dump into csv files 2) The distance matrices are up to 5000 x 5000 (but they symmetric, so only n(n-1)/2 are important), but the ones I am using now are just 1500 x 1500. 3) I thought lsqnonneg only worked on linear system in the form y=ax 4) The terms are matrices, how do you write a canonical form???? the x1 .... xn are matrices (e.g. 1500 x 1500) .... the ci are coefficients in R .... Regards On Monday 07 September 2009 14:39:04 you wrote: > On Mon, Sep 7, 2009 at 2:38 PM, Corrado wrote: > > Dear friends, > > > > I would like to solve the following regression problem: > > > > y=c1 x1 + c2 x2 + .... + cn xn > > > > where the y, xi are all matrices and the ci are constants that need to be > > determined. The y, xi are distance matrices (symmetric). Obviously ci > > should be forced to positive or null (i.e. non negative). > > > > Any suggestion? > > First convert the linear system into canonical form (matrix of > coefficients and vector of rhs), then use lsqnonneg. > Since the matrices are symmetric, extracting just lower/upper > triangular parts will suffice. The best way how to do the first will > depend on the dimensionality of your problem and how your data is > stored. > > regards -- Corrado Topi Global Climate Change & Biodiversity Indicators Area 18,Department of Biology University of York, York, YO10 5YW, UK Phone: + 44 (0) 1904 328645, E-mail: ct529 at york.ac.uk From babelproofreader at gmail.com Mon Sep 7 09:27:55 2009 From: babelproofreader at gmail.com (babelproofreader) Date: Mon, 7 Sep 2009 07:27:55 -0700 (PDT) Subject: Moving polynomial fit In-Reply-To: References: <25309400.post@talk.nabble.com> Message-ID: <25331404.post@talk.nabble.com> On Sep 5, 2009, at 11:09 AM, babelproofreader wrote: > I would like to write a script/function for use on a time series > that will > least squares fit a polynomial of a given degree to a moving window > across > the time series in the same way as a moving average computes an > average of a > moving window..... There might be a better way ... Assuming you'd like to center your window about the data point of interest ... ---------------- begin: mwpolysmooth.m --------------- function ym = mwpolysmooth (x, y, order, window) % USAGE: ym = mwpolysmooth (x, y, order, window) xc = num2cell(x); idx = @(xc) find (abs (x - xc) < 0.5*window); n = cellfun (idx, xc, 'uniformoutput', false); mpfit = @(n) polyfit (x(n), y(n), order); pm = cellfun (mpfit, n, 'uniformoutput', false); nc = num2cell (1:numel(x)); mpval = @(n) polyval (pm{n}, x(n)); ym = cell2mat (cellfun (mpval, nc, 'uniformoutput', false)); end ---------------- end: mwpolysmooth.m --------------- Ben, Thanks for your function - I've learned some useful coding from it - but I'm not sure if it really address my problem. I wish to fit real time streaming data (market prices), but as I understand it your code "peaks into the future" to smooth over the window i.e. the fitted value for the most recent streaming data "n" is different from the value that will be calculated when this data value is (n - some_value) in the past, hence invalidating any historical testing over past prices. The simple for loop below is an example of what I want to do, but it is slow. x=(1:length(price))'; polysmooth=price; for i=5:length(price) y=price(i-4:i,1); a=polyfit(x,y,2); polysmooth(i,1)=polyval(a,5); endfor -- View this message in context: http://www.nabble.com/Moving-polynomial-fit-tp25309400p25331404.html Sent from the Octave - General mailing list archive at Nabble.com. From ct529 at york.ac.uk Mon Sep 7 09:37:08 2009 From: ct529 at york.ac.uk (Corrado) Date: Mon, 7 Sep 2009 15:37:08 +0100 Subject: Matrix regression of distance matrices + non negative least square In-Reply-To: <69d8d540909070639w19be493eke4b2d615b5400f2a@mail.gmail.com> References: <200909071338.28862.ct529@york.ac.uk> <69d8d540909070639w19be493eke4b2d615b5400f2a@mail.gmail.com> Message-ID: <200909071537.08610.ct529@york.ac.uk> Dear Jaroslav, by the way, lsqnonneg is not among the packages I can install on my octave. I know there is a lsqnonneg package in Matlab. Regard On Monday 07 September 2009 14:39:04 Jaroslav Hajek wrote: > On Mon, Sep 7, 2009 at 2:38 PM, Corrado wrote: > > Dear friends, > > > > I would like to solve the following regression problem: > > > > y=c1 x1 + c2 x2 + .... + cn xn > > > > where the y, xi are all matrices and the ci are constants that need to be > > determined. The y, xi are distance matrices (symmetric). Obviously ci > > should be forced to positive or null (i.e. non negative). > > > > Any suggestion? > > First convert the linear system into canonical form (matrix of > coefficients and vector of rhs), then use lsqnonneg. > Since the matrices are symmetric, extracting just lower/upper > triangular parts will suffice. The best way how to do the first will > depend on the dimensionality of your problem and how your data is > stored. > > regards -- Corrado Topi Global Climate Change & Biodiversity Indicators Area 18,Department of Biology University of York, York, YO10 5YW, UK Phone: + 44 (0) 1904 328645, E-mail: ct529 at york.ac.uk From macy at sfo.com Mon Sep 7 10:00:40 2009 From: macy at sfo.com (macy at sfo.com) Date: Mon, 7 Sep 2009 08:00:40 -0700 (PDT) Subject: Moving polynomial fit In-Reply-To: <25331404.post@talk.nabble.com> References: <25309400.post@talk.nabble.com> <25331404.post@talk.nabble.com> Message-ID: <1083.66.81.37.191.1252335640.squirrel@cp01.sfo.com> NOW I REMEMBER! I had to rewrite the function polyval into a custom type function so that I could use c variable as an array, not just a vector. Then, just write the whole for-loop as an array sequence. As I said I went from 20 minutes down to 12 seconds for mine. Robert > On Sep 5, 2009, at 11:09 AM, babelproofreader wrote: > >> I would like to write a script/function for use on a time series >> that will >> least squares fit a polynomial of a given degree to a moving window >> across >> the time series in the same way as a moving average computes an >> average of a >> moving window..... > > There might be a better way ... Assuming you'd like to center your > window about the data point of interest ... > > ---------------- begin: mwpolysmooth.m --------------- > function ym = mwpolysmooth (x, y, order, window) > % USAGE: ym = mwpolysmooth (x, y, order, window) > > xc = num2cell(x); > idx = @(xc) find (abs (x - xc) < 0.5*window); > n = cellfun (idx, xc, 'uniformoutput', false); > mpfit = @(n) polyfit (x(n), y(n), order); > pm = cellfun (mpfit, n, 'uniformoutput', false); > nc = num2cell (1:numel(x)); > mpval = @(n) polyval (pm{n}, x(n)); > ym = cell2mat (cellfun (mpval, nc, 'uniformoutput', false)); > > end > ---------------- end: mwpolysmooth.m --------------- > > Ben, > > Thanks for your function - I've learned some useful coding from it - but > I'm > not sure if it really address my problem. I wish to fit real time > streaming > data (market prices), but as I understand it your code "peaks into the > future" to smooth over the window i.e. the fitted value for the most > recent > streaming data "n" is different from the value that will be calculated > when > this data value is (n - some_value) in the past, hence invalidating any > historical testing over past prices. The simple for loop below is an > example > of what I want to do, but it is slow. > > x=(1:length(price))'; > polysmooth=price; > for i=5:length(price) > y=price(i-4:i,1); > a=polyfit(x,y,2); > polysmooth(i,1)=polyval(a,5); > endfor > > From highegg at gmail.com Mon Sep 7 10:04:35 2009 From: highegg at gmail.com (Jaroslav Hajek) Date: Mon, 7 Sep 2009 17:04:35 +0200 Subject: Matrix regression of distnce matrices + non negative least square In-Reply-To: <200909071521.39612.ct529@york.ac.uk> References: <200909071338.28862.ct529@york.ac.uk> <69d8d540909070639w19be493eke4b2d615b5400f2a@mail.gmail.com> <200909071521.39612.ct529@york.ac.uk> Message-ID: <69d8d540909070804i7f1d5821v9c5a4e758dd2338a@mail.gmail.com> On Mon, Sep 7, 2009 at 4:21 PM, Corrado wrote: > Dear Jaroslav, > > thanks for your help. > > I actually do not understand what you are suggesting: > > 1) The data would be stored in matrices, which I can easily dump into csv files OK. But mind you, instead of working with a number of equal-sized matrices it is often more efficient to work with a 3D array. Usually it depends on where you get the matrices from. > 2) The distance matrices are up to 5000 x 5000 (but they symmetric, so only > n(n-1)/2 are important), but the ones I am using now are just 1500 x 1500. In that case, it probably doesn't matter much which representation you choose. > 3) I thought lsqnonneg only worked on linear system in the form y=ax Yes. That's why you need to bring the system into this form. > 4) The terms are matrices, how do you write a canonical form???? the x1 .... > xn are matrices (e.g. 1500 x 1500) .... the ci are coefficients in R .... > A matrix equation constitutes a system of equations; one for each element. If x1...xN are MxM, you get a system of M*(M+1)/2 equations in N variables. Suppose you have the matrices X in a cell array, so that X{1} is the first matrix etc., and the RHS matrix is Y. Then you want to do something like A = [cellfun (@vech, X, "UniformOutput", false){:}]; b = vech (Y); c = lsqnonneg (A, b); To get the coefficients in "c". Note that lsqnonneg is part of Octave 3.2.0+. There is a small problem with the above simplistic code: it does not discard the diagonal equations, because vech includes the diagonal. You can modify vech in order to discard even the diagonal equations. hth -- RNDr. Jaroslav Hajek computing expert & GNU Octave developer Aeronautical Research and Test Institute (VZLU) Prague, Czech Republic url: www.highegg.matfyz.cz From ct529 at york.ac.uk Mon Sep 7 10:13:04 2009 From: ct529 at york.ac.uk (Corrado) Date: Mon, 7 Sep 2009 16:13:04 +0100 Subject: Matrix regression of distnce matrices + non negative least square In-Reply-To: <69d8d540909070804i7f1d5821v9c5a4e758dd2338a@mail.gmail.com> References: <200909071338.28862.ct529@york.ac.uk> <200909071521.39612.ct529@york.ac.uk> <69d8d540909070804i7f1d5821v9c5a4e758dd2338a@mail.gmail.com> Message-ID: <200909071613.04573.ct529@york.ac.uk> Thanks a lot Jaroslav, I am trying to understand how it works .... :) .... it is my first program in octave. On Monday 07 September 2009 16:04:35 Jaroslav Hajek wrote: > On Mon, Sep 7, 2009 at 4:21 PM, Corrado wrote: > > Dear Jaroslav, > > > > thanks for your help. > > > > I actually do not understand what you are suggesting: > > > > 1) The data would be stored in matrices, which I can easily dump into csv > > files > > OK. But mind you, instead of working with a number of equal-sized > matrices it is often more efficient to work with a 3D array. Usually > it depends on where you get the matrices from. > > > 2) The distance matrices are up to 5000 x 5000 (but they symmetric, so > > only n(n-1)/2 are important), but the ones I am using now are just 1500 x > > 1500. > > In that case, it probably doesn't matter much which representation you > choose. > > > 3) I thought lsqnonneg only worked on linear system in the form y=ax > > Yes. That's why you need to bring the system into this form. > > > 4) The terms are matrices, how do you write a canonical form???? the x1 > > .... xn are matrices (e.g. 1500 x 1500) .... the ci are coefficients in R > > .... > > A matrix equation constitutes a system of equations; one for each > element. If x1...xN are MxM, you get a > system of M*(M+1)/2 equations in N variables. > > Suppose you have the matrices X in a cell array, so that X{1} is the > first matrix etc., and the RHS matrix is Y. > Then you want to do something like > A = [cellfun (@vech, X, "UniformOutput", false){:}]; > b = vech (Y); > c = lsqnonneg (A, b); > To get the coefficients in "c". Note that lsqnonneg is part of Octave > 3.2.0+. There is a small problem with the above simplistic code: it does > not discard the diagonal equations, because vech includes the diagonal. You > can modify vech in order to discard even the diagonal equations. > > hth -- Corrado Topi Global Climate Change & Biodiversity Indicators Area 18,Department of Biology University of York, York, YO10 5YW, UK Phone: + 44 (0) 1904 328645, E-mail: ct529 at york.ac.uk From bpabbott at mac.com Mon Sep 7 10:18:06 2009 From: bpabbott at mac.com (Ben Abbott) Date: Mon, 07 Sep 2009 11:18:06 -0400 Subject: Moving polynomial fit In-Reply-To: <25331404.post@talk.nabble.com> References: <25309400.post@talk.nabble.com> <25331404.post@talk.nabble.com> Message-ID: On Sep 7, 2009, at 10:27 AM, babelproofreader wrote: > > > On Sep 5, 2009, at 11:09 AM, babelproofreader wrote: > >> I would like to write a script/function for use on a time series >> that will >> least squares fit a polynomial of a given degree to a moving window >> across >> the time series in the same way as a moving average computes an >> average of a >> moving window..... > > There might be a better way ... Assuming you'd like to center your > window about the data point of interest ... > > ---------------- begin: mwpolysmooth.m --------------- > function ym = mwpolysmooth (x, y, order, window) > % USAGE: ym = mwpolysmooth (x, y, order, window) > > xc = num2cell(x); > idx = @(xc) find (abs (x - xc) < 0.5*window); > n = cellfun (idx, xc, 'uniformoutput', false); > mpfit = @(n) polyfit (x(n), y(n), order); > pm = cellfun (mpfit, n, 'uniformoutput', false); > nc = num2cell (1:numel(x)); > mpval = @(n) polyval (pm{n}, x(n)); > ym = cell2mat (cellfun (mpval, nc, 'uniformoutput', false)); > > end > ---------------- end: mwpolysmooth.m --------------- > > Ben, > > Thanks for your function - I've learned some useful coding from it - > but I'm > not sure if it really address my problem. I wish to fit real time > streaming > data (market prices), but as I understand it your code "peaks into the > future" to smooth over the window i.e. the fitted value for the most > recent > streaming data "n" is different from the value that will be > calculated when > this data value is (n - some_value) in the past, hence invalidating > any > historical testing over past prices. You can modify the window to represent only past values by ... idx = @(xc) find ((xc - x) < window & (xc - x) > 0); Ben From xdong at cse.unl.edu Mon Sep 7 10:33:32 2009 From: xdong at cse.unl.edu (Xin Dong) Date: Mon, 7 Sep 2009 10:33:32 -0500 Subject: Greek letters in plot legend Message-ID: <7a394d4e0909070833w107cfc2dj100d67eb99232e7f@mail.gmail.com> Hi all, I need Greek letters in plot legend. I use the command: legend("\eta=5", "\eta=10", "\eta=15", "\eta=20", "location", "southwest"); However, octave cannot parse "\eta". The interesting thing is if I use "\alpha" or "\theta", it can be successfully displayed. I tried it on Octave 3.0.1 on Unbuntu 9.04 and Octave 3.2.2 on Mac OS X, both have the same problem. Can anyone give some advice? Thanks, Xin -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090907/3fe7558e/attachment.html From bpabbott at mac.com Mon Sep 7 10:55:51 2009 From: bpabbott at mac.com (Ben Abbott) Date: Mon, 07 Sep 2009 11:55:51 -0400 Subject: Greek letters in plot legend In-Reply-To: <7a394d4e0909070833w107cfc2dj100d67eb99232e7f@mail.gmail.com> References: <7a394d4e0909070833w107cfc2dj100d67eb99232e7f@mail.gmail.com> Message-ID: <5895F928-0B9F-40ED-870F-A6368737A679@mac.com> On Sep 7, 2009, at 11:33 AM, Xin Dong wrote: > Hi all, > > I need Greek letters in plot legend. I use the command: > legend("\eta=5", "\eta=10", "\eta=15", "\eta=20", "location", > "southwest"); > > However, octave cannot parse "\eta". The interesting thing is if I > use "\alpha" or "\theta", it can be successfully displayed. I tried > it on Octave 3.0.1 on Unbuntu 9.04 and Octave 3.2.2 on Mac OS X, > both have the same problem. > > Can anyone give some advice? > > Thanks, > Xin See this page .. http://www.gnu.org/software/octave/doc/interpreter/Strings.html The backslash is being interpreted as an escape sequence. What you need to correct it is ... legend("\\eta=5", "\\eta=10", "\\eta=15", "\\eta=20", "location", "southwest"); ... or replace the double-quotes with single-quotes ... legend('\eta=5', '\eta=10', '\eta=15', '\eta=20', "location", "southwest"); Ben From ilnseher at eit.uni-kl.de Mon Sep 7 11:04:53 2009 From: ilnseher at eit.uni-kl.de (Thomas Ilnseher) Date: Mon, 07 Sep 2009 18:04:53 +0200 Subject: [Fwd: Re: Greek letters in plot legend] Message-ID: <1252339493.1971.57.camel@pcmik05.zmk.uni-kl.de> I forget to send to the octave ML. -- Thomas Ilnseher -------------- next part -------------- An embedded message was scrubbed... From: Thomas Ilnseher Subject: Re: Greek letters in plot legend Date: Mon, 07 Sep 2009 18:03:53 +0200 Size: 27525 Url: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090907/6857506a/attachment-0001.mht From carlo.defalco at gmail.com Mon Sep 7 12:25:33 2009 From: carlo.defalco at gmail.com (Carlo de Falco) Date: Mon, 7 Sep 2009 19:25:33 +0200 Subject: [Fwd: Re: Greek letters in plot legend] In-Reply-To: <1252339493.1971.57.camel@pcmik05.zmk.uni-kl.de> References: <1252339493.1971.57.camel@pcmik05.zmk.uni-kl.de> Message-ID: On 7 Sep 2009, at 18:04, Thomas Ilnseher wrote: > depends on what you need to do. > > If you want to see it on the monitor, i can't help you. > > If you need it in files, I have an advise for you: > > octave:1> x=0:0.01:2*pi; > octave:2> y=sin(x); > ^^ I plot something > octave:3> plot(x,y,'.-b;\$sin(\eta)$;'); > ^^ I use latex stuff for the greek letters - > gnuplot complains the following works fine for me with octave 3.2.2, gnuplot 4.2.5 and X11 display on a mac: >> x=0:0.01:2*pi;y=sin(x); >> plot(x,y); >> legend('\sin(\eta)') HTH, c. From Rolf.Schirmacher at MuellerBBM.de Mon Sep 7 14:31:11 2009 From: Rolf.Schirmacher at MuellerBBM.de (Schirmacher, Rolf) Date: Mon, 7 Sep 2009 21:31:11 +0200 Subject: bandpass filter for 2D Data Message-ID: <2417729F3416D511A27E0090273A963B02910FD1@smex01.mbbm.de> > -----Original Message----- > From: John Swensen [mailto:jpswensen at comcast.net] > Sent: Friday, August 28, 2009 5:33 PM > To: Sergei Steshenko > Cc: help-octave at octave.org > Subject: Re: bandpass filter for 2D Data > > > > On Aug 28, 2009, at 11:30 AM, Sergei Steshenko wrote: > > > > > > > --- On Thu, 8/27/09, John Swensen wrote: > > > >> From: John Swensen > >> Subject: Re: bandpass filter for 2D Data > >> To: "Dr. Johannes Zellner" > >> Cc: help-octave at octave.org > >> Date: Thursday, August 27, 2009, 12:58 PM > >> > >> On Aug 27, 2009, at 3:15 AM, Dr. Johannes Zellner wrote: > >> > >>> Hi > >>> > >>> does anyone have an implementation of a 2D bandpass > >> filter? > >>> > >>> Suppose I've 2d data in a matrix of 1000 x 1000 pixels > >> which > >>> represents a spatial extension of 1 m (1 mm per > >> pixel). > >>> Now I'd like to filter away all frequencies below a > >> wavelength of 50 > >>> mm and above a wavelength of 150 mm, > >>> so the resulting data should only have frequencies > >> corresponding to > >>> wavelengths between 50 and 150 mm. > >>> > >>> Any octave examples for this? > >>> > >>> -- > >>> Johannes > >>> _______________________________________________ > >>> Help-octave mailing list > >>> Help-octave at octave.org > >>> https://www-old.cae.wisc.edu/mailman/listinfo/help-octave > >> > >> I don't know if there is an example of how to do this, but > >> I think I > >> remember doing the following pseudocode in my computer > >> visions class: > >> > >> 1) perform the 2D FFT > >> 2) figure out, based on your spatial sampling frequency, > >> how much one > >> "pixel" in the magnitude portion of the 2D FFT is > >> 3) set everything but an annulus whose larger radius > >> equates to 150mm > >> wavelength and inner radius equates to 50mm to zero. > >> 4) Perform the inverse 2D FFT > >> > >> Someone please correct me if this doesn't work, but I think > >> this ends > >> up being a fairly quick way to do what you ask and easy to > >> implement. > >> > >> John Swensen > >> _______________________________________________ > > > > > > Your approach is essentially correct, however, with any inverse FFT > > brickwall filter (the one you propose) causes a lot of > ringing in the > > reconstituted signal. > > > > Regards, > > Sergei. > > > > > > > > Yeah, I thought about that afterward, but hadn't got around to > correcting myself. To solve that problem you use a difference of 2D > Guassians to generate the annulus. I don't quite remember > now how to > set the variance of the Gaussians to get the desired cutoff > frequencies, though. > > Thanks for pointing out my error, > John > > _______________________________________________ > Help-octave mailing list > Help-octave at octave.org > https://www-old.cae.wisc.edu/mailman/listinfo/help-octave > I guess the same way as in 1d filter design... and unfortunately the optimum solution depends on your performance criterion. So, perhaps do a 1d - design and "circle" the frequency response (complex!) around zero (probably) in the complex spectral plane to get the spectral filter matrix. Gaussian might be preferred due to its optimum time-frequency properties (i.e. equally distributed time-frequency uncertainty / fourier-transform is gauss again), but that really depends on the application. Getting a frequency domain brick of course gives about the worst time/spatial domain behaviour. Rolf Schirmacher From christophe.tournery at illusonic.com Mon Sep 7 16:24:29 2009 From: christophe.tournery at illusonic.com (Christophe Tournery) Date: Mon, 7 Sep 2009 23:24:29 +0200 Subject: how to change scale display in imagesc In-Reply-To: <1964ddb30909062125o2378fa17r84dcbe971ec94fd7@mail.gmail.com> References: <1964ddb30909062125o2378fa17r84dcbe971ec94fd7@mail.gmail.com> Message-ID: <94A29D38-8E28-4F2F-B48D-31CC7BE3A71B@illusonic.com> You may want to try: axis xy -c On Sep 7, 2009, at 6:25 AM, febty febriani wrote: > Dear all, > > I plotted the attached figure with using imagesc. My question is how > to change the scale display so that the y- scale from 0 to 0.5, not > from 0.5 to 0 like the attached figure. Any thoughts are > appreciated. Thanks very much.. > > > Your sincerely, > Febty > -- > > ****** > febty febriani > Indonesian Institute of Sciences > Research Center for Physics > Kompleks PUSPIPTEK > Serpong, Indonesia, 15314 > _______________________________________________ > Help-octave mailing list > Help-octave at octave.org > https://www-old.cae.wisc.edu/mailman/listinfo/help-octave From kirzhanov at gmail.com Mon Sep 7 10:39:50 2009 From: kirzhanov at gmail.com (iason) Date: Mon, 7 Sep 2009 08:39:50 -0700 (PDT) Subject: lsode In-Reply-To: <25A0E03F32D04501A0BCD48984753C78@cb289178a> References: <25A0E03F32D04501A0BCD48984753C78@cb289178a> Message-ID: <25332412.post@talk.nabble.com> dmelliott wrote: > > > Dear Help, > > Is it possible to get the actual solution points that lsode uses rather > than just the regularly spaced ones generated by linspace for the input? > > > Thanks, > > > dmelliott > _______________________________________________ > Help-octave mailing list > Help-octave at octave.org > https://www-old.cae.wisc.edu/mailman/listinfo/help-octave > > dmelliott, have you achieved any success in retrieving the solution points (the independent variable nodes) from the LSODE function of OCTAVE? don't you know, is it possible to do this using the original LSODE (or similar) function from the ODEPACK library (where it comes from)? -- View this message in context: http://www.nabble.com/lsode-tp19545666p25332412.html Sent from the Octave - General mailing list archive at Nabble.com. From gbohanno at netscape.net Mon Sep 7 18:52:58 2009 From: gbohanno at netscape.net (George Bohannon) Date: Mon, 07 Sep 2009 19:52:58 -0400 Subject: Trouble building 3.2.2 (pthread) Message-ID: <8CBFE2D75F48880-28C0-1D9C2@webmail-m034.sysops.aol.com> I'm trying to build 3.2.2 on a Red Hat EL4 system. I installed gcc 4.3.4 specifically for this purpose. I ran configure successfully as follows: ./configure F77=gfortran I then ran 'make' and got the following error after building for a while. Does anyone know how to satisfy this undefined reference to 'pthread' items? gcc -c -I/usr/include/pcre -I. -I.. -I../liboctave -I../src -I../libcruft/misc? -DHAVE_CONFIG_H? -Wall -W -Wshadow -W format -g -O2 main.c -o main.o g++ -I/usr/include/pcre -I. -I.. -I../liboctave -I../src -I../libcruft/misc? -DHAVE_CONFIG_H? -Wall -W -Wshadow -Wold -style-cast -Wformat -g -O2 -rdynamic \ -L..? -fPIC? -o octave \ main.o? \ -L../liboctave -L../libcruft -L../src -Wl,-rpath -Wl,/usr/local/lib/octave-3.2.2 \ -loctinterp -loctave? -lcruft?? \ ???? \ ??? \ ??? \ -L/usr/X11R6/lib64 -lX11? -lreadline? -lncurses -ldl -lblas -lz -lm? -L./../lib64 -L/usr/local/lib/gcc/x86_64-unknown -linux-gnu/4.3.4 -L/usr/local/lib/gcc/x86_64-unknown-linux-gnu/4.3.4/../../../../lib64 -L/lib/../lib64 -L/usr/lib/../ lib64 -L. -L/usr/local/lib/gcc/x86_64-unknown-linux-gnu/4.3.4/../../.. -lz -lgfortranbegin -lgfortran -lm ../liboctave/liboctave.so: undefined reference to `pthread_mutexattr_destroy' ../liboctave/liboctave.so: undefined reference to `pthread_mutexattr_settype' ../liboctave/liboctave.so: undefined reference to `pthread_mutexattr_init' collect2: ld returned 1 exit status make[2]: *** [octave] Error 1 make[2]: Leaving directory `/usr/local/octave-3.2.2/src' make[1]: *** [src] Error 2 make[1]: Leaving directory `/usr/local/octave-3.2.2' make: *** [all] Error 2 -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090907/cf7f0a9c/attachment.html From tmacchant at yahoo.co.jp Tue Sep 8 02:39:42 2009 From: tmacchant at yahoo.co.jp (Tatsuro MATSUOKA) Date: Tue, 8 Sep 2009 16:39:42 +0900 (JST) Subject: Can I change maker of stem? Message-ID: <20090908073942.78562.qmail@web3804.mail.bbt.yahoo.co.jp> Hello This inquiry is done in the octave thread in Japan. In the manual The default color is "r" (red). The default line style is "-" and the default marker is "o". The line style can be altered by the linespec argument in the same manner as the plot command. However, there is no description of alternation of the marker. Can I change maker of stem? For example, "x". It will be grateful for me if someone will give me information. Regards Tatsuro -------------------------------------- Thanks 10 years! Yahoo! Shopping and Yahoo! Auctions http://pr.mail.yahoo.co.jp/ec10years/ From schubert.seb at googlemail.com Tue Sep 8 03:37:16 2009 From: schubert.seb at googlemail.com (Sebastian Schubert) Date: Tue, 8 Sep 2009 10:37:16 +0200 Subject: Logarithmic hist and other colour Message-ID: <200909081037.20947.schubert.seb@googlemail.com> Hi, is it possible to plot a histogram logarithmically within octave (3.2.2) with the standard tools? Can I change the colour (no filling of the bars)? Pointers to the manual are fine. :) Cheers Sebastian -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 197 bytes Desc: This is a digitally signed message part. Url : https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090908/6606b91b/attachment.bin From benjamin.barras at epfl.ch Tue Sep 8 09:40:05 2009 From: benjamin.barras at epfl.ch (alynghy) Date: Tue, 8 Sep 2009 07:40:05 -0700 (PDT) Subject: gnuplot not working in RHEL4 32 bit In-Reply-To: References: Message-ID: <25347537.post@talk.nabble.com> The problem is solved on RHEL 5.3 with the same errors : 1) Remove gnuplot from redhat : yum erase gnuplot 2) Remove libraries blas/lapack from redhat : yum erase lapack yum erase blas 3) Remove oldies : yum erase compat-* yum erase compat-lib* 4) Compile the last gnuplot and lapack : cd gnuplot-4.2.5 ./configure make make install cd .. AND cd lapack-3.2.1 cp make.inc.example make.inc make blaslib make all cp blas_LINUX.a /usr/local/lib/libblas.a cp lapack_LINUX.a /usr/local/lib/liblapack.a 5) Compile octave : cd octave-3.2.2 ./configure --with-blas=/usr/local/lib --with-lapack=/usr/local/lib --enable-static LIBS=-lpthread make make install Best regards, Benjamin kelvin-2 wrote: > > I have tried recompiling numerous times but the results have been > consistenly unsatisfying. It should be noted that I am able to > successfully install and plot on a 64 bit machine with RHEL4. Here are > the error messages - does anyone know where to look or what might be > preventing the tool from working with gnuplot? > > using octave-3.2.2 with gnuplot 4.3.0. > > bones:octave-3.2.2 >run-octave > warning: lo_ieee_init: unrecognized floating point format! > > ... > > octave:1> plot(1:10) > error: get: invalid handle (= 1.79769e+308) > error: called from: > error: > /z/users/kmccollough/projects/octave-3.2.2/scripts/plot/__plt_get_axis_arg__.m > at line 57, column 9 > error: /z/users/kmccollough/projects/octave-3.2.2/scripts/plot/plot.m at > line 178, column 18 > octave:1> __gnuplot_version__ > ans = 4.3.0 > octave:2> > > Thanks, > kelvin > > -- View this message in context: http://www.nabble.com/gnuplot-not-working-in-RHEL4-32-bit-tp25224366p25347537.html Sent from the Octave - General mailing list archive at Nabble.com. From gbohanno at netscape.net Mon Sep 7 23:20:37 2009 From: gbohanno at netscape.net (George Bohannon) Date: Tue, 08 Sep 2009 00:20:37 -0400 Subject: Trouble building 3.2.2 (pthread) In-Reply-To: <8CBFE2D75F48880-28C0-1D9C2@webmail-m034.sysops.aol.com> References: <8CBFE2D75F48880-28C0-1D9C2@webmail-m034.sysops.aol.com> Message-ID: <8CBFE52DA07212F-40FC-D624@webmail-d012.sysops.aol.com> > I'm trying to build 3.2.2 on a Red Hat EL4 system. I installed gcc 4.3.4 specifically for this purpose. I ran configure successfully as follows: > ./configure F77=gfortran > I then ran 'make' and got the following error after building for a while. ... I got past the pthread problem by defining the following environment variable and rerunning configure: $ export LDFLAGS=-lpthread However, I then ran make and encountered the following error. Any suggestions? making doc-files DOC_FILES = __contourc__.df __convn__.df __delaunayn__.df __dsearchn__.df __glpk__.df __lin_interpn__.df __magick_read__. df __pchip_deriv__.df __qp__.df __voronoi__.df amd.df balance.df besselj.df betainc.df bitfcns.df bsxfun.df ccolamd.df ce llfun.df chol.df colamd.df colloc.df conv2.df convhulln.df daspk.df dasrt.df dassl.df data.df debug.df defaults.df det.df ?dirfns.df dispatch.df dlmread.df dmperm.df eig.df eigs.df error.df fft.df fft2.df fftn.df fftw.df file-io.df filter.df f ind.df fltk_backend.df gammainc.df gcd.df getgrent.df getpwent.df getrusage.df givens.df graphics.df help.df hess.df hex2 num.df input.df inv.df kron.df lex.df load-path.df load-save.df lookup.df ls-oct-ascii.df lsode.df lu.df luinc.df mappers .df matrix_type.df max.df md5sum.df oct-hist.df octave.df ov-base.df ov-cell.df ov-class.df ov-fcn-handle.df ov-fcn-inlin e.df ov-flt-re-mat.df ov-int16.df ov-int32.df ov-int64.df ov-int8.df ov-list.df ov-null-mat.df ov-re-mat.df ov-struct.df ov-typeinfo.df ov-uint16.df ov-uint32.df ov-uint64.df ov-uint8.df ov-usr-fcn.df ov.df pager.df parse.df pinv.df pr-output .df pt-arg-list.df pt-eval.df pt-mat.df qr.df quad.df qz.df rand.df rcond.df regexp.df schur.df sighandlers.df sparse.df spparms.df sqrtm.df strfns.df svd.df syl.df symbfact.df symrcm.df symtab.df syscalls.df sysdep.df time.df toplev.df tsear ch.df typecast.df urlwrite.df utils.df variables.df mv doc-files-t doc-files making gendoc.cc g++ -g -O2 -o gendoc gendoc.cc -lpthread making DOCSTRINGS ./gendoc: /usr/lib64/libstdc++.so.6: version `GLIBCXX_3.4.9' not found (required by ./gendoc) make[2]: *** [DOCSTRINGS] Error 1 make[2]: Leaving directory `/usr/local/octave-3.2.2/src' make[1]: *** [src] Error 2 make[1]: Leaving directory `/usr/local/octave-3.2.2' make: *** [all] Error 2 -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090908/4edfadf8/attachment-0001.html From dasergatskov at gmail.com Tue Sep 8 10:44:00 2009 From: dasergatskov at gmail.com (Dmitri A. Sergatskov) Date: Tue, 8 Sep 2009 10:44:00 -0500 Subject: gnuplot not working in RHEL4 32 bit In-Reply-To: <25347537.post@talk.nabble.com> References: <25347537.post@talk.nabble.com> Message-ID: <892b16670909080844q5b83868dqe96173fb721dd387@mail.gmail.com> >> warning: lo_ieee_init: unrecognized floating point format! The problem is with lapack (and atlas if it builds against it). You may want to have a look at https://bugzilla.redhat.com/show_bug.cgi?id=520518 and fill a similar bug report for RHEL. Sincerely, Dmitri. -- From jwe at octave.org Tue Sep 8 10:58:10 2009 From: jwe at octave.org (John W. Eaton) Date: Tue, 8 Sep 2009 11:58:10 -0400 Subject: gnuplot not working in RHEL4 32 bit In-Reply-To: <892b16670909080844q5b83868dqe96173fb721dd387@mail.gmail.com> References: <25347537.post@talk.nabble.com> <892b16670909080844q5b83868dqe96173fb721dd387@mail.gmail.com> Message-ID: <19110.32530.318519.357455@segfault.lan> On 8-Sep-2009, Dmitri A. Sergatskov wrote: | >> warning: lo_ieee_init: unrecognized floating point format! FWIW, in future versions of Octave (at least in releases after the 3.2.x series) this will be a fatal error, so users won't be able to easily ignore it. The patch is here: http://hg.savannah.gnu.org/hgweb/octave/rev/264fb5520973 and is fairly simple, so perhaps it should be applied to the 3.2.x series as well. jwe From xdong.cn at gmail.com Tue Sep 8 19:28:28 2009 From: xdong.cn at gmail.com (Xin Dong) Date: Tue, 8 Sep 2009 19:28:28 -0500 Subject: Install packages in Mac OS X Message-ID: Hi, Has anyone successfully installed octave-forge packages with snow leopard and octave 3.2.2? I tried to install image-1.0.10.tar.gz, but failed. Part of the error message: "intNDArray >::increment_index (Array&, dim_vector const&, int)", referenced from: octave_value_list do_filtering >, octave_int, intNDArray >, octave_int >(intNDArray > const&, boolNDArray const&, octave_int (*) (intNDArray >&, int, int), intNDArray > const&, int)in __spatial_filtering__.o ld: symbol(s) not found collect2: ld returned 1 exit status make: *** [__spatial_filtering__.oct] Error 1 Thanks in advance for any help, Xin From tmacchant at yahoo.co.jp Tue Sep 8 20:40:05 2009 From: tmacchant at yahoo.co.jp (Tatsuro MATSUOKA) Date: Wed, 9 Sep 2009 10:40:05 +0900 (JST) Subject: Can I change maker of stem? In-Reply-To: <4AA6969A.9010101@dbateman.org> Message-ID: <20090909014005.22709.qmail@web3804.mail.bbt.yahoo.co.jp> Hello --- David Bateman wrote: > Try > > h = stem(1:10, 'marker', 'x') > set (h, 'marker', 'o') > > in octave 3.2.x ... This uses the stem series objects supported in > Octave 3.2.x and described in the section > > Plotting -> Advanced Plotting -> Object Groups -> Stem Series > > of the manual h=stem(1:10, 'marker', 'x'); gives > h=stem(1:10, 'marker', 'x'); error: subscript indices must be either positive integers or logicals. error: called from: error: C:\Programs\Octave\3.2.2_gcc-4.3.0\share\octave\3.2.2\m\plot\__add_datasource__.m at line 42, column 5 error: C:\Programs\Octave\3.2.2_gcc-4.3.0\share\octave\3.2.2\m\plot\__stem__.m at line 159, column 5 error: C:\Programs\Octave\3.2.2_gcc-4.3.0\share\octave\3.2.2\m\plot\stem.m at line 78, column 7 octave-3.2.2.exe:15:C:\Programs\Octave\3.2.2_gcc-4.3.0\bin Therefore I showed an example to the questioner as, x = 1:10; y = ones (1, length (x))*2.*x; h = stem(x,y); set(h, 'marker','x'); set(h, 'marker','*'); Anyway thanks a lot! Tatsuro -------------------------------------- Thanks 10 years! Yahoo! Shopping and Yahoo! Auctions http://pr.mail.yahoo.co.jp/ec10years/ From febty82 at gmail.com Tue Sep 8 21:14:30 2009 From: febty82 at gmail.com (febty febriani) Date: Wed, 9 Sep 2009 11:14:30 +0900 Subject: how to change scale display in imagesc In-Reply-To: <94A29D38-8E28-4F2F-B48D-31CC7BE3A71B@illusonic.com> References: <1964ddb30909062125o2378fa17r84dcbe971ec94fd7@mail.gmail.com> <94A29D38-8E28-4F2F-B48D-31CC7BE3A71B@illusonic.com> Message-ID: <1964ddb30909081914u5a2bd99eq824fe29caf105eb7@mail.gmail.com> thanks for your response. but it did not work for my case. I used this command to reverse y-axis : set(gca,"ydir","normal"). your sincerely, febty 2009/9/8 Christophe Tournery > You may want to try: > axis xy > -c > > > On Sep 7, 2009, at 6:25 AM, febty febriani wrote: > > Dear all, >> >> I plotted the attached figure with using imagesc. My question is how to >> change the scale display so that the y- scale from 0 to 0.5, not from 0.5 to >> 0 like the attached figure. Any thoughts are appreciated. Thanks very much.. >> >> >> Your sincerely, >> Febty >> -- >> >> ****** >> febty febriani >> Indonesian Institute of Sciences >> Research Center for Physics >> Kompleks PUSPIPTEK >> Serpong, Indonesia, 15314 >> _______________________________________________ >> Help-octave mailing list >> Help-octave at octave.org >> https://www-old.cae.wisc.edu/mailman/listinfo/help-octave >> > > -- ****** febty febriani Indonesian Institute of Sciences Research Center for Physics Kompleks PUSPIPTEK Serpong, Indonesia, 15314 -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090909/677e735a/attachment.html From riccardocorradini at yahoo.it Wed Sep 9 04:27:49 2009 From: riccardocorradini at yahoo.it (Riccardo Corradini) Date: Wed, 9 Sep 2009 09:27:49 +0000 (GMT) Subject: R: Trouble building 3.2.2 (pthread) In-Reply-To: <8CBFE52DA07212F-40FC-D624@webmail-d012.sysops.aol.com> Message-ID: <287860.37973.qm@web25508.mail.ukl.yahoo.com> Hi George, try to install the glib rpm package for redhat See http://www.linuxforums.org/forum/redhat-fedora-linux-help/28627-installing-glib.html Bests Riccardo Corradini --- Mar 8/9/09, George Bohannon ha scritto: Da: George Bohannon Oggetto: Trouble building 3.2.2 (pthread) A: help-octave at octave.org Data: Marted? 8 settembre 2009, 06:20 > I'm trying to build 3.2.2 on a Red Hat EL4 system. I installed gcc 4.3.4 specifically for this purpose. I ran configure successfully as follows: > ./configure F77=gfortran > I then ran 'make' and got the following error after building for a while. ... I got past the pthread problem by defining the following environment variable and rerunning configure: $ export LDFLAGS=-lpthread However, I then ran make and encountered the following error. Any suggestions? making doc-files DOC_FILES = __contourc__.df __convn__.df __delaunayn__.df __dsearchn__.df __glpk__.df __lin_interpn__.df __magick_read__. df __pchip_deriv__.df __qp__.df __voronoi__.df amd.df balance.df besselj.df betainc.df bitfcns.df bsxfun.df ccolamd.df ce llfun.df chol.df colamd.df colloc.df conv2.df convhulln.df daspk.df dasrt.df dassl.df data.df debug.df defaults.df det.df ?dirfns.df dispatch.df dlmread.df dmperm.df eig.df eigs.df error.df fft.df fft2.df fftn.df fftw.df file-io.df filter.df f ind.df fltk_backend.df gammainc.df gcd.df getgrent.df getpwent.df getrusage.df givens.df graphics.df help.df hess.df hex2 num.df input.df inv.df kron.df lex.df load-path.df load-save.df lookup.df ls-oct-ascii.df lsode.df lu.df luinc.df mappers .df matrix_type.df max.df md5sum.df oct-hist.df octave.df ov-base.df ov-cell.df ov-class.df ov-fcn-handle.df ov-fcn-inlin e.df ov-flt-re-mat.df ov-int16.df ov-int32.df ov-int64.df ov-int8.df ov-list.df ov-null-mat.df ov-re-mat.df ov-struct.df ov-typeinfo.df ov-uint16.df ov-uint32.df ov-uint64.df ov-uint8.df ov-usr-fcn.df ov.df pager.df parse.df pinv.df pr-output .df pt-arg-list.df pt-eval.df pt-mat.df qr.df quad.df qz.df rand.df rcond.df regexp.df schur.df sighandlers.df sparse.df spparms.df sqrtm.df strfns.df svd.df syl.df symbfact.df symrcm.df symtab.df syscalls.df sysdep.df time.df toplev.df tsear ch.df typecast.df urlwrite.df utils.df variables.df mv doc-files-t doc-files making gendoc.cc g++ -g -O2 -o gendoc gendoc.cc -lpthread making DOCSTRINGS ./gendoc: /usr/lib64/libstdc++.so.6: version `GLIBCXX_3.4.9' not found (required by ./gendoc) make[2]: *** [DOCSTRINGS] Error 1 make[2]: Leaving directory `/usr/local/octave-3.2.2/src' make[1]: *** [src] Error 2 make[1]: Leaving directory `/usr/local/octave-3.2.2' make: *** [all] Error 2 -----Segue allegato----- _______________________________________________ Help-octave mailing list Help-octave at octave.org https://www-old.cae.wisc.edu/mailman/listinfo/help-octave -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090909/e97fe38f/attachment.html From dbateman at dbateman.org Tue Sep 8 12:38:34 2009 From: dbateman at dbateman.org (David Bateman) Date: Tue, 08 Sep 2009 19:38:34 +0200 Subject: Can I change maker of stem? In-Reply-To: <20090908073942.78562.qmail@web3804.mail.bbt.yahoo.co.jp> References: <20090908073942.78562.qmail@web3804.mail.bbt.yahoo.co.jp> Message-ID: <4AA6969A.9010101@dbateman.org> Tatsuro MATSUOKA wrote: > Hello > > This inquiry is done in the octave thread in Japan. > > In the manual > > The default color is "r" (red). The default line style is "-" and the default marker is > "o". The line style can be altered by the linespec argument in the same manner as > the plot command. > > However, there is no description of alternation of the marker. > Can I change maker of stem? For example, "x". > > It will be grateful for me if someone will give me information. > > Regards > > Tatsuro > > -------------------------------------- > Thanks 10 years! Yahoo! Shopping and Yahoo! Auctions > http://pr.mail.yahoo.co.jp/ec10years/ > _______________________________________________ > Help-octave mailing list > Help-octave at octave.org > https://www-old.cae.wisc.edu/mailman/listinfo/help-octave > > Try h = stem(1:10, 'marker', 'x') set (h, 'marker', 'o') in octave 3.2.x ... This uses the stem series objects supported in Octave 3.2.x and described in the section Plotting -> Advanced Plotting -> Object Groups -> Stem Series of the manual D. -- David Bateman dbateman at dbateman.org 35 rue Gambetta +33 1 46 04 02 18 (Home) 92100 Boulogne-Billancourt FRANCE +33 6 72 01 06 33 (Mob) From gkousiou at telecom.ntua.gr Wed Sep 9 04:49:30 2009 From: gkousiou at telecom.ntua.gr (George Kousiouris) Date: Wed, 9 Sep 2009 12:49:30 +0300 (EEST) Subject: Command for automatic deployment of dependent packages Message-ID: <1799.147.102.19.192.1252489770.squirrel@my.telecom.ntua.gr> Hi all, I have a question regarding octave installation (basically package installation). Is there a command that adds a package to an octave installation and automatically detects the dependencies of this package from other packages and installs them too? Thanks in advance and best regards, George From matthias.brennwald at eawag.ch Wed Sep 9 03:44:09 2009 From: matthias.brennwald at eawag.ch (Matthias Brennwald) Date: Wed, 9 Sep 2009 10:44:09 +0200 Subject: Exponential notation in tick labels? Message-ID: <9156614F-3C2D-4222-93F8-D9C39C71A697@eawag.ch> Dear all I'm sure this has been discussed before, but I couldn't find anything (maybe I did not chose the right search terms). I'd like to use exponential notation for tick-mark labels in plots. For instance "plot ([0:1e4:1E6])" yields a plot with y-axis labels 0, 200000, 400000, 600000, 700000, 1e+6. I'd like these to be 0, 2e5, 4e5, 6e5, 8e5, 1e6. Or, even better, 0, 2x10^5, 4x10^5,..., 10^6. How can I achieve this? Matthias ---- Matthias Brennwald Eawag, CH-8600 D?bendorf Office Eawag BU-C08: +41 44 823 53 05 Lab Eawag LA-C76: +41 44 823 53 06 Lab ETHZ CLA A31.6: +41 632 09 36/39 matthias.brennwald at eawag.ch From matthias at brennwald.org Wed Sep 9 06:18:22 2009 From: matthias at brennwald.org (Matthias Brennwald) Date: Wed, 9 Sep 2009 13:18:22 +0200 Subject: Exponential notation in tick labels? Message-ID: Dear all I'm sure this has been discussed before, but I couldn't find anything (maybe I did not chose the right search terms). I'd like to use exponential notation for tick-mark labels in plots. For instance "plot ([0:1e4:1E6])" yields a plot with y-axis labels 0, 200000, 400000, 600000, 700000, 1e+6. I'd like these to be 0, 2e5, 4e5, 6e5, 8e5, 1e6. Or, even better, 0, 2x10^5, 4x10^5,..., 10^6. How can I achieve this? Matthias ---- Matthias Brennwald Eawag, CH-8600 D?bendorf Office Eawag BU-C08: +41 44 823 53 05 Lab Eawag LA-C76: +41 44 823 53 06 Lab ETHZ CLA A31.6: +41 632 09 36/39 matthias.brennwald at eawag.ch From carlo.defalco at gmail.com Wed Sep 9 07:10:26 2009 From: carlo.defalco at gmail.com (Carlo de Falco) Date: Wed, 9 Sep 2009 14:10:26 +0200 Subject: Exponential notation in tick labels? In-Reply-To: References: Message-ID: <420ba0760909090510m4b95a6cby468a93f126522b79@mail.gmail.com> 2009/9/9 Matthias Brennwald : > Dear all > > I'm sure this has been discussed before, but I couldn't find anything > (maybe I did not chose the right search terms). I'd like to use > exponential notation for tick-mark labels in plots. For instance "plot > ([0:1e4:1E6])" yields a plot with y-axis labels 0, 200000, 400000, > 600000, 700000, 1e+6. I'd like these to be 0, 2e5, 4e5, 6e5, 8e5, 1e6. > Or, even better, 0, 2x10^5, 4x10^5,..., 10^6. How can I achieve this? octave-3.2.2:40> plot ([0:1e2:1e6]) octave-3.2.2:41> xt = get(gca, 'xtick'); octave-3.2.2:42> yt = get(gca, 'ytick'); octave-3.2.2:43> set(gca, 'xticklabel', sprintf('%1.1e|', xt)); octave-3.2.2:44> set(gca, 'yticklabel', sprintf('%1.1e|', yt)); HTH, c. > Matthias > > ---- > Matthias Brennwald > Eawag, CH-8600 D?bendorf > Office Eawag BU-C08: +41 44 823 53 05 > Lab Eawag LA-C76: +41 44 823 53 06 > Lab ETHZ CLA A31.6: +41 632 09 36/39 > matthias.brennwald at eawag.ch > > > _______________________________________________ > Help-octave mailing list > Help-octave at octave.org > https://www-old.cae.wisc.edu/mailman/listinfo/help-octave > From highegg at gmail.com Wed Sep 9 07:15:55 2009 From: highegg at gmail.com (Jaroslav Hajek) Date: Wed, 9 Sep 2009 14:15:55 +0200 Subject: gnuplot not working in RHEL4 32 bit In-Reply-To: <19110.32530.318519.357455@segfault.lan> References: <25347537.post@talk.nabble.com> <892b16670909080844q5b83868dqe96173fb721dd387@mail.gmail.com> <19110.32530.318519.357455@segfault.lan> Message-ID: <69d8d540909090515i6cbfc5f2h8d947aa79083d5ce@mail.gmail.com> On Tue, Sep 8, 2009 at 5:58 PM, John W. Eaton wrote: > On ?8-Sep-2009, Dmitri A. Sergatskov wrote: > > | >> warning: lo_ieee_init: unrecognized floating point format! > > FWIW, in future versions of Octave (at least in releases after the > 3.2.x series) this will be a fatal error, so users won't be able to > easily ignore it. > > The patch is here: > > ?http://hg.savannah.gnu.org/hgweb/octave/rev/264fb5520973 > > and is fairly simple, so perhaps it should be applied to the 3.2.x > series as well. > applied. -- RNDr. Jaroslav Hajek computing expert & GNU Octave developer Aeronautical Research and Test Institute (VZLU) Prague, Czech Republic url: www.highegg.matfyz.cz From matthias at brennwald.org Wed Sep 9 07:35:29 2009 From: matthias at brennwald.org (Matthias Brennwald) Date: Wed, 9 Sep 2009 14:35:29 +0200 Subject: Exponential notation in tick labels? In-Reply-To: <420ba0760909090510m4b95a6cby468a93f126522b79@mail.gmail.com> References: <420ba0760909090510m4b95a6cby468a93f126522b79@mail.gmail.com> Message-ID: <40BD3A73-4D21-4152-80F3-28D7D4FE418C@brennwald.org> On Sep 9, 2009, at 2:10 PM, Carlo de Falco wrote: > 2009/9/9 Matthias Brennwald : >> Dear all >> >> I'm sure this has been discussed before, but I couldn't find anything >> (maybe I did not chose the right search terms). I'd like to use >> exponential notation for tick-mark labels in plots. For instance >> "plot >> ([0:1e4:1E6])" yields a plot with y-axis labels 0, 200000, 400000, >> 600000, 700000, 1e+6. I'd like these to be 0, 2e5, 4e5, 6e5, 8e5, >> 1e6. >> Or, even better, 0, 2x10^5, 4x10^5,..., 10^6. How can I achieve this? > > > octave-3.2.2:40> plot ([0:1e2:1e6]) > octave-3.2.2:41> xt = get(gca, 'xtick'); > octave-3.2.2:42> yt = get(gca, 'ytick'); > octave-3.2.2:43> set(gca, 'xticklabel', sprintf('%1.1e|', xt)); > octave-3.2.2:44> set(gca, 'yticklabel', sprintf('%1.1e|', yt)); > > > HTH, > c. Thanks, this does the trick! Now I could even try to adapt this to the "10^n" notation... I don't know a direct way to use sprintf(...) to print numbers in the 10^n format, but I guess it is feasible by manipulating the ticklabels using string functions somehow. Thanks again Matthias From dbateman at dbateman.org Wed Sep 9 07:48:02 2009 From: dbateman at dbateman.org (David Bateman) Date: Wed, 09 Sep 2009 14:48:02 +0200 Subject: Can I change maker of stem? In-Reply-To: <20090909014005.22709.qmail@web3804.mail.bbt.yahoo.co.jp> References: <20090909014005.22709.qmail@web3804.mail.bbt.yahoo.co.jp> Message-ID: <4AA7A402.7040605@dbateman.org> Tatsuro MATSUOKA wrote: > Hello > > --- David Bateman wrote: > > >> Try >> >> h = stem(1:10, 'marker', 'x') >> set (h, 'marker', 'o') >> >> in octave 3.2.x ... This uses the stem series objects supported in >> Octave 3.2.x and described in the section >> >> Plotting -> Advanced Plotting -> Object Groups -> Stem Series >> >> of the manual >> > > h=stem(1:10, 'marker', 'x'); gives > >> h=stem(1:10, 'marker', 'x'); >> > error: subscript indices must be either positive integers or logicals. > error: called from: > error: C:\Programs\Octave\3.2.2_gcc-4.3.0\share\octave\3.2.2\m\plot\__add_datasource__.m at line 42, > column 5 > error: C:\Programs\Octave\3.2.2_gcc-4.3.0\share\octave\3.2.2\m\plot\__stem__.m at line 159, column 5 > error: C:\Programs\Octave\3.2.2_gcc-4.3.0\share\octave\3.2.2\m\plot\stem.m at line 78, column 7 > octave-3.2.2.exe:15:C:\Programs\Octave\3.2.2_gcc-4.3.0\bin > > Oppps, check the bugfix http://hg.tw-math.de/release-3-2-x/rev/d208ae6e9d74 so the first syntax will be fixed in 3.2.3 D. -- David Bateman dbateman at dbateman.org 35 rue Gambetta +33 1 46 04 02 18 (Home) 92100 Boulogne-Billancourt FRANCE +33 6 72 01 06 33 (Mob) From carlo.defalco at gmail.com Wed Sep 9 07:59:04 2009 From: carlo.defalco at gmail.com (Carlo de Falco) Date: Wed, 9 Sep 2009 14:59:04 +0200 Subject: Exponential notation in tick labels? In-Reply-To: <40BD3A73-4D21-4152-80F3-28D7D4FE418C@brennwald.org> References: <420ba0760909090510m4b95a6cby468a93f126522b79@mail.gmail.com> <40BD3A73-4D21-4152-80F3-28D7D4FE418C@brennwald.org> Message-ID: <420ba0760909090559k49dcbe80l64db6aa58cc1628c@mail.gmail.com> 2009/9/9 Matthias Brennwald : > Thanks, this does the trick! Now I could even try to adapt this to the > "10^n" notation... I don't know a direct way to use sprintf(...) to > print numbers in ?the 10^n format, but I guess it is feasible by > manipulating the ticklabels using string functions somehow. octave-3.2.2:76> x= [1e5:1e5:1e6]; octave-3.2.2:77> plot(x,x); octave-3.2.2:78> axis tight octave-3.2.2:79> xt = get(gca, 'xtick'); octave-3.2.2:80> x_ex = floor(log10(xt)); octave-3.2.2:81> x_mant = xt./10.^x_ex; octave-3.2.2:82> set(gca, 'xticklabel', sprintf('%1.1fx10^{%d}|', x_mant, x_ex)); Note that if one of the ticks were labeled "0" it would need to be handled separately (that's the reason for "axis tight") > Thanks again > Matthias c. From bpabbott at mac.com Wed Sep 9 08:05:20 2009 From: bpabbott at mac.com (Ben Abbott) Date: Wed, 09 Sep 2009 09:05:20 -0400 Subject: Exponential notation in tick labels? In-Reply-To: <40BD3A73-4D21-4152-80F3-28D7D4FE418C@brennwald.org> References: <420ba0760909090510m4b95a6cby468a93f126522b79@mail.gmail.com> <40BD3A73-4D21-4152-80F3-28D7D4FE418C@brennwald.org> Message-ID: <110624671733611579087806112242133143711-Webmail@me.com> On Wednesday, September 09, 2009, at 08:35AM, "Matthias Brennwald" wrote: > >On Sep 9, 2009, at 2:10 PM, Carlo de Falco wrote: > >> 2009/9/9 Matthias Brennwald : >>> Dear all >>> >>> I'm sure this has been discussed before, but I couldn't find anything >>> (maybe I did not chose the right search terms). I'd like to use >>> exponential notation for tick-mark labels in plots. For instance >>> "plot >>> ([0:1e4:1E6])" yields a plot with y-axis labels 0, 200000, 400000, >>> 600000, 700000, 1e+6. I'd like these to be 0, 2e5, 4e5, 6e5, 8e5, >>> 1e6. >>> Or, even better, 0, 2x10^5, 4x10^5,..., 10^6. How can I achieve this? >> >> >> octave-3.2.2:40> plot ([0:1e2:1e6]) >> octave-3.2.2:41> xt = get(gca, 'xtick'); >> octave-3.2.2:42> yt = get(gca, 'ytick'); >> octave-3.2.2:43> set(gca, 'xticklabel', sprintf('%1.1e|', xt)); >> octave-3.2.2:44> set(gca, 'yticklabel', sprintf('%1.1e|', yt)); >> >> >> HTH, >> c. > >Thanks, this does the trick! Now I could even try to adapt this to the >"10^n" notation... I don't know a direct way to use sprintf(...) to >print numbers in the 10^n format, but I guess it is feasible by >manipulating the ticklabels using string functions somehow. > >Thanks again >Matthias If you're looking to fix a single figure ... yt = '0|2\cdot{10^5}|4\cdot{10^5}|6\cdot{10^5}|8\cdot{10^5}|10^6'; set (gca, "yticklabel", yt) Ben From carlo.defalco at gmail.com Wed Sep 9 08:07:00 2009 From: carlo.defalco at gmail.com (Carlo de Falco) Date: Wed, 9 Sep 2009 15:07:00 +0200 Subject: Command for automatic deployment of dependent packages In-Reply-To: <1799.147.102.19.192.1252489770.squirrel@my.telecom.ntua.gr> References: <1799.147.102.19.192.1252489770.squirrel@my.telecom.ntua.gr> Message-ID: <420ba0760909090607y41d19b0bi6d25cd2555ad9099@mail.gmail.com> 2009/9/9 George Kousiouris : > > Hi all, > > I have a question regarding octave installation (basically package > installation). Is there a command that adds a package to an octave > installation and automatically detects the dependencies of this package > from other packages and installs them too? This is not currently possible as it would require the package manager to download the packages from the repository automatically. On the other hand, in some linux distributions (at least fedora and debian, AFAIK) octave packages are distributed via the system's package manager which does usually support this feature so doing apt-get install on debian or yum install on fedora should do exactly what you ask > Thanks in advance and best regards, > George > c. From carlo.defalco at gmail.com Wed Sep 9 08:38:16 2009 From: carlo.defalco at gmail.com (Carlo de Falco) Date: Wed, 9 Sep 2009 15:38:16 +0200 Subject: Exponential notation in tick labels? In-Reply-To: <420ba0760909090559k49dcbe80l64db6aa58cc1628c@mail.gmail.com> References: <420ba0760909090510m4b95a6cby468a93f126522b79@mail.gmail.com> <40BD3A73-4D21-4152-80F3-28D7D4FE418C@brennwald.org> <420ba0760909090559k49dcbe80l64db6aa58cc1628c@mail.gmail.com> Message-ID: <420ba0760909090638k49d59660td8ea6d4c38cb4214@mail.gmail.com> 2009/9/9 Carlo de Falco : > 2009/9/9 Matthias Brennwald : >> Thanks, this does the trick! Now I could even try to adapt this to the >> "10^n" notation... I don't know a direct way to use sprintf(...) to >> print numbers in ?the 10^n format, but I guess it is feasible by >> manipulating the ticklabels using string functions somehow. > > > octave-3.2.2:76> x= [1e5:1e5:1e6]; > octave-3.2.2:77> plot(x,x); > octave-3.2.2:78> axis tight > octave-3.2.2:79> xt = get(gca, 'xtick'); > octave-3.2.2:80> x_ex = floor(log10(xt)); > octave-3.2.2:81> x_mant = xt./10.^x_ex; > octave-3.2.2:82> set(gca, 'xticklabel', sprintf('%1.1fx10^{%d}|', > x_mant, x_ex)); > > > Note that if one of the ticks were labeled "0" it would need to be > handled separately > (that's the reason for "axis tight") sorry, I made mistake in the call to sprintf above.. the approach below should work correctly and also andle the zeros automatically... function [ex, mant] = exp_notation (x) nz = find(x); ex(nz) = floor(log10(abs(x(nz)))); mant(nz) = x(nz)./10.^ex(nz); endfunction octave-3.2.2:108> x= [-1e6:1e5:1e6]; octave-3.2.2:109> plot(x,x); octave-3.2.2:110> xt = get(gca, 'xtick');[xex,xmant] = exp_notation (xt); octave-3.2.2:111> yt = get(gca, 'ytick');[yex,ymant] = exp_notation (yt); octave-3.2.2:112> set(gca, 'xticklabel', sprintf('%3.3gx10^{%d}|', [xmant; xex](:))); octave-3.2.2:113> set(gca, 'yticklabel', sprintf('%3.3gx10^{%d}|', [ymant; yex](:))); >> Thanks again >> Matthias > c. > From riccardocorradini at yahoo.it Wed Sep 9 08:45:35 2009 From: riccardocorradini at yahoo.it (Riccardo Corradini) Date: Wed, 9 Sep 2009 13:45:35 +0000 (GMT) Subject: octave + mpi classes into c++ code Message-ID: <741710.47231.qm@web25502.mail.ukl.yahoo.com> Hi I successfully installed http://www.osl.iu.edu/research/oompi/software.php these C++ classes with open mpi 1.2.8. Are there any hints on how is possible to use them efficiently into or with or extending octave c++ classes . This would be nice because? if on one hand the octave's API change and improve rapidly overt time, on the other hand it would easy to use the same mpi C++ classes. I would like to have an example. Thanks a lot for all your help. Respectfully Riccardo Corradini -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090909/2399de2f/attachment.html From matthias at brennwald.org Wed Sep 9 09:07:00 2009 From: matthias at brennwald.org (Matthias Brennwald) Date: Wed, 9 Sep 2009 16:07:00 +0200 Subject: Exponential notation in tick labels? In-Reply-To: <420ba0760909090638k49d59660td8ea6d4c38cb4214@mail.gmail.com> References: <420ba0760909090510m4b95a6cby468a93f126522b79@mail.gmail.com> <40BD3A73-4D21-4152-80F3-28D7D4FE418C@brennwald.org> <420ba0760909090559k49dcbe80l64db6aa58cc1628c@mail.gmail.com> <420ba0760909090638k49d59660td8ea6d4c38cb4214@mail.gmail.com> Message-ID: <722D198C-D88A-446E-8815-B8F44434ED97@brennwald.org> On Sep 9, 2009, at 3:38 PM, Carlo de Falco wrote: > 2009/9/9 Carlo de Falco : >> 2009/9/9 Matthias Brennwald : >>> Thanks, this does the trick! Now I could even try to adapt this to >>> the >>> "10^n" notation... I don't know a direct way to use sprintf(...) to >>> print numbers in the 10^n format, but I guess it is feasible by >>> manipulating the ticklabels using string functions somehow. >> >> >> octave-3.2.2:76> x= [1e5:1e5:1e6]; >> octave-3.2.2:77> plot(x,x); >> octave-3.2.2:78> axis tight >> octave-3.2.2:79> xt = get(gca, 'xtick'); >> octave-3.2.2:80> x_ex = floor(log10(xt)); >> octave-3.2.2:81> x_mant = xt./10.^x_ex; >> octave-3.2.2:82> set(gca, 'xticklabel', sprintf('%1.1fx10^{%d}|', >> x_mant, x_ex)); >> >> >> Note that if one of the ticks were labeled "0" it would need to be >> handled separately >> (that's the reason for "axis tight") > > sorry, I made mistake in the call to sprintf above.. > the approach below should work correctly and also andle the > zeros automatically... > > function [ex, mant] = exp_notation (x) > nz = find(x); > ex(nz) = floor(log10(abs(x(nz)))); > mant(nz) = x(nz)./10.^ex(nz); > endfunction > > octave-3.2.2:108> x= [-1e6:1e5:1e6]; > octave-3.2.2:109> plot(x,x); > octave-3.2.2:110> xt = get(gca, 'xtick');[xex,xmant] = exp_notation > (xt); > octave-3.2.2:111> yt = get(gca, 'ytick');[yex,ymant] = exp_notation > (yt); > octave-3.2.2:112> set(gca, 'xticklabel', sprintf('%3.3gx10^{%d}|', > [xmant; xex](:))); > octave-3.2.2:113> set(gca, 'yticklabel', sprintf('%3.3gx10^{%d}|', > [ymant; yex](:))); Even better, thanks a bunch! Matthias From vic at norton.name Wed Sep 9 09:23:55 2009 From: vic at norton.name (Vic Norton) Date: Wed, 9 Sep 2009 10:23:55 -0400 Subject: Install packages in Mac OS X In-Reply-To: References: Message-ID: <97579901-A788-4093-AD33-4FBDE5C1D709@norton.name> I don't have Snow Leopard yet, but you might try this. It works for me. 1) Download "Octave.app for Mac OS X" from . 2) Drop the Octave application into your Applications folder. 3) To be able to use the shebang line #!/usr/local/bin/octave in your scripts, do $ sudo ln -s \ /Applications/Octave.app/Contents/Resources/bin/octave \ /usr/local/bin in Terminal. Regards, Vic On Sep 8, 2009, at 8:28 PM, Xin Dong wrote: > Hi, > > Has anyone successfully installed octave-forge packages with snow > leopard and octave 3.2.2? I tried to install image-1.0.10.tar.gz, but > failed. From choonway at gmail.com Wed Sep 9 11:08:22 2009 From: choonway at gmail.com (Liao Choon Way) Date: Wed, 9 Sep 2009 09:08:22 -0700 (PDT) Subject: unofficial octave 3.2.2 msvc2008 solution/project files Message-ID: <25368142.post@talk.nabble.com> hi all, i have prepared a _rough_ set of files for those interested in embedding octave into windows applications and have problems with mingw dlls. Get them http://sourceforge.net/projects/el-rekka/files/octave-3.2.2-msvc9-20090909.tar.gz/download here . instructions enclosed. read before use. check the repository for updates. choonway -- View this message in context: http://www.nabble.com/unofficial-octave-3.2.2-msvc2008-solution-project-files-tp25368142p25368142.html Sent from the Octave - General mailing list archive at Nabble.com. From bpabbott at mac.com Wed Sep 9 06:57:55 2009 From: bpabbott at mac.com (Ben Abbott) Date: Wed, 09 Sep 2009 07:57:55 -0400 Subject: Exponential notation in tick labels? In-Reply-To: References: Message-ID: <376D4B5A-9634-406D-867D-75FFBCAF61F4@mac.com> On Sep 9, 2009, at 7:18 AM, Matthias Brennwald wrote: > Dear all > > I'm sure this has been discussed before, but I couldn't find anything > (maybe I did not chose the right search terms). I'd like to use > exponential notation for tick-mark labels in plots. For instance "plot > ([0:1e4:1E6])" yields a plot with y-axis labels 0, 200000, 400000, > 600000, 700000, 1e+6. I'd like these to be 0, 2e5, 4e5, 6e5, 8e5, 1e6. > Or, even better, 0, 2x10^5, 4x10^5,..., 10^6. How can I achieve this? > > Matthias You can over-ride the automatic formatting by ... set (gca, "yticklabel", num2str (get (gca, "ytick"), '%.1e|')) Ben From Thomas.Treichl at gmx.net Wed Sep 9 13:15:50 2009 From: Thomas.Treichl at gmx.net (Thomas Treichl) Date: Wed, 09 Sep 2009 20:15:50 +0200 Subject: Install packages in Mac OS X In-Reply-To: <97579901-A788-4093-AD33-4FBDE5C1D709@norton.name> References: <97579901-A788-4093-AD33-4FBDE5C1D709@norton.name> Message-ID: <4AA7F0D6.9060206@gmx.net> Vic Norton schrieb: > I don't have Snow Leopard yet, but you might try this. It works for me. > 1) Download "Octave.app for Mac OS X" from > . > 2) Drop the Octave application into your Applications folder. > 3) To be able to use the shebang line > #!/usr/local/bin/octave > in your scripts, do > $ sudo ln -s \ > /Applications/Octave.app/Contents/Resources/bin/octave \ > /usr/local/bin > in Terminal. > > Regards, > > Vic > > On Sep 8, 2009, at 8:28 PM, Xin Dong wrote: >> Hi, >> >> Has anyone successfully installed octave-forge packages with snow >> leopard and octave 3.2.2? I tried to install image-1.0.10.tar.gz, but >> failed. Hi Vic, hi Xin, I think the problem is a bit more complex. Apple has changed some more things from Leopard to Snow Leopard and with Snow Leopard everything that has to do with Octave's mkoctfile is broken now (ie. installing packages, the 'mkoctfile' command itself, the command 'mex', and so on) - in detail: Snow Leopard's linker does not accept my 10.4 build libraries anymore and that's why linking against my binaries completely fails. I've already commented on a similar problem here http://www-old.cae.wisc.edu/pipermail/bug-octave/2009-September/009375.html Just because of my own interest - what is the current GCC version from Snow Leopard's XCode tools? Is there at least a gfortran available? Best regards Thomas From gbohanno at netscape.net Wed Sep 9 13:26:56 2009 From: gbohanno at netscape.net (George Bohannon) Date: Wed, 09 Sep 2009 14:26:56 -0400 Subject: Trouble building 3.2.2 (pthread) Message-ID: <8CBFF923E5A74CF-4584-20E4@webmail-m006.sysops.aol.com> Here is a little more information: There are two versions of gcc installed on this RHEL4 system. Octave 3.2.2 will not build with the gcc version already installed (3.4.6), so I installed gcc 4.3.4.? The rather long output from 'make' prior to the gendoc error indicates that 'make' is using the gcc 4.3.4 library for everything up to the point at which it stops on gendoc. Nevertheless, here is information about the two installations: [root at fluffy ~]# strings /usr/lib/libstdc++.so.6 | grep GLIBCXX GLIBCXX_3.4 GLIBCXX_3.4.1 GLIBCXX_3.4.2 GLIBCXX_3.4.3 GLIBCXX_FORCE_NEW [root at fluffy ~]# strings /usr/local/lib/libstdc++.so.6 | grep GLIBCXX GLIBCXX_3.4 GLIBCXX_3.4.1 GLIBCXX_3.4.2 GLIBCXX_3.4.3 GLIBCXX_3.4.4 GLIBCXX_3.4.5 GLIBCXX_3.4.6 GLIBCXX_3.4.7 GLIBCXX_3.4.8 GLIBCXX_3.4.9 GLIBCXX_3.4.10 GLIBCXX_FORCE_NEW GLIBCXX_DEBUG_MESSAGE_LENGTH So it appears that the gcc in /usr/local/lib (which is gcc 4.3.4) has the required library. However, I have tried setting the following environment and then running configure & make without success: export F77=gfortran export LIBS=-lpthread export LDFLAGS=-L/usr/local/lib This still results in the message ./gendoc: /usr/lib64/libstdc++.so.6: version `GLIBCXX_3.4.9' not found (required by ./gendoc) I have run out of things to try. Any suggestions? ? -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090909/df42bde0/attachment.html From bpabbott at mac.com Wed Sep 9 14:02:40 2009 From: bpabbott at mac.com (Ben Abbott) Date: Wed, 09 Sep 2009 15:02:40 -0400 Subject: Install packages in Mac OS X Message-ID: <23337479393450908730213684685666271541-Webmail@me.com> On Wednesday, September 09, 2009, at 02:15PM, "Thomas Treichl" wrote: >Vic Norton schrieb: >> I don't have Snow Leopard yet, but you might try this. It works for me. >> 1) Download "Octave.app for Mac OS X" from >> . >> 2) Drop the Octave application into your Applications folder. >> 3) To be able to use the shebang line >> #!/usr/local/bin/octave >> in your scripts, do >> $ sudo ln -s \ >> /Applications/Octave.app/Contents/Resources/bin/octave \ >> /usr/local/bin >> in Terminal. >> >> Regards, >> >> Vic >> >> On Sep 8, 2009, at 8:28 PM, Xin Dong wrote: >>> Hi, >>> >>> Has anyone successfully installed octave-forge packages with snow >>> leopard and octave 3.2.2? I tried to install image-1.0.10.tar.gz, but >>> failed. > >Hi Vic, hi Xin, > >I think the problem is a bit more complex. Apple has changed some more things >from Leopard to Snow Leopard and with Snow Leopard everything that has to do >with Octave's mkoctfile is broken now (ie. installing packages, the 'mkoctfile' >command itself, the command 'mex', and so on) - in detail: Snow Leopard's linker >does not accept my 10.4 build libraries anymore and that's why linking against >my binaries completely fails. I've already commented on a similar problem here > > http://www-old.cae.wisc.edu/pipermail/bug-octave/2009-September/009375.html > >Just because of my own interest - what is the current GCC version from Snow >Leopard's XCode tools? Is there at least a gfortran available? > >Best regards > > Thomas Hi Thomas, I've been running Snow Leopard since the morning it was released. $ gcc --version i686-apple-darwin10-gcc-4.2.1 (GCC) 4.2.1 (Apple Inc. build 5646) I don't think gfortran is included (it's not in /usr/bin). The biggest annoyance has been that the old .la files no longer work (my Fink packages are currently a mess). I deleted all .la files in the Fink directory structure and rebuild the appropriate package when an .la file comes up missing. I can *almost* build a functioning Octave. It compiles, but crashes during "make check". If I run and then exit, I get a core dump. I wish I had time to look into what is happening but I have very little spare time at present. Ben From rob at jlab.org Wed Sep 9 14:44:45 2009 From: rob at jlab.org (Rob Mahurin) Date: Wed, 9 Sep 2009 15:44:45 -0400 Subject: Logarithmic hist and other colour In-Reply-To: <200909081037.20947.schubert.seb@googlemail.com> References: <200909081037.20947.schubert.seb@googlemail.com> Message-ID: <20090909194405.GA64737@dyn21924529.dz.ornl.gov> On Tue, Sep 08, 2009 at 10:37:16AM +0200, Sebastian Schubert wrote: > is it possible to plot a histogram logarithmically within octave (3.2.2) > with the standard tools? Can I change the colour (no filling of the > bars)? Pointers to the manual are fine. :) I do this by > hist(whatever); > set(gca,"yscale","log") Cheers, Rob From efrios at yahoo.com Wed Sep 9 16:28:17 2009 From: efrios at yahoo.com (Hielos) Date: Wed, 9 Sep 2009 14:28:17 -0700 (PDT) Subject: jhandles with debian In-Reply-To: <6ec71d090905231528u6265c95fw2db40e30681e894a@mail.gmail.com> References: <6ec71d090905210458l3d18fe82r870a7b8c341419ba@mail.gmail.com> <128f38bd0905210545s40a3fcb3iab142a26964b095a@mail.gmail.com> <6ec71d090905210634i31dbc3c6yfa8407cad5ae1ada@mail.gmail.com> <128f38bd0905210749t73e5d6f0re2dab67570e543d@mail.gmail.com> <6ec71d090905210756p4cda351bhfe4f822486eb454e@mail.gmail.com> <128f38bd0905210802k35028c58qe3278fca58a55fca@mail.gmail.com> <6ec71d090905231528u6265c95fw2db40e30681e894a@mail.gmail.com> Message-ID: <25373464.post@talk.nabble.com> Hello. If it makes you feel better, I am having the same issue as you. There is not much information on how to solve it, and I think it should. May be, jhandles was only destined to work with Windows..? As a matter of fact, I think that the bottom line goes to installing octave-java. I am running Jaunty (ubuntu 9.04) 64 bits. From my perspective, this is a REAL issue, since I can't program any GUI's without jhandles (I have seen it's marked as whish-list somewhere else). Good luck to all of us oz123 wrote: > > Hello, again > ./configure on my debian machine will succeed only if I do: > > export JAVA_HOME="/usr/lib/jvm/java-6-sun-1.6.0.13/" > > These are the last line of the configure out put. > > But like I said before it fails on make . > __java__.cc: In member function ?octave_value > octave_java::do_java_set(JNIEnv*, const std::string&, const > octave_value&)?: > __java__.cc:1812: warning: deprecated conversion from string constant to > ?char*? > __java__.cc: In static member function ?static octave_value > octave_java::do_java_set(JNIEnv*, const std::string&, const std::string&, > const octave_value&)?: > __java__.cc:1834: warning: deprecated conversion from string constant to > ?char*? > make[1]: *** [__java__.oct] Error 1 > make[1]: Leaving directory `/home/ozdeb/Desktop/java-1.2.6/src' > make: *** [build] Error 2 > > Are these the header files you mean ? > > /usr/lib/jvm/java-6-sun-1.6.0.13/include > /usr/lib/jvm/java-6-sun-1.6.0.13/include/linux > /usr/lib/jvm/java-6-sun-1.6.0.13/include/linux/jni_md.h > /usr/lib/jvm/java-6-sun-1.6.0.13/include/linux/jawt_md.h > /usr/lib/jvm/java-6-sun-1.6.0.13/include/jni.h > /usr/lib/jvm/java-6-sun-1.6.0.13/include/jdwpTransport.h > /usr/lib/jvm/java-6-sun-1.6.0.13/include/jawt.h > /usr/lib/jvm/java-6-sun-1.6.0.13/include/classfile_constants.h > /usr/lib/jvm/java-6-sun-1.6.0.13/include/jvmti.h > > > Because if so, they are already under java home. > > I even tried copying them to the working directory of java/src/ where make > is working. But it still fails. > > Any idea ? > B.T.W the silence about the subject means nobody is using jhandles on > linux > ? Someone ? > > Thanks, Oz > > > On Thu, May 21, 2009 at 5:02 PM, Michael Goffioul < > michael.goffioul at gmail.com> wrote: > >> On Thu, May 21, 2009 at 3:56 PM, Oz Nahum wrote: >> >>JDK include directory is not in the standard include path, so it >> >>seems you have to add it manually, through some environment >> >>variable. Under MSVC, I use INCLUDE variable. >> > >> > Ok, could someone translate this to noobs simple language ? >> > I understand you develop this software under microsoft windows [:-(], >> and >> I >> > don't understand >> > what is the include variable. You mean I have to change manually the >> > configure or make files ? >> >> What it means is that the headers provided by JDK are not installed >> in some standard location, so the compiler cannot find them >> automatically. >> The configure script expects them in $JAVA_HOME/include. If this is not >> the case, then you'll have to fix your system, or let the compiler know >> about >> the non standard location, usually by using some well-known environment >> variable. Under MSVC, this is achieved through the variable called >> "INCLUDE". >> >> I don't know the equivalent for GCC, but I guess using CPPFLAGS and the >> -I compiler flag could do it. >> >> Michael. >> > > > > -- > ---- > Imagine there's no countries > It isn't hard to do > Nothing to kill or die for > And no religion too > Imagine all the people > Living life in peace > > _______________________________________________ > Help-octave mailing list > Help-octave at octave.org > https://www-old.cae.wisc.edu/mailman/listinfo/help-octave > > -- View this message in context: http://www.nabble.com/jhandles-with-debian-tp23652114p25373464.html Sent from the Octave - General mailing list archive at Nabble.com. From tmacchant at yahoo.co.jp Wed Sep 9 19:06:56 2009 From: tmacchant at yahoo.co.jp (Tatsuro MATSUOKA) Date: Thu, 10 Sep 2009 09:06:56 +0900 (JST) Subject: Can I change maker of stem? In-Reply-To: <4AA7A402.7040605@dbateman.org> Message-ID: <20090910000657.93938.qmail@web3809.mail.bbt.yahoo.co.jp> Hello --- David Batemanwrote: > Oppps, check the bugfix > > http://hg.tw-math.de/release-3-2-x/rev/d208ae6e9d74 > > so the first syntax will be fixed in 3.2.3 I have confirmed on tbe 3.2.3rc-3. Thanks!! -------------------------------------- Thanks 10 years! Yahoo! Shopping and Yahoo! Auctions http://pr.mail.yahoo.co.jp/ec10years/ From gbohanno at netscape.net Wed Sep 9 21:00:08 2009 From: gbohanno at netscape.net (George Bohannon) Date: Wed, 09 Sep 2009 22:00:08 -0400 Subject: Trouble building 3.2.2 (pthread) Message-ID: <8CBFFD18EB0F5CD-25C0-6700@webmail-m036.sysops.aol.com> Success!? Persistence pays off again. Gotta use lib64, not lib. Here are the environment variables that allowed the build to work: export F77=gfortran export LIBS=-lpthread export LDFLAGS=-L/usr/local/lib64 export LD_LIBRARY_PATH=/usr/local/lib64 It all seems so simple now. -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090909/6168a317/attachment-0001.html From udippel at uniten.edu.my Wed Sep 9 21:27:13 2009 From: udippel at uniten.edu.my (Uwe Dippel) Date: Thu, 10 Sep 2009 10:27:13 +0800 Subject: Octave and Eidors Message-ID: <4AA86401.8080502@uniten.edu.my> Dear all, I am a total newbie. Not to Unix nor Linux, but to Octave and Eidors. I followed what is written on the main site of eidors, but the examples fail: octave:1> run downloads/eidors-v3.3/startup.m warning: isstr is obsolete and will be removed from a future version of Octave, please use ischar instead EIDORS:[Completed setting up of EIDORS Version 3.3 ($Date: 2008/07/19 16:14:18 $)] EIDORS:[Parameter: cache_size=100 MB] EIDORS:[Parameter: mapped_colour=127] EIDORS:[Default background colour: write] EIDORS:[EIDORS mex folder: /home/udippel/downloads/eidors-v3.3/arch/octave/pc] octave:3> run downloads/eidors-v3.3/examples/demo_real.m step 1: create FEM model structure step 2: create FEM model electrodes definitions step 3: create FEM model stimulation and measurement patterns step 4: simulate data for homogeneous medium step 5: simulate data for inhomogeneous medium warning: set: invalid property `Name' warning: set: invalid property `EdgeColor' error: invalid value = Direct error: called from `__patch__' in file /usr/share/octave/3.0.1/m/plot/__patch__.m near line 182, column 5 error: gnuplot (as of v4.2) only supports 2D filled patches error: evaluating if command near line 537, column 9 error: evaluating if command near line 531, column 7 error: evaluating if command near line 529, column 5 error: evaluating for command near line 518, column 3 error: evaluating switch command near line 332, column 7 error: evaluating for command near line 328, column 5 error: evaluating if command near line 25, column 3 error: called from `__go_draw_axes__' in file /usr/share/octave/3.0.1/m/plot/__go_draw_axes__.m error: evaluating switch command near line 58, column 4 error: evaluating for command near line 56, column 2 error: evaluating if command near line 33, column 7 error: evaluating if command near line 26, column 5 error: evaluating if command near line 25, column 3 error: called from `__go_draw_figure__' in file /usr/share/octave/3.0.1/m/plot/__go_draw_figure__.m error: evaluating if command near line 81, column 6 error: evaluating if command near line 78, column 4 error: evaluating if command near line 76, column 2 error: evaluating for command near line 75, column 7 error: evaluating if command near line 45, column 5 error: called from `drawnow' in file /usr/share/octave/3.0.1/m/plot/drawnow.m octave:3> Please, have a bit of patience with me, and help me out; what is wrong?? (I have done my homework, as far as the first error is concerned, and googled for it, but it did not result in anything. Meaning, I must be doing something totally wrong? Uwe From jwe at octave.org Thu Sep 10 00:19:17 2009 From: jwe at octave.org (John W. Eaton) Date: Thu, 10 Sep 2009 01:19:17 -0400 Subject: Octave and Eidors In-Reply-To: <4AA86401.8080502@uniten.edu.my> References: <4AA86401.8080502@uniten.edu.my> Message-ID: <19112.35925.323307.343873@segfault.lan> On 10-Sep-2009, Uwe Dippel wrote: | I am a total newbie. Not to Unix nor Linux, but to Octave and Eidors. I | followed what is written on the main site of eidors, but the examples fail: | | octave:1> run downloads/eidors-v3.3/startup.m | warning: isstr is obsolete and will be removed from a future version of | Octave, please use ischar instead | EIDORS:[Completed setting up of EIDORS Version 3.3 ($Date: 2008/07/19 | 16:14:18 $)] | EIDORS:[Parameter: cache_size=100 MB] | EIDORS:[Parameter: mapped_colour=127] | EIDORS:[Default background colour: write] | EIDORS:[EIDORS mex folder: | /home/udippel/downloads/eidors-v3.3/arch/octave/pc] | octave:3> run downloads/eidors-v3.3/examples/demo_real.m | step 1: create FEM model structure | step 2: create FEM model electrodes definitions | step 3: create FEM model stimulation and measurement patterns | step 4: simulate data for homogeneous medium | step 5: simulate data for inhomogeneous medium | warning: set: invalid property `Name' | warning: set: invalid property `EdgeColor' | error: invalid value = Direct | error: called from `__patch__' in file | /usr/share/octave/3.0.1/m/plot/__patch__.m near line 182, column 5 You might have better luck with graphics if you try the current Octave release, 3.2.2. jwe From dbateman at dbateman.org Thu Sep 10 00:34:28 2009 From: dbateman at dbateman.org (David Bateman) Date: Thu, 10 Sep 2009 07:34:28 +0200 Subject: Octave and Eidors In-Reply-To: <4AA86401.8080502@uniten.edu.my> References: <4AA86401.8080502@uniten.edu.my> Message-ID: <4AA88FE4.4050408@dbateman.org> Uwe Dippel wrote: > Dear all, > > I am a total newbie. Not to Unix nor Linux, but to Octave and Eidors. I > followed what is written on the main site of eidors, but the examples fail: > > octave:1> run downloads/eidors-v3.3/startup.m > warning: isstr is obsolete and will be removed from a future version of > Octave, please use ischar instead > EIDORS:[Completed setting up of EIDORS Version 3.3 ($Date: 2008/07/19 > 16:14:18 $)] > EIDORS:[Parameter: cache_size=100 MB] > EIDORS:[Parameter: mapped_colour=127] > EIDORS:[Default background colour: write] > EIDORS:[EIDORS mex folder: > /home/udippel/downloads/eidors-v3.3/arch/octave/pc] > octave:3> run downloads/eidors-v3.3/examples/demo_real.m > step 1: create FEM model structure > step 2: create FEM model electrodes definitions > step 3: create FEM model stimulation and measurement patterns > step 4: simulate data for homogeneous medium > step 5: simulate data for inhomogeneous medium > warning: set: invalid property `Name' > warning: set: invalid property `EdgeColor' > error: invalid value = Direct > error: called from `__patch__' in file > /usr/share/octave/3.0.1/m/plot/__patch__.m near line 182, column 5 > error: gnuplot (as of v4.2) only supports 2D filled patches > error: evaluating if command near line 537, column 9 > error: evaluating if command near line 531, column 7 > error: evaluating if command near line 529, column 5 > error: evaluating for command near line 518, column 3 > error: evaluating switch command near line 332, column 7 > error: evaluating for command near line 328, column 5 > error: evaluating if command near line 25, column 3 > error: called from `__go_draw_axes__' in file > /usr/share/octave/3.0.1/m/plot/__go_draw_axes__.m > error: evaluating switch command near line 58, column 4 > error: evaluating for command near line 56, column 2 > error: evaluating if command near line 33, column 7 > error: evaluating if command near line 26, column 5 > error: evaluating if command near line 25, column 3 > error: called from `__go_draw_figure__' in file > /usr/share/octave/3.0.1/m/plot/__go_draw_figure__.m > error: evaluating if command near line 81, column 6 > error: evaluating if command near line 78, column 4 > error: evaluating if command near line 76, column 2 > error: evaluating for command near line 75, column 7 > error: evaluating if command near line 45, column 5 > error: called from `drawnow' in file > /usr/share/octave/3.0.1/m/plot/drawnow.m > octave:3> > > Please, have a bit of patience with me, and help me out; what is wrong?? > > (I have done my homework, as far as the first error is concerned, and > googled for it, but it did not result in anything. Meaning, I must be > doing something totally wrong? > > Uwe > Try using a newer version of Octave. Version 3.2.2 for example.. I suspect this will work there.. Though you should report to Eidors that "isstr" is deprecated in Octave David -- David Bateman dbateman at dbateman.org 35 rue Gambetta +33 1 46 04 02 18 (Home) 92100 Boulogne-Billancourt FRANCE +33 6 72 01 06 33 (Mob) From tmacchant at yahoo.co.jp Thu Sep 10 05:14:40 2009 From: tmacchant at yahoo.co.jp (Tatsuro MATSUOKA) Date: Thu, 10 Sep 2009 19:14:40 +0900 (JST) Subject: Octave and MSVC In-Reply-To: <981987.2481.qm@web59002.mail.re1.yahoo.com> Message-ID: <20090910101440.23897.qmail@web3802.mail.bbt.yahoo.co.jp> Hello Sorry! The page is no longer maintained. I have to close the page. The release of octave on MSVC have deleted from the sourceforge cite due to the licence issue. Today on the octave ML, the following topic is submitted. unofficial octave 3.2.2 msvc2008 solution/project files http://www.nabble.com/unofficial-octave-3.2.2-msvc2008-solution-project-files-tt25368142.html I have not seen it yet. I hope that the above is useful for you. Regards Tatsuro --- David Sarraf wrote: > Dr. Matsuoka > > On your "Tatsuro's Octave for Windows Page", you mention compiling .oct files with MSVC. Have > you found a place to download the older 2005 verison of MSVC? If so, could you please provide > me with the link? I have a similar problem. I want to use fracshift.m from the Signals > toolbox, however that function depends on another function, upfirdn, that needs to be compiled. > > > > Thank you > > > > David Sarraf > -------------------------------------- Thanks 10 years! Yahoo! Shopping and Yahoo! Auctions http://pr.mail.yahoo.co.jp/ec10years/ From mirek at zind.ikem.pwr.wroc.pl Thu Sep 10 05:29:18 2009 From: mirek at zind.ikem.pwr.wroc.pl (Miroslaw Kwasniak) Date: Thu, 10 Sep 2009 12:29:18 +0200 Subject: Exponential notation in tick labels? In-Reply-To: <9156614F-3C2D-4222-93F8-D9C39C71A697@eawag.ch> References: <9156614F-3C2D-4222-93F8-D9C39C71A697@eawag.ch> Message-ID: <20090910102918.GC1544@zind.ikem.pwr.wroc.pl> On Wed, Sep 09, 2009 at 10:44:09AM +0200, Matthias Brennwald wrote: > Dear all > > I'm sure this has been discussed before, but I couldn't find anything > (maybe I did not chose the right search terms). I'd like to use > exponential notation for tick-mark labels in plots. For instance "plot > ([0:1e4:1E6])" yields a plot with y-axis labels 0, 200000, 400000, > 600000, 700000, 1e+6. I'd like these to be 0, 2e5, 4e5, 6e5, 8e5, 1e6. > Or, even better, 0, 2x10^5, 4x10^5,..., 10^6. How can I achieve this? %tick values tv=(0:2:10)*1e5; %tick labels tl=eval(strrep(['tl=[',sprintf("'%.0g'\n",tv),']'],'e+0','*10^')); %use on plot set(gca,'ytick',tv,'yticklabel',tl) From mirek at zind.ikem.pwr.wroc.pl Thu Sep 10 05:29:18 2009 From: mirek at zind.ikem.pwr.wroc.pl (Miroslaw Kwasniak) Date: Thu, 10 Sep 2009 12:29:18 +0200 Subject: Exponential notation in tick labels? In-Reply-To: <9156614F-3C2D-4222-93F8-D9C39C71A697@eawag.ch> References: <9156614F-3C2D-4222-93F8-D9C39C71A697@eawag.ch> Message-ID: <20090910102918.GC1544@zind.ikem.pwr.wroc.pl> On Wed, Sep 09, 2009 at 10:44:09AM +0200, Matthias Brennwald wrote: > Dear all > > I'm sure this has been discussed before, but I couldn't find anything > (maybe I did not chose the right search terms). I'd like to use > exponential notation for tick-mark labels in plots. For instance "plot > ([0:1e4:1E6])" yields a plot with y-axis labels 0, 200000, 400000, > 600000, 700000, 1e+6. I'd like these to be 0, 2e5, 4e5, 6e5, 8e5, 1e6. > Or, even better, 0, 2x10^5, 4x10^5,..., 10^6. How can I achieve this? %tick values tv=(0:2:10)*1e5; %tick labels tl=eval(strrep(['tl=[',sprintf("'%.0g'\n",tv),']'],'e+0','*10^')); %use on plot set(gca,'ytick',tv,'yticklabel',tl) From vic at norton.name Thu Sep 10 05:34:59 2009 From: vic at norton.name (Vic Norton) Date: Thu, 10 Sep 2009 06:34:59 -0400 Subject: Install packages in Mac OS X In-Reply-To: <4AA7F0D6.9060206@gmx.net> References: <97579901-A788-4093-AD33-4FBDE5C1D709@norton.name> <4AA7F0D6.9060206@gmx.net> Message-ID: <8EB1C2D9-1B3D-4DFC-AC7A-86A373C7508A@norton.name> Thanks Thomas! This thread settles one thing for me. I have a copy of Snow Leopard coming from Amazon. I definitely will NOT install it until I can install an Octave that will work with it. I depend on Octave. I can do without Snow Leopard. Regards, Vic On Sep 9, 2009, at 2:15 PM, Thomas Treichl wrote: > Vic Norton schrieb: >> I don't have Snow Leopard yet, but you might try this. It works for >> me. >> 1) Download "Octave.app for Mac OS X" from >> . >> 2) Drop the Octave application into your Applications folder. >> 3) To be able to use the shebang line >> #!/usr/local/bin/octave >> in your scripts, do >> $ sudo ln -s \ >> /Applications/Octave.app/Contents/Resources/bin/octave \ >> /usr/local/bin >> in Terminal. >> Regards, >> Vic >> On Sep 8, 2009, at 8:28 PM, Xin Dong wrote: >>> Hi, >>> >>> Has anyone successfully installed octave-forge packages with snow >>> leopard and octave 3.2.2? I tried to install image-1.0.10.tar.gz, >>> but >>> failed. > > Hi Vic, hi Xin, > > I think the problem is a bit more complex. Apple has changed some > more things from Leopard to Snow Leopard and with Snow Leopard > everything that has to do with Octave's mkoctfile is broken now (ie. > installing packages, the 'mkoctfile' command itself, the command > 'mex', and so on) - in detail: Snow Leopard's linker does not accept > my 10.4 build libraries anymore and that's why linking against my > binaries completely fails. I've already commented on a similar > problem here > > http://www-old.cae.wisc.edu/pipermail/bug-octave/2009-September/009375.html > > Just because of my own interest - what is the current GCC version > from Snow Leopard's XCode tools? Is there at least a gfortran > available? > > Best regards > > Thomas > > From wilson.rosa at gmail.com Thu Sep 10 09:18:52 2009 From: wilson.rosa at gmail.com (Wilson de Oliveira) Date: Thu, 10 Sep 2009 11:18:52 -0300 Subject: Netlab on Octave Message-ID: <91e5dab20909100718g49d98773sfc70abb694b45aad@mail.gmail.com> Hi. I hope anyone may help me As you may guess I am a complete newbie in Octave, but I need to run Netlab and have no access to Matlab. I am using Gnu Octave for Windows 3.0.0. When trying to use the Netlab 3.3 demo ?demnlab? I get the following messages: octave-3.0.0.exe:11> demnlab demnlab demnlab.m octave-3.0.0.exe:11> demnlab warning: set: invalid property `Name' warning: set: invalid property `NumberTitle' error: `uicontrol' undefined near line 33 column 3 error: evaluating if command near line 20, column 1 error: called from `demnlab' in file `c:\octave\Netlab\demnlab.m' octave-3.0.0.exe:11> . Wilson de Oliveira UFRPE-DEInfo http://www.cin.ufpe.br/~wrdo -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090910/675a0ce2/attachment.html From ct529 at york.ac.uk Thu Sep 10 09:57:47 2009 From: ct529 at york.ac.uk (Corrado) Date: Thu, 10 Sep 2009 15:57:47 +0100 Subject: Matrix regression of distnce matrices + non negative least square In-Reply-To: <69d8d540909070804i7f1d5821v9c5a4e758dd2338a@mail.gmail.com> References: <200909071338.28862.ct529@york.ac.uk> <200909071521.39612.ct529@york.ac.uk> <69d8d540909070804i7f1d5821v9c5a4e758dd2338a@mail.gmail.com> Message-ID: <200909101557.47893.ct529@york.ac.uk> Dear Jaroslav, Octave list, here I am again .... How do you calculate distance or dissimilarity matrices in Octave? and how do you treat triangular matrices + diagonal in Octave? is there a separate package? Regards On Monday 07 September 2009 16:04:35 Jaroslav Hajek wrote: > On Mon, Sep 7, 2009 at 4:21 PM, Corrado wrote: > > Dear Jaroslav, > > > > thanks for your help. > > > > I actually do not understand what you are suggesting: > > > > 1) The data would be stored in matrices, which I can easily dump into csv > > files > > OK. But mind you, instead of working with a number of equal-sized > matrices it is often more efficient to work with a 3D array. Usually > it depends on where you get the matrices from. > > > 2) The distance matrices are up to 5000 x 5000 (but they symmetric, so > > only n(n-1)/2 are important), but the ones I am using now are just 1500 x > > 1500. > > In that case, it probably doesn't matter much which representation you > choose. > > > 3) I thought lsqnonneg only worked on linear system in the form y=ax > > Yes. That's why you need to bring the system into this form. > > > 4) The terms are matrices, how do you write a canonical form???? the x1 > > .... xn are matrices (e.g. 1500 x 1500) .... the ci are coefficients in R > > .... > > A matrix equation constitutes a system of equations; one for each > element. If x1...xN are MxM, you get a > system of M*(M+1)/2 equations in N variables. > > Suppose you have the matrices X in a cell array, so that X{1} is the > first matrix etc., and the RHS matrix is Y. > Then you want to do something like > A = [cellfun (@vech, X, "UniformOutput", false){:}]; > b = vech (Y); > c = lsqnonneg (A, b); > To get the coefficients in "c". Note that lsqnonneg is part of Octave > 3.2.0+. There is a small problem with the above simplistic code: it does > not discard the diagonal equations, because vech includes the diagonal. You > can modify vech in order to discard even the diagonal equations. > > hth -- Corrado Topi Global Climate Change & Biodiversity Indicators Area 18,Department of Biology University of York, York, YO10 5YW, UK Phone: + 44 (0) 1904 328645, E-mail: ct529 at york.ac.uk From tmacchant at yahoo.co.jp Thu Sep 10 10:06:08 2009 From: tmacchant at yahoo.co.jp (Tatsuro MATSUOKA) Date: Fri, 11 Sep 2009 00:06:08 +0900 (JST) Subject: Netlab on Octave In-Reply-To: <91e5dab20909100718g49d98773sfc70abb694b45aad@mail.gmail.com> Message-ID: <20090910150608.28418.qmail@web3807.mail.bbt.yahoo.co.jp> Hello Please show us what is Netlab more in detail. There wrote no information about demnlab.m. What you think common sense is not always popular to other people. You first reconsider your question again to explain the Netlab to those who did not have knowledge of them. BTW, why do you want use old octave ? The compatibility to MATLAB is much improved in the octave 3.2 than that of octave 3.0. Regards Tatsuro --- Wilson de Oliveira wrote: > Hi. I hope anyone may help me > As you may guess I am a complete newbie in Octave, > but I need to run Netlab and have no access to Matlab. > > I am using Gnu Octave for Windows 3.0.0. > When trying to use the Netlab 3.3 demo ?demnlab? > I get the following messages: > > octave-3.0.0.exe:11> demnlab > demnlab demnlab.m > octave-3.0.0.exe:11> demnlab > warning: set: invalid property `Name' > warning: set: invalid property `NumberTitle' > error: `uicontrol' undefined near line 33 column 3 > error: evaluating if command near line 20, column 1 > error: called from `demnlab' in file `c:\octave\Netlab\demnlab.m' > octave-3.0.0.exe:11> > > . > Wilson de Oliveira > UFRPE-DEInfo > http://www.cin.ufpe.br/~wrdo > > _______________________________________________ > Help-octave mailing list > Help-octave at octave.org > https://www-old.cae.wisc.edu/mailman/listinfo/help-octave > -------------------------------------- Thanks 10 years! Yahoo! Shopping and Yahoo! Auctions http://pr.mail.yahoo.co.jp/ec10years/ From dfslezak at gmail.com Thu Sep 10 11:04:03 2009 From: dfslezak at gmail.com (=?ISO-8859-1?Q?Diego_Fern=E1ndez_Slezak?=) Date: Thu, 10 Sep 2009 12:04:03 -0400 Subject: Compiling error Message-ID: Hello, I'm trying to compile Octave in BlueGene. My configure line is ./configure --disable-readline --disable-shared --disable-dl --enable-static --target=ppc-bgp-gnu --host=ppc-bgp-gnu --without-hdf5 --without-fftw --without-x --with-x=no --without-readline --without-gnuplot --with-blas=esslbg When I try to compile it, it fails with the following error. Apparently, the option --without-x and --with-x=no are not being taken into account. When I check the Makeconf file, I find HAVE_X_WINDOWS defined. Any ideas? . . . /bgsys/drivers/ppcfloor/gnu-linux//bin/powerpc-bgp-linux-g++ -c -I/bgsys/drivers/ppcfloor//include -I. -I.. -I../liboctave -I../src -I../libcruft/misc -DHAVE_CONFIG_H -Wall -W -Wshadow -Wold-style-cast -Wformat -I/bgsys/drivers/ppcfloor//include -O3 display.cc -o display.o display.cc:34:22: error: X11/Xlib.h: No such file or directory display.cc: In member function ?void display_info::init()?: display.cc:96: error: ?Display? was not declared in this scope display.cc:96: error: ?display? was not declared in this scope display.cc:96: error: ?XOpenDisplay? was not declared in this scope display.cc:100: error: ?Screen? was not declared in this scope display.cc:100: error: ?screen? was not declared in this scope display.cc:100: error: ?DefaultScreenOfDisplay? was not declared in this scope display.cc:104: error: ?DefaultDepthOfScreen? was not declared in this scope display.cc:106: error: ?HeightOfScreen? was not declared in this scope display.cc:107: error: ?WidthOfScreen? was not declared in this scope display.cc:109: error: ?XScreenNumberOfScreen? was not declared in this scope display.cc:111: error: ?DisplayHeightMM? was not declared in this scope display.cc:112: error: ?DisplayWidthMM? was not declared in this scope make[2]: *** [display.o] Error 1 make[2]: Leaving directory `/bgpusr2/xdslezak/octave-3.2.2/src' make[1]: *** [src] Error 2 make[1]: Leaving directory `/bgpusr2/xdslezak/octave-3.2.2' make: *** [all] Error 2 From udippel at uniten.edu.my Thu Sep 10 11:39:21 2009 From: udippel at uniten.edu.my (Uwe Dippel) Date: Fri, 11 Sep 2009 00:39:21 +0800 Subject: Help-octave Digest, Vol 42, Issue 18 In-Reply-To: References: Message-ID: <4AA92BB9.9030501@uniten.edu.my> help-octave-request at octave.org wrote: > > Message: 2 > Date: Thu, 10 Sep 2009 01:19:17 -0400 > From: "John W. Eaton" > Subject: Octave and Eidors > To: Uwe Dippel > Cc: help-octave at octave.org > Message-ID: <19112.35925.323307.343873 at segfault.lan> > Content-Type: text/plain; charset=us-ascii > > On 10-Sep-2009, Uwe Dippel wrote: > > | I am a total newbie. Not to Unix nor Linux, but to Octave and Eidors. I > | followed what is written on the main site of eidors, but the examples fail: > | > | octave:1> run downloads/eidors-v3.3/startup.m > | warning: isstr is obsolete and will be removed from a future version of > | Octave, please use ischar instead > | EIDORS:[Completed setting up of EIDORS Version 3.3 ($Date: 2008/07/19 > | 16:14:18 $)] > | EIDORS:[Parameter: cache_size=100 MB] > | EIDORS:[Parameter: mapped_colour=127] > | EIDORS:[Default background colour: write] > | EIDORS:[EIDORS mex folder: > | /home/udippel/downloads/eidors-v3.3/arch/octave/pc] > | octave:3> run downloads/eidors-v3.3/examples/demo_real.m > | step 1: create FEM model structure > | step 2: create FEM model electrodes definitions > | step 3: create FEM model stimulation and measurement patterns > | step 4: simulate data for homogeneous medium > | step 5: simulate data for inhomogeneous medium > | warning: set: invalid property `Name' > | warning: set: invalid property `EdgeColor' > | error: invalid value = Direct > | error: called from `__patch__' in file > | /usr/share/octave/3.0.1/m/plot/__patch__.m near line 182, column 5 > > You might have better luck with graphics if you try the current Octave > release, 3.2.2. > Okay, that's the first step. How would this be done most favourably on Ubuntu 9.04? There is a download link that mentions packages (http://octave.sf.net/), but none is to be seen. Of course, I'd prefer a Ubuntu-.deb. > > Try using a newer version of Octave. Version 3.2.2 for example.. I > suspect this will work there.. Though you should report to Eidors that > "isstr" is deprecated in Octave > They have changed it in their CVS already; so any next version should have it. I also noticed it in my failed efforts, but it was a warning only. Uwe From carlo.defalco at gmail.com Thu Sep 10 11:57:48 2009 From: carlo.defalco at gmail.com (Carlo de Falco) Date: Thu, 10 Sep 2009 18:57:48 +0200 Subject: 4-D Array Message-ID: <611AD04F-B050-4A54-8625-BF253463EC56@gmail.com> Hi, I am trying to create a 4D NDArray (3x3x3x3) from within an oct-file but I don't understand how dim_vector works, I tried the following but it crashes Octave: dim_vector a (4); a(0)=3;a(1)=3;a(2)=3;a(3)=3; NDArray b (a); with the error: ../liboctave/dim-vector.h:113: failed assertion `i >= 0 && i < ndims' any help appreciated, c. From jwe at octave.org Thu Sep 10 12:09:21 2009 From: jwe at octave.org (John W. Eaton) Date: Thu, 10 Sep 2009 13:09:21 -0400 Subject: 4-D Array In-Reply-To: <611AD04F-B050-4A54-8625-BF253463EC56@gmail.com> References: <611AD04F-B050-4A54-8625-BF253463EC56@gmail.com> Message-ID: <19113.12993.833814.388335@segfault.lan> On 10-Sep-2009, Carlo de Falco wrote: | I am trying to create a 4D NDArray (3x3x3x3) from within | an oct-file but I don't understand how dim_vector works, | I tried the following but it crashes Octave: | | dim_vector a (4); Looking at the dim-vector.h header file, I see explicit dim_vector (octave_idx_type n) : rep (newrep (2)) { rep[0] = n; rep[1] = 1; } so dim_vector a(4) creates a dimension vector for an 4x1 object. You need to do dim_vector a; a.resize (4); a(0) = 3; a(1) = 3; a(2) = 3; a(3) = 3; or, since your dimensions are all the same, this should also work: dim_vector a; a.resize (4, 3); jwe From gkousiou at telecom.ntua.gr Thu Sep 10 12:10:00 2009 From: gkousiou at telecom.ntua.gr (George Kousiouris) Date: Thu, 10 Sep 2009 20:10:00 +0300 (EEST) Subject: Unable to load matlab-produced mat files in octave Message-ID: <1149.147.102.19.192.1252602600.squirrel@my.telecom.ntua.gr> Hi all, I have a neural network created with Matlab 7.5 and stored in a mat file. I am trying to load it to Octave 3.0.1 unsuccessfully. I have also tried saving it as older Matlab version, however with the older versions I get the error Unknown object. Saving it as 7.3 version, I get the following error when attempting to load it in Octave: error:load:error while reading hdf5 item IW Any suggestions? Thanks in advance and best regards, George From Pascal.Dupuis at worldonline.be Thu Sep 10 11:05:52 2009 From: Pascal.Dupuis at worldonline.be (Dupuis) Date: Thu, 10 Sep 2009 09:05:52 -0700 (PDT) Subject: sqp, objective and equality constraint gradients ? Message-ID: <25385728.post@talk.nabble.com> Hello, I have troubles getting sqp to work. Problem is defined as finding points on an ellipse verifying some optimum condition. objective: f =@(x) -prod(x); gradient: fg = @(x) -[x(2); x(1)]; equality: ce = @(x) (x-center).'*M*(x-center) - level gradient: ceg = @(x) 2*M*(x-center) where x is a (2, 1) vector, center is a (2, 1) vector with the center coordinates, M is symetric, positive definite and level the sum of square of the distances between each point and the two ellipse defining points. The call is as follows: 1) find some good candidate by trying a few points, let's call it xinit 2) lb = .95*xinit; ub = 1.05*xinit %# define a five percent search interval 3) [xopt, obj, info, iter, nf, lambda] = sqp(xinit, {f fg}, {ce ceg}, [], lb, ub); The problems are at line 343 and 377 F = feval (ce_grd, x); C = feval (ci_grd, x); A = [F; C]; F is supposed to be (n, 1); while C is (2*n, n): they are not compatible ... I tried transposing F or padding F with zeroes : if line 343 succeeds, the code fails elsewhere, f.i. in line 377: t4 = norm (lambda .* con) which expects lambda (rows(F), 1) and con (= [ce; ci]) to be the same dimensions. Could someone please tell me the expected dimensions of the various gradients ? Regards Pascal -- View this message in context: http://www.nabble.com/sqp%2C-objective-and-equality-constraint-gradients---tp25385728p25385728.html Sent from the Octave - General mailing list archive at Nabble.com. From redays at gmail.com Thu Sep 10 12:27:35 2009 From: redays at gmail.com (Leandro) Date: Thu, 10 Sep 2009 14:27:35 -0300 Subject: Install 3.2.2 Message-ID: When I do the 'make install' command It says that it can't find the file conf.texi, but I type 'conf.texi.in' and it keeps going... but then It can't find the file 'polynomial.m', but the file IS in the octave3.2.2 folder. What do I have to do? I am using Ubuntu 9.04 64 bits. Thanks. -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090910/d6f78626/attachment.html From ct529 at york.ac.uk Thu Sep 10 12:53:16 2009 From: ct529 at york.ac.uk (Corrado) Date: Thu, 10 Sep 2009 18:53:16 +0100 Subject: Install 3.2.2 In-Reply-To: References: Message-ID: <200909101853.16177.ct529@york.ac.uk> It sounds strange .... did you type "sudo make install" or are you trying to install in the user home directory? On Thursday 10 September 2009 18:27:35 Leandro wrote: > When I do the 'make install' command It says that it can't find the file > conf.texi, but I type 'conf.texi.in' and it keeps going... but then It > can't find the file 'polynomial.m', but the file IS in the octave3.2.2 > folder. What do I have to do? > > I am using Ubuntu 9.04 64 bits. > > Thanks. -- Corrado Topi Global Climate Change & Biodiversity Indicators Area 18,Department of Biology University of York, York, YO10 5YW, UK Phone: + 44 (0) 1904 328645, E-mail: ct529 at york.ac.uk From jwe at octave.org Thu Sep 10 13:02:19 2009 From: jwe at octave.org (John W. Eaton) Date: Thu, 10 Sep 2009 14:02:19 -0400 Subject: Install 3.2.2 In-Reply-To: References: Message-ID: <19113.16171.550556.867755@segfault.lan> On 10-Sep-2009, Leandro wrote: | When I do the 'make install' command It says that it can't find the file | conf.texi, but I type 'conf.texi.in' and it keeps going... but then It can't | find the file 'polynomial.m', but the file IS in the octave3.2.2 folder. | What do I have to do? Precisely what did you do? Did you run configure? Did you run make? Or did you just unpack the tar file and run "make install"? jwe From dbateman at dbateman.org Thu Sep 10 13:13:56 2009 From: dbateman at dbateman.org (David Bateman) Date: Thu, 10 Sep 2009 20:13:56 +0200 Subject: Unable to load matlab-produced mat files in octave In-Reply-To: <1149.147.102.19.192.1252602600.squirrel@my.telecom.ntua.gr> References: <1149.147.102.19.192.1252602600.squirrel@my.telecom.ntua.gr> Message-ID: <4AA941E4.4030001@dbateman.org> George Kousiouris wrote: > Hi all, > > I have a neural network created with Matlab 7.5 and stored in a mat file. > I am trying to load it to Octave 3.0.1 unsuccessfully. I have also tried > saving it as older Matlab version, however with the older versions I get > the error > > Unknown object. > > Saving it as 7.3 version, I get the following error when attempting to > load it in Octave: > > error:load:error while reading hdf5 item IW > > > Any suggestions? > > Thanks in advance and best regards, > George > > > > Matlab v7.3 format is not yet supported. Adding this support would make a nice project for someone, and was one of the things on my personal wishlist before I had to cut back my contributions to Octave. For now save your files in matlab with the the "-v7" flag or change your default file format preference as shown on the page http://www.mathworks.com/access/helpdesk/help/techdoc/ref/save.html D. -- David Bateman dbateman at dbateman.org 35 rue Gambetta +33 1 46 04 02 18 (Home) 92100 Boulogne-Billancourt FRANCE +33 6 72 01 06 33 (Mob) From carlo.defalco at gmail.com Thu Sep 10 14:15:40 2009 From: carlo.defalco at gmail.com (Carlo de Falco) Date: Thu, 10 Sep 2009 21:15:40 +0200 Subject: 4-D Array In-Reply-To: <611AD04F-B050-4A54-8625-BF253463EC56@gmail.com> References: <611AD04F-B050-4A54-8625-BF253463EC56@gmail.com> Message-ID: On 10 Sep 2009, at 18:57, Carlo de Falco wrote: > Hi, > I am trying to create a 4D NDArray (3x3x3x3) from within > an oct-file but I don't understand how dim_vector works, > I tried the following but it crashes Octave: > > dim_vector a (4); > a(0)=3;a(1)=3;a(2)=3;a(3)=3; > NDArray b (a); > > with the error: > > ../liboctave/dim-vector.h:113: failed assertion `i >= 0 && i < ndims' > > any help appreciated, > c. > ooops looking at the constructor implementation I see that "dim_vector a (4)" is equivalent to "dim_vector a (4, 1)", so the above makes no sense... c. From highegg at gmail.com Thu Sep 10 14:36:07 2009 From: highegg at gmail.com (Jaroslav Hajek) Date: Thu, 10 Sep 2009 21:36:07 +0200 Subject: Matrix regression of distnce matrices + non negative least square In-Reply-To: <200909101557.47893.ct529@york.ac.uk> References: <200909071338.28862.ct529@york.ac.uk> <200909071521.39612.ct529@york.ac.uk> <69d8d540909070804i7f1d5821v9c5a4e758dd2338a@mail.gmail.com> <200909101557.47893.ct529@york.ac.uk> Message-ID: <69d8d540909101236j4f00c45cl622b06f0d9e727e1@mail.gmail.com> On Thu, Sep 10, 2009 at 4:57 PM, Corrado wrote: > Dear Jaroslav, Octave list, > > here I am again .... > > How do you calculate distance or dissimilarity matrices in Octave? For instance, see http://octave.sourceforge.net/doc/f/pdist.html > and how do > you treat triangular matrices + diagonal in Octave? ?is there a separate > package? > That depends. Diagonal matrices are a special type. Triangular/symmetric matrices are typically treated as full, with certain functions (such as matrix division) able to specialize. Of course, you can also work with vectors of the upper/lower triangular elements, or even with "jagged arrays" - cell arrays of vectors. Your choice. There's also a package for triangular matrices in OctaveForge's extra/, but I don't think it's much used. hth -- RNDr. Jaroslav Hajek computing expert & GNU Octave developer Aeronautical Research and Test Institute (VZLU) Prague, Czech Republic url: www.highegg.matfyz.cz From dbateman at dbateman.org Thu Sep 10 15:06:33 2009 From: dbateman at dbateman.org (David Bateman) Date: Thu, 10 Sep 2009 22:06:33 +0200 Subject: Matrix regression of distnce matrices + non negative least square In-Reply-To: <69d8d540909101236j4f00c45cl622b06f0d9e727e1@mail.gmail.com> References: <200909071338.28862.ct529@york.ac.uk> <200909071521.39612.ct529@york.ac.uk> <69d8d540909070804i7f1d5821v9c5a4e758dd2338a@mail.gmail.com> <200909101557.47893.ct529@york.ac.uk> <69d8d540909101236j4f00c45cl622b06f0d9e727e1@mail.gmail.com> Message-ID: <4AA95C49.1060604@dbateman.org> Jaroslav Hajek wrote: > On Thu, Sep 10, 2009 at 4:57 PM, Corrado wrote: > >> Dear Jaroslav, Octave list, >> >> here I am again .... >> >> How do you calculate distance or dissimilarity matrices in Octave? >> > > For instance, see > http://octave.sourceforge.net/doc/f/pdist.html > > >> and how do >> you treat triangular matrices + diagonal in Octave? is there a separate >> package? >> >> > > That depends. Diagonal matrices are a special type. > Triangular/symmetric matrices are typically treated as full, with > certain functions (such as matrix division) able to specialize. Of > course, you can also work with vectors of the upper/lower triangular > elements, or even with "jagged arrays" - cell arrays of vectors. Your > choice. > > There's also a package for triangular matrices in OctaveForge's > extra/, but I don't think it's much used. > > hth > The triangular matrix code is in octave-forge for the sole reason of having an example user defined type in C++. See the comments in the docs http://octave.svn.sourceforge.net/viewvc/octave/trunk/octave-forge/extra/triangular/doc/triangular.texi?revision=HEAD&view=markup So not surprising the triangular class in octave-forge isn't "used", as its use is as an example for others. D. From vic at norton.name Thu Sep 10 16:29:30 2009 From: vic at norton.name (Vic Norton) Date: Thu, 10 Sep 2009 17:29:30 -0400 Subject: Mac OSX 10.6 and Octave Message-ID: <202B0033-5864-4FC4-AD8A-973756E1FFB7@norton.name> Has anyone been able to successfully install Octave 3.2.2 (or any earlier version) on the new Mac OSX 10.6 (Snow Leopard) operating system? I've heard nothing but horror stories so far. I would very much like to upgrade to Mac OSX 10.6 (which I have purchased), but I dare not upgrade unless I can install Octave. Mind you, I am an old (74), unix-un-savvy mathematician; I need a relatively straightforward installation process. By the way, Octave 3.2.2 works perfectly now, on my 2.93 GHz Intel Core 2 Duo iMac with Mac OSX 10.5.8. As I understand it, Octave 3.2.2 will stop working as soon as I upgrade to Mac OSX 10.6. Am I wrong about this? Any advice would be greatly appreciated. Regards, Vic From bpabbott at mac.com Thu Sep 10 17:09:48 2009 From: bpabbott at mac.com (Ben Abbott) Date: Thu, 10 Sep 2009 18:09:48 -0400 Subject: Mac OSX 10.6 and Octave In-Reply-To: <202B0033-5864-4FC4-AD8A-973756E1FFB7@norton.name> References: <202B0033-5864-4FC4-AD8A-973756E1FFB7@norton.name> Message-ID: On Sep 10, 2009, at 5:29 PM, Vic Norton wrote: > Has anyone been able to successfully install Octave 3.2.2 (or any > earlier version) on the new Mac OSX 10.6 (Snow Leopard) operating > system? I've heard nothing but horror stories so far. I would very > much like to upgrade to Mac OSX 10.6 (which I have purchased), but I > dare not upgrade unless I can install Octave. Mind you, I am an old > (74), unix-un-savvy mathematician; I need a relatively straightforward > installation process. > > By the way, Octave 3.2.2 works perfectly now, on my 2.93 GHz Intel > Core 2 Duo iMac with Mac OSX 10.5.8. As I understand it, Octave 3.2.2 > will stop working as soon as I upgrade to Mac OSX 10.6. Am I wrong > about this? > > Any advice would be greatly appreciated. > > Regards, > > Vic I'm presently unable to build octave, but have no problem running the binary at the link below. http://sourceforge.net/projects/octave/files/Octave%20MacOSX%20Binary However, if you need to compile oct-files, you'll want to wait until the problem with 'mkoctfile' is fixed. http://www.nabble.com/Install-packages-in-Mac-OS-X-td25356552.html Ben From tmacchant at yahoo.co.jp Thu Sep 10 19:19:04 2009 From: tmacchant at yahoo.co.jp (Tatsuro MATSUOKA) Date: Fri, 11 Sep 2009 09:19:04 +0900 (JST) Subject: Netlab on Octave In-Reply-To: <91e5dab20909100829r19723a32teb8d9f19c151b0f3@mail.gmail.com> Message-ID: <20090911001904.22946.qmail@web3802.mail.bbt.yahoo.co.jp> Hello Wilson de Oliveira --- Wilson de Oliveira wrote: > Ok. Sorry. > For a start, Netlab is a Matlab toolbox for Pattern Recognition which > includes amongst others models Neural Networks. It is freely available at: > http://www.ncrg.aston.ac.uk/netlab/index.php > demnlab.m is a demonstration program which runs several models in gui > interface. > > As regard the version of the octave, thanks for your help! The octave 3.0.0 > came with qtoctave - a gui interface for octave; Now that I?ve installed the > 3.2.2 version available at sourceforge.net I got fewer errors: > > > demnlab > error: `uicontrol' undefined near line 33 column 3 > error: called from: > error: C:\Octave\Netlab\demnlab.m at line 33, column 3 > octave-3.2.2.exe:6:C:\Octave\Netlab > > > > Thanks for your help > Wilson de Oliveira > UFRPE-DEInfo > http://www.cin.ufpe.br/~wrdo > > Unfortunately Octave does not support GUI graphic control. You should control graphics with graphic handle functions. Please see section 15 "Plotting" in octave manual. You should read care fully "15.1 Plotting Basics" band "15.2 Advanced Plotting". Perhaps these types functions are compatible to MATLAB. I have tried a simple example in web page. ndata=20 % Generate the matrix of inputs x and targets t. x = [0:1/19:1]'; t = sin(2*pi*x) + 0.2*randn(ndata, 1); % Set up network parameters. net = mlp(1, 3, 1, 'linear') net = { type = mlp nin = 1 nhidden = 3 nout = 1 nwts = 10 outfn = linear w1 = -1.148633 1.104356 0.049478 b1 = -0.070054 0.902782 1.349561 w2 = 0.17895 0.27658 0.36492 b2 = 0.66142 } **************** % Set up vector of options for the optimiser. options = zeros(1,18); options(1) = 1; options(9) = 1; options(14) = 100; % Train using scaled conjugate gradients. [net, options] = netopt(net, options, x, t, 'scg'); error: `fcnchk' undefined near line 68 column 5 error: called from: error: D:\usr\Tatsu\program\Octave\netlab\scg.m at line 68, column 3 error: D:\usr\Tatsu\program\Octave\netlab\netopt.m at line 36, column 17 Octave does not support `fcnchk' But I found http://en.wikibooks.org/wiki/MATLAB_Programming/Differences_between_Octave_and_MATLAB ******** If something (like Netlab) need a function called fcnchk you can just put the following into a file called fcnchk.m and put it somewhere Octave can find it: function f=fcnchk(x, n) f = x; end ******** I placed fcnchk.m under the same folder of netlab SO I get Checking gradient ... analytic diffs delta 1.1904e+000 1.1904e+000 -1.3890e-009 4.8963e-001 4.8963e-001 8.2556e-010 1.1238e+000 1.1238e+000 -5.8918e-010 2.3292e+000 2.3292e+000 -1.3039e-010 1.1362e+000 1.1362e+000 -1.2848e-009 1.8523e+000 1.8523e+000 6.3412e-010 -1.3883e+001 -1.3883e+001 -1.9210e-010 2.0438e+001 2.0438e+001 5.2320e-010 1.9960e+001 1.9960e+001 -9.0928e-011 2.2659e+001 2.2659e+001 -8.4377e-010 Cycle 1 Error 4.629483 Scale 1.000000e+000 Cycle 2 Error 4.629483 Scale 5.000000e-001 Cycle 3 Error 4.629483 Scale 2.000000e+000 Cycle 4 Error 4.259136 Scale 8.000000e+000 Cycle 5 Error 4.050134 Scale 4.000000e+000 Cycle 6 Error 3.775366 Scale 2.000000e+000 Cycle 7 Error 3.390233 Scale 2.000000e+000 Cycle 8 Error 3.288238 Scale 1.000000e+000 Cycle 9 Error 3.286530 Scale 5.000000e-001 Cycle 10 Error 3.235898 Scale 2.500000e-001 Cycle 11 Error 3.212532 Scale 1.250000e-001 Cycle 12 Error 3.192542 Scale 6.250000e-002 Cycle 13 Error 3.187294 Scale 3.125000e-002 : : ***************************************** % Plot the trained network predictions. plotvals = [0:0.01:1]'; y = mlpfwd(net, plotvals); plot(plotvals, y, 'ob') gives a plot like attatchment files. ******** Honestly I am not familiar with this type of work. In addition, I have no experience of MATLAB Hopefully users who use both MATLAB and octave give you much better suggestions. The aboves are all what I can do for you. Good luck!! Regards Tatsuro -------------------------------------- Thanks 10 years! Yahoo! Shopping and Yahoo! Auctions http://pr.mail.yahoo.co.jp/ec10years/ -------------- next part -------------- A non-text attachment was scrubbed... Name: sample.png Type: image/png Size: 8835 bytes Desc: 3472330463-sample.png Url : https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090911/d3ebef1b/attachment.png From Potorti at isti.cnr.it Fri Sep 11 02:21:47 2009 From: Potorti at isti.cnr.it (Francesco Potorti`) Date: Fri, 11 Sep 2009 09:21:47 +0200 Subject: Matrix regression of distnce matrices + non negative least square In-Reply-To: <200909101557.47893.ct529@york.ac.uk> References: <200909071338.28862.ct529@york.ac.uk> <200909071521.39612.ct529@york.ac.uk> <69d8d540909070804i7f1d5821v9c5a4e758dd2338a@mail.gmail.com> <200909101557.47893.ct529@york.ac.uk> Message-ID: >How do you calculate distance or dissimilarity matrices in Octave? Maybe the statistics package can help you? Have you looked at pdist? -- Francesco Potort? (ricercatore) Voice: +39 050 315 3058 (op.2111) ISTI - Area della ricerca CNR Fax: +39 050 315 2040 via G. Moruzzi 1, I-56124 Pisa Email: Potorti at isti.cnr.it (entrance 20, 1st floor, room C71) Web: http://fly.isti.cnr.it/ From highegg at gmail.com Fri Sep 11 04:17:16 2009 From: highegg at gmail.com (Jaroslav Hajek) Date: Fri, 11 Sep 2009 11:17:16 +0200 Subject: new function for quadratic programming: pqpnonneg Message-ID: <69d8d540909110217j423527ebrf6fe14f2b6b321a9@mail.gmail.com> hi all, I just contributed a new function: pqpnonneg (Positive Quadratic Programming in NONNEGative variables). It can be used to solve problems of the form min 1/2*x'*A*x + b'*x, all (x >= 0) where A is a positive definite matrix. The implementation exploits a duality between least squares and positive qp problems; it is very similar to lsqnonneg except that it solves the dual system A \ -b and works with a Cholesky factorization instead of QR (via qrinsert & qrdelete). If applicable, there are two advantages against qp: 1. it is usually significantly faster 2. it will always converge in a finite number of iterations (I think this follows from the Lawson-Hanson proof and the duality) both of these are of course very desirable. Here's a small benchmark creating an artificial problem and solving it via both pqpnonneg and qp: n = 500; ## Generate SPD matrix for i = 1:3 A = rand (n); A = A'*A + 1e-3*eye (n); x = rand (n, 1) - 0.5; b = -(A*x); disp ("pqpnonneg") tic; [x1, obj1] = pqpnonneg (A, b); toc norm (x1 - x) disp ("qp") tic; [x1, obj1] = qp (zeros (n, 1), A, b, [], [], zeros (n, 1), []); toc norm (x1 - x) disp ("--------------------------") endfor On my Core 2 Duo @ 2.83 GHz, g++ -O3 -march=native + serial GotoBLAS, I got: pqpnonneg Elapsed time is 0.00449514 seconds. ans = 6.2362 qp Elapsed time is 1.162 seconds. ans = 6.2362 -------------------------- pqpnonneg Elapsed time is 0.001014 seconds. ans = 6.7428 qp Elapsed time is 1.144 seconds. ans = 6.7428 -------------------------- pqpnonneg Elapsed time is 0.02081 seconds. ans = 6.2335 qp Elapsed time is 32.09 seconds. ans = 6.2335 -------------------------- pqpnonneg Elapsed time is 0.0235 seconds. ans = 6.0290 qp Elapsed time is 35.54 seconds. ans = 6.0290 -------------------------- pqpnonneg Elapsed time is 0.02568 seconds. ans = 6.1129 qp Elapsed time is 37.88 seconds. ans = 6.1129 -------------------------- so, as you can see, pqpnonneg can be many times faster, as much as 1500x in this benchmark. Btw. the reason why this goes into Octave rather than OctaveForge/optim is the duality with lsqnonneg. If ever lsqnonneg is moved to optim, so should pqpnonneg. enjoy! -- RNDr. Jaroslav Hajek computing expert & GNU Octave developer Aeronautical Research and Test Institute (VZLU) Prague, Czech Republic url: www.highegg.matfyz.cz From ct529 at york.ac.uk Fri Sep 11 05:07:25 2009 From: ct529 at york.ac.uk (Corrado) Date: Fri, 11 Sep 2009 11:07:25 +0100 Subject: CUDA in Octave 322 Message-ID: <200909111107.25284.ct529@york.ac.uk> Dear Octave list, is there any support for CUDA in Octave 322? Best, -- Corrado Topi Global Climate Change & Biodiversity Indicators Area 18,Department of Biology University of York, York, YO10 5YW, UK Phone: + 44 (0) 1904 328645, E-mail: ct529 at york.ac.uk From ct529 at york.ac.uk Fri Sep 11 05:11:56 2009 From: ct529 at york.ac.uk (Corrado) Date: Fri, 11 Sep 2009 11:11:56 +0100 Subject: Benchmarking Octave 322 Message-ID: <200909111111.57102.ct529@york.ac.uk> Dear list, I have compiled 322 with and without option -march=native on gcc 4.3.3 on kubuntu64 bit, and I would like to test which is more performant. Is there a standard Octave benchmark I could use? Regards -- Corrado Topi Global Climate Change & Biodiversity Indicators Area 18,Department of Biology University of York, York, YO10 5YW, UK Phone: + 44 (0) 1904 328645, E-mail: ct529 at york.ac.uk From highegg at gmail.com Fri Sep 11 05:17:04 2009 From: highegg at gmail.com (Jaroslav Hajek) Date: Fri, 11 Sep 2009 12:17:04 +0200 Subject: CUDA in Octave 322 In-Reply-To: <200909111107.25284.ct529@york.ac.uk> References: <200909111107.25284.ct529@york.ac.uk> Message-ID: <69d8d540909110317wa6cf48g8e2ed58cf9411ce0@mail.gmail.com> On Fri, Sep 11, 2009 at 12:07 PM, Corrado wrote: > Dear Octave list, > > is there any support for CUDA ?in Octave 322? > > Best, > -- > Corrado Topi > > Global Climate Change & Biodiversity Indicators > Area 18,Department of Biology > University of York, York, YO10 5YW, UK > Phone: + 44 (0) 1904 328645, E-mail: ct529 at york.ac.uk > In short, no. There are codes for Matlab that *might* work with Octave (possibly after modifications). You can, of course, use CUDA in your own C++ extensions, but you can't distribute those, because CUDA is not free software. -- RNDr. Jaroslav Hajek computing expert & GNU Octave developer Aeronautical Research and Test Institute (VZLU) Prague, Czech Republic url: www.highegg.matfyz.cz From highegg at gmail.com Fri Sep 11 05:21:04 2009 From: highegg at gmail.com (Jaroslav Hajek) Date: Fri, 11 Sep 2009 12:21:04 +0200 Subject: Benchmarking Octave 322 In-Reply-To: <200909111111.57102.ct529@york.ac.uk> References: <200909111111.57102.ct529@york.ac.uk> Message-ID: <69d8d540909110321s19e6c6bbg6c9bfcc21370b484@mail.gmail.com> On Fri, Sep 11, 2009 at 12:11 PM, Corrado wrote: > Dear list, > > I have compiled 322 with and without option -march=native on gcc 4.3.3 on > kubuntu64 bit, and I would like to test which is more performant. Is there a > standard Octave benchmark I could use? > > Regards > -- > Corrado Topi > > Global Climate Change & Biodiversity Indicators > Area 18,Department of Biology > University of York, York, YO10 5YW, UK > Phone: + 44 (0) 1904 328645, E-mail: ct529 at york.ac.uk > There is the benchmark package at http://octave.sourceforge.net/benchmark/index.html and also some codes all over the web (mostly sadly out-of-date). You can also invent your own benchmarks; in particular, contributions to the benchmark package will be warmly welcome and coldly scrutinized :). regards -- RNDr. Jaroslav Hajek computing expert & GNU Octave developer Aeronautical Research and Test Institute (VZLU) Prague, Czech Republic url: www.highegg.matfyz.cz From ct529 at york.ac.uk Fri Sep 11 05:32:49 2009 From: ct529 at york.ac.uk (Corrado) Date: Fri, 11 Sep 2009 11:32:49 +0100 Subject: CUDA in Octave 322 In-Reply-To: <69d8d540909110317wa6cf48g8e2ed58cf9411ce0@mail.gmail.com> References: <200909111107.25284.ct529@york.ac.uk> <69d8d540909110317wa6cf48g8e2ed58cf9411ce0@mail.gmail.com> Message-ID: <200909111132.50005.ct529@york.ac.uk> Sorry I had hoped nvidia would have released the driver FS/OS .... :( I definitively do not want to use non FS/OS software .... do you know about the status of OpenCL over Nvidia or ATI? On Friday 11 September 2009 11:17:04 Jaroslav Hajek wrote: > On Fri, Sep 11, 2009 at 12:07 PM, Corrado wrote: > > Dear Octave list, > > > > is there any support for CUDA in Octave 322? > > > > Best, > > -- > > Corrado Topi > > > > Global Climate Change & Biodiversity Indicators > > Area 18,Department of Biology > > University of York, York, YO10 5YW, UK > > Phone: + 44 (0) 1904 328645, E-mail: ct529 at york.ac.uk > > In short, no. There are codes for Matlab that *might* work with Octave > (possibly after modifications). You can, of course, use CUDA in your > own C++ extensions, but you can't distribute those, because CUDA is > not free software. -- Corrado Topi Global Climate Change & Biodiversity Indicators Area 18,Department of Biology University of York, York, YO10 5YW, UK Phone: + 44 (0) 1904 328645, E-mail: ct529 at york.ac.uk From highegg at gmail.com Fri Sep 11 05:37:44 2009 From: highegg at gmail.com (Jaroslav Hajek) Date: Fri, 11 Sep 2009 12:37:44 +0200 Subject: CUDA in Octave 322 In-Reply-To: <200909111132.50005.ct529@york.ac.uk> References: <200909111107.25284.ct529@york.ac.uk> <69d8d540909110317wa6cf48g8e2ed58cf9411ce0@mail.gmail.com> <200909111132.50005.ct529@york.ac.uk> Message-ID: <69d8d540909110337x7d433f4enb10ab03c63ad4f95@mail.gmail.com> On Fri, Sep 11, 2009 at 12:32 PM, Corrado wrote: > Sorry I had hoped nvidia would have released the driver FS/OS .... :( > > I definitively do not want to use non FS/OS software .... do you know about the > status of OpenCL over Nvidia or ATI? > Personally, I'm fairly ignorant about GPGPU, primarily because I have no GPU hardware around. You'll have to investigate yourself. -- RNDr. Jaroslav Hajek computing expert & GNU Octave developer Aeronautical Research and Test Institute (VZLU) Prague, Czech Republic url: www.highegg.matfyz.cz From Potorti at isti.cnr.it Fri Sep 11 06:48:27 2009 From: Potorti at isti.cnr.it (Francesco Potorti`) Date: Fri, 11 Sep 2009 13:48:27 +0200 Subject: Benchmarking Octave 322 In-Reply-To: <69d8d540909110321s19e6c6bbg6c9bfcc21370b484@mail.gmail.com> References: <200909111111.57102.ct529@york.ac.uk> <69d8d540909110321s19e6c6bbg6c9bfcc21370b484@mail.gmail.com> Message-ID: >There is the benchmark package at >http://octave.sourceforge.net/benchmark/index.html > >and also some codes all over the web (mostly sadly out-of-date). In the past I used to maintain a benchmark.m, which is still available at . It still works on Octave 3.2.2 and claims to compute the performance relative to Octave 2 on a Pentium II at 350 MHz with Debian's lapack3 and refblas3 as of November 2005. Its main asset is that it computes a 95% confidence interval for the results, something that as far as I can see is missing from your code. I even used to publish results sent from people on , back when the reference was Sun Sparc, about 100 times slower than the current Pentium II reference. I stopped updating the results when compiling Octave became so much dependent on libraries and compiling options that producing a single number for a given hardware would have been misleading, and maintaining a significant list would have been too complex. I often thought about working to merge it with your code, but never found the time, and I find myself adding things in front of this on my wishlist. So I am writing this mail, in the hope that you, or someone else, possiby with my help, can work towards a better and easy-to-use benchmark. It would also be nice to have a page on the Octave wiki with some performance results. For a reference, here is what I see using my benchmark on an AMD Athlon 64 X2 3800+ running Debian's Octave 3.2.2: octave> benchmark Octave benchmark version bm 2.3 Speed of octave 3.2.2 on x86_64-pc-linux-gnu Pentium II 350 MHz has score 1.0, higher numbers are better Matrix inversion (LAPACK) 9.05 +/- 0.3% (154 runs) Schur decomposition (LAPACK) 23.88 +/- 0.2% (126 runs) Differential equation (LSODE) 22.83 +/- 0.3% (546 runs) Fourier transforms (FFTPACK) 7.43 +/- 0.5% (196 runs) for loop 34.76 +/- 1.0% (658 runs) -- Performance index (bm 2.3): 17 It is surprising to me to see that such a modern processor is less than ten times faster on some tests than a Pentium II! -- Francesco Potort? (ricercatore) Voice: +39 050 315 3058 (op.2111) ISTI - Area della ricerca CNR Fax: +39 050 315 2040 via G. Moruzzi 1, I-56124 Pisa Email: Potorti at isti.cnr.it (entrance 20, 1st floor, room C71) Web: http://fly.isti.cnr.it/ From ilnseher at eit.uni-kl.de Fri Sep 11 07:15:04 2009 From: ilnseher at eit.uni-kl.de (Thomas Ilnseher) Date: Fri, 11 Sep 2009 14:15:04 +0200 Subject: CUDA in Octave 322 In-Reply-To: <69d8d540909110317wa6cf48g8e2ed58cf9411ce0@mail.gmail.com> References: <200909111107.25284.ct529@york.ac.uk> <69d8d540909110317wa6cf48g8e2ed58cf9411ce0@mail.gmail.com> Message-ID: <1252671305.13983.24.camel@pcmik05.zmk.uni-kl.de> Am Freitag, den 11.09.2009, 12:17 +0200 schrieb Jaroslav Hajek: > You can, of course, use CUDA in your > own C++ extensions, but you can't distribute those, because CUDA is > not free software. Ok, I might be wrong here, but AFAIK Octave uses LAPACK. As GPL still allows linking against CS "platform libraries", you can still link Octave against a CS CUDA enabled LAPACK Lib (granted that such a thing exists) when you define LAPACK as a platform library. Same thing as running *ANY* GPL program on Windowze... (it will link against some CS win32 libs dynamically). Same thing as running a GPL prog on Linux w/ NV or AMD binary driver installed. ... And So On (tm). It's the question whether LAPACK is a platform library. IMHO it is (you can substitute ATLAS with IMKL AMD something which are CSd). Now you only need a LAPACK lib that exploits CUDA. Problem here is that you have to copy data to the GPU's memory nad back, call the GPU and so on. This probably gives a reasonable overhead, so you'd only accelerate things this way when operating with *LARGE* vectors / matrices. -- Thomas Ilnseher From sedwards2 at cinci.rr.com Fri Sep 11 07:31:14 2009 From: sedwards2 at cinci.rr.com (Stuart Edwards) Date: Fri, 11 Sep 2009 08:31:14 -0400 Subject: Mac OSX 10.6 and Octave In-Reply-To: <202B0033-5864-4FC4-AD8A-973756E1FFB7@norton.name> References: <202B0033-5864-4FC4-AD8A-973756E1FFB7@norton.name> Message-ID: I was running 3.2.0 when I upgraded to 10.6 and everything still seems to be working fine. Stu On Sep 10, 2009, at 5:29 PM, Vic Norton wrote: > Has anyone been able to successfully install Octave 3.2.2 (or any > earlier version) on the new Mac OSX 10.6 (Snow Leopard) operating > system? I've heard nothing but horror stories so far. I would very > much like to upgrade to Mac OSX 10.6 (which I have purchased), but I > dare not upgrade unless I can install Octave. Mind you, I am an old > (74), unix-un-savvy mathematician; I need a relatively straightforward > installation process. > > By the way, Octave 3.2.2 works perfectly now, on my 2.93 GHz Intel > Core 2 Duo iMac with Mac OSX 10.5.8. As I understand it, Octave 3.2.2 > will stop working as soon as I upgrade to Mac OSX 10.6. Am I wrong > about this? > > Any advice would be greatly appreciated. > > Regards, > > Vic > > _______________________________________________ > Help-octave mailing list > Help-octave at octave.org > https://www-old.cae.wisc.edu/mailman/listinfo/help-octave From highegg at gmail.com Fri Sep 11 07:38:28 2009 From: highegg at gmail.com (Jaroslav Hajek) Date: Fri, 11 Sep 2009 14:38:28 +0200 Subject: Benchmarking Octave 322 In-Reply-To: References: <200909111111.57102.ct529@york.ac.uk> <69d8d540909110321s19e6c6bbg6c9bfcc21370b484@mail.gmail.com> Message-ID: <69d8d540909110538u296bc919neede8a1f9252f927@mail.gmail.com> On Fri, Sep 11, 2009 at 1:48 PM, Francesco Potorti` wrote: >>There is the benchmark package at >>http://octave.sourceforge.net/benchmark/index.html >> >>and also some codes all over the web (mostly sadly out-of-date). > > In the past I used to maintain a benchmark.m, which is still available > at . ?It still > works on Octave 3.2.2 and claims to compute the performance relative to > Octave 2 on a Pentium II at 350 MHz with Debian's lapack3 and refblas3 > as of November 2005. ?Its main asset is that it computes a 95% > confidence interval for the results, something that as far as I can see > is missing from your code. > You're right, that could be of some use. I just added that capability. > I even used to publish results sent from people on > , back when the > reference was Sun Sparc, about 100 times slower than the current Pentium > II reference. ?I stopped updating the results when compiling Octave > became so much dependent on libraries and compiling options that > producing a single number for a given hardware would have been > misleading, and maintaining a significant list would have been too > complex. The mistake is to present it as benchmarking the hardware. It's benchmarking particular installations. Still, comparisons can be very useful. A typical usage is to compare a generic distro package with a custom compilation. > I often thought about working to merge it with your code, but never > found the time, and I find myself adding things in front of this on my > wishlist. ?So I am writing this mail, in the hope that you, or someone > else, possiby with my help, can work towards a better and easy-to-use > benchmark. ?It would also be nice to have a page on the Octave wiki with > some performance results. The package is also low priority for me; besides, it seems almost nobody uses it. The point was to provide a package compatible with older Octaves, even Matlab, so that users can benchmark and share results, and write new benchmarks. Writing a new benchmark is easy: % function benchmark_pinv (m,n) % description: % Benchmarking the pseudoinverse % % arguments: % m = number of rows % n = number of columns % % results: % time_rand = time for pinv of a random m*n matrix % time_diag = time for pinv of a random diagonal m*n matrix % function results = benchmark_pinv (m,n) benchutil_default_arg ('m', 400); benchutil_default_arg ('n', 400); benchutil_initialize (mfilename) a = rand (m, n); tic; pinv (a); time_rand = toc; benchutil_set_result ('time_rand') % Do it in a compatible way. a = diag (rand (max (m, n), 1)); a = a(1:m, 1:n); tic; pinv (a); time_diag = toc; benchutil_set_result ('time_diag') now, just run it in various ways: octave:1> benchmark_pinv Running benchmark: benchmark_pinv Benchmarking the pseudoinverse number of rows (m) = 400 number of columns (n) = 400 time for pinv of a random m*n matrix: 0.561242 time for pinv of a random diagonal m*n matrix: 2.00272e-05 octave:2> benchmark_pinv (600, 300) Running benchmark: benchmark_pinv Benchmarking the pseudoinverse number of rows (m) = 600 number of columns (n) = 300 time for pinv of a random m*n matrix: 0.243105 time for pinv of a random diagonal m*n matrix: 1.40667e-05 octave:3> benchutil_average("benchmark_pinv", 10, 600, 300) Running benchmark: benchmark_pinv Benchmarking the pseudoinverse number of rows (m) = 600 number of columns (n) = 300 time for pinv of a random m*n matrix: 0.237562 time for pinv of a random diagonal m*n matrix: 1.40667e-05 .... time for pinv of a random m*n matrix (avg. over 10 runs): 0.240214 +/- 1.595569% time for pinv of a random diagonal m*n matrix (avg. over 10 runs): 0.000014 +/- 3.743879% The descriptions are auto-extracted from the help string and progress is displayed throughout each run, as well as auto-averaging over multiple runs via benchutil_average. -- RNDr. Jaroslav Hajek computing expert & GNU Octave developer Aeronautical Research and Test Institute (VZLU) Prague, Czech Republic url: www.highegg.matfyz.cz From ct529 at york.ac.uk Fri Sep 11 07:53:32 2009 From: ct529 at york.ac.uk (Corrado) Date: Fri, 11 Sep 2009 13:53:32 +0100 Subject: CUDA in Octave 322 In-Reply-To: <1252671305.13983.24.camel@pcmik05.zmk.uni-kl.de> References: <200909111107.25284.ct529@york.ac.uk> <69d8d540909110317wa6cf48g8e2ed58cf9411ce0@mail.gmail.com> <1252671305.13983.24.camel@pcmik05.zmk.uni-kl.de> Message-ID: <200909111353.32334.ct529@york.ac.uk> On Friday 11 September 2009 13:15:04 Thomas Ilnseher wrote: > Problem here is that you have to copy data to the GPU's memory nad > back, call the GPU and so on. This probably gives a reasonable overhead, > so you'd only accelerate things this way when operating with *LARGE* > vectors / matrices. Yes, this is the situation here (very large matrices). The fact that CUDA is not FS/OS is still a problem though. That was the reason for mentioning OpenCL. Regards -- Corrado Topi Global Climate Change & Biodiversity Indicators Area 18,Department of Biology University of York, York, YO10 5YW, UK Phone: + 44 (0) 1904 328645, E-mail: ct529 at york.ac.uk From highegg at gmail.com Fri Sep 11 07:54:47 2009 From: highegg at gmail.com (Jaroslav Hajek) Date: Fri, 11 Sep 2009 14:54:47 +0200 Subject: CUDA in Octave 322 In-Reply-To: <1252671305.13983.24.camel@pcmik05.zmk.uni-kl.de> References: <200909111107.25284.ct529@york.ac.uk> <69d8d540909110317wa6cf48g8e2ed58cf9411ce0@mail.gmail.com> <1252671305.13983.24.camel@pcmik05.zmk.uni-kl.de> Message-ID: <69d8d540909110554y149f460bs1c2d14425f78aabc@mail.gmail.com> On Fri, Sep 11, 2009 at 2:15 PM, Thomas Ilnseher wrote: > Am Freitag, den 11.09.2009, 12:17 +0200 schrieb Jaroslav Hajek: >> You can, of course, use CUDA in your >> own C++ extensions, but you can't distribute those, because CUDA is >> not free software. > Ok, I might be wrong here, but AFAIK Octave uses LAPACK. > > As GPL still allows linking against CS "platform libraries", you can > still link Octave against a CS CUDA enabled LAPACK Lib (granted that > such a thing exists) when you define LAPACK as a platform library. > > Same thing as running *ANY* GPL program on Windowze... (it will link > against some CS win32 libs dynamically). > > Same thing as running a GPL prog on Linux w/ NV or AMD binary driver > installed. > ... And So On (tm). > > It's the question whether LAPACK is a platform library. IMHO it is (you > can substitute ATLAS with IMKL AMD something which are CSd). > > > Now you only need a LAPACK lib that exploits CUDA. > > Problem here is that you have to ?copy data to the GPU's memory nad > back, call the GPU and so on. This probably gives a reasonable overhead, > so you'd only accelerate things this way when operating with *LARGE* > vectors / matrices. > -- > Thomas Ilnseher > > It seems to me that you are confusing things. You can link Octave to whatever you want to, including arbitrary proprietary libraries. What you typically can't do is to distribute the resulting binaries, if they are derivative works of the non-free library used. Proprietary BLAS/LAPACK implementations certainly do not qualify for the system library exception, but as long as you use dynamic linking and only standard BLAS/LAPACK calls, there is no problem because the binary will work with any BLAS/LAPACK. -- RNDr. Jaroslav Hajek computing expert & GNU Octave developer Aeronautical Research and Test Institute (VZLU) Prague, Czech Republic url: www.highegg.matfyz.cz From romeyke at cbs.mpg.de Fri Sep 11 08:05:18 2009 From: romeyke at cbs.mpg.de (Andreas Romeyke) Date: Fri, 11 Sep 2009 15:05:18 +0200 Subject: CUDA in Octave 322 In-Reply-To: <1252671305.13983.24.camel@pcmik05.zmk.uni-kl.de> References: <200909111107.25284.ct529@york.ac.uk> <69d8d540909110317wa6cf48g8e2ed58cf9411ce0@mail.gmail.com> <1252671305.13983.24.camel@pcmik05.zmk.uni-kl.de> Message-ID: <20090911150518.4bec1b75@linde.cbs.mpg.de> Hello, Am Fri, 11 Sep 2009 14:15:04 +0200 schrieb Thomas Ilnseher : > Problem here is that you have to copy data to the GPU's memory nad > back, call the GPU and so on. This probably gives a reasonable > overhead, so you'd only accelerate things this way when operating > with *LARGE* vectors / matrices. Nope, you would only accelerate things this way when *heavily* operating on vectors/matrices. The bottleneck is the data transfer between GPU and CPU. There are limits in branching, there are limits in jumping or random access the video memory. Bye andreas -- Software Developer / Dipl. Inform. (FH) Max Planck Institute for Human Cognitive and Brain Sciences Department of Psychology Stephanstr. 1a, 04103 Leipzig, Germany -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 197 bytes Desc: not available Url : https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090911/61528433/attachment.bin From dasergatskov at gmail.com Fri Sep 11 08:48:14 2009 From: dasergatskov at gmail.com (Dmitri A. Sergatskov) Date: Fri, 11 Sep 2009 08:48:14 -0500 Subject: Benchmarking Octave 322 In-Reply-To: References: <200909111111.57102.ct529@york.ac.uk> <69d8d540909110321s19e6c6bbg6c9bfcc21370b484@mail.gmail.com> Message-ID: <892b16670909110648w63864372mece42ba6769c2363@mail.gmail.com> On Fri, Sep 11, 2009 at 6:48 AM, Francesco Potorti` wrote: > For a reference, here is what I see using my benchmark on an AMD Athlon > 64 X2 3800+ running Debian's Octave 3.2.2: > > octave> benchmark > Octave benchmark version bm 2.3 > Speed of octave 3.2.2 on x86_64-pc-linux-gnu > ?Pentium II 350 MHz has score 1.0, higher numbers are better > Matrix inversion (LAPACK) ? ? ? ? 9.05 +/- 0.3% (154 runs) > Schur decomposition (LAPACK) ? ? 23.88 +/- 0.2% (126 runs) > Differential equation (LSODE) ? ?22.83 +/- 0.3% (546 runs) > Fourier transforms (FFTPACK) ? ? ?7.43 +/- 0.5% (196 runs) > for loop ? ? ? ? ? ? ? ? ? ? ? ? 34.76 +/- 1.0% (658 runs) > -- Performance index (bm 2.3): 17 > It looks to me your ATLAS is not well optimized. Here is 3.2.2 on Fedora 11 x86_64 (Opteron 180, at 2.4GHz): Matrix inversion (LAPACK) 31.47 +/- 2.6% (539 runs) Schur decomposition (LAPACK) 39.68 +/- 0.1% (238 runs) Differential equation (LSODE) 26.19 +/- 0.6% (623 runs) Fourier transforms (FFTPACK) 7.09 +/- 1.9% (168 runs) for loop 35.66 +/- 1.1% (665 runs) -- Performance index (bm 2.3): 24 > -- > Francesco Potort? (ricercatore) ? ? ? ?Voice: +39 050 315 3058 (op.2111) Dmitri. -- From riccardocorradini at yahoo.it Fri Sep 11 09:16:08 2009 From: riccardocorradini at yahoo.it (Riccardo Corradini) Date: Fri, 11 Sep 2009 14:16:08 +0000 (GMT) Subject: Benchmarking Octave 322 In-Reply-To: <892b16670909110648w63864372mece42ba6769c2363@mail.gmail.com> Message-ID: <289169.10228.qm@web25501.mail.ukl.yahoo.com> I also have better results with custom optimized libraries Speed of octave 3.2.2 on x86_64-unknown-linux-gnu ? Pentium II 350 MHz has score 1.0, higher numbers are better Matrix inversion (LAPACK)??????? 34.47 +/- 21.0% (380 runs) Schur decomposition (LAPACK)???? 29.56 +/- 1.3% (168 runs) Differential equation (LSODE)??? 34.62 +/- 0.4% (819 runs) Fourier transforms (FFTPACK)???? 13.09 +/- 0.2% (343 runs) for loop???????????????????????? 54.78 +/- 0.6% (1008 runs) -- Performance index (bm 2.3): 30 ?cat /proc/cpuinfo processor??? : 0 vendor_id??? : AuthenticAMD cpu family??? : 15 model??? ??? : 107 model name??? : AMD Athlon(tm) 64 X2 Dual Core Processor 5600+ Bests Riccardo --- Ven 11/9/09, Dmitri A. Sergatskov ha scritto: Da: Dmitri A. Sergatskov Oggetto: Re: Benchmarking Octave 322 A: "Francesco Potorti`" Cc: help-octave at octave.org Data: Venerd? 11 settembre 2009, 15:48 On Fri, Sep 11, 2009 at 6:48 AM, Francesco Potorti` wrote: > For a reference, here is what I see using my benchmark on an AMD Athlon > 64 X2 3800+ running Debian's Octave 3.2.2: > > octave> benchmark > Octave benchmark version bm 2.3 > Speed of octave 3.2.2 on x86_64-pc-linux-gnu > ?Pentium II 350 MHz has score 1.0, higher numbers are better > Matrix inversion (LAPACK) ? ? ? ? 9.05 +/- 0.3% (154 runs) > Schur decomposition (LAPACK) ? ? 23.88 +/- 0.2% (126 runs) > Differential equation (LSODE) ? ?22.83 +/- 0.3% (546 runs) > Fourier transforms (FFTPACK) ? ? ?7.43 +/- 0.5% (196 runs) > for loop ? ? ? ? ? ? ? ? ? ? ? ? 34.76 +/- 1.0% (658 runs) > -- Performance index (bm 2.3): 17 > It looks to me your ATLAS is not well optimized. Here is 3.2.2 on Fedora 11 x86_64 (Opteron 180, at 2.4GHz): Matrix inversion (LAPACK)? ? ? ? 31.47 +/- 2.6% (539 runs) Schur decomposition (LAPACK)? ???39.68 +/- 0.1% (238 runs) Differential equation (LSODE)? ? 26.19 +/- 0.6% (623 runs) Fourier transforms (FFTPACK)? ? ? 7.09 +/- 1.9% (168 runs) for loop? ? ? ? ? ? ? ? ? ? ? ???35.66 +/- 1.1% (665 runs) -- Performance index (bm 2.3): 24 > -- > Francesco Potort? (ricercatore) ? ? ? ?Voice: +39 050 315 3058 (op.2111) Dmitri. -- _______________________________________________ Help-octave mailing list Help-octave at octave.org https://www-old.cae.wisc.edu/mailman/listinfo/help-octave -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090911/e8eeac22/attachment.html From Bard.Skaflestad at sintef.no Fri Sep 11 09:04:30 2009 From: Bard.Skaflestad at sintef.no (=?iso-8859-1?Q?B=E5rd_Skaflestad?=) Date: Fri, 11 Sep 2009 16:04:30 +0200 Subject: Using STR2FUNC in sub-function to refer to other sub-function(s) Message-ID: <47AC1666471FFC41873637D50D111B812679568394@SINTEFEXMBX01.sintef.no> All, I'm experiencing a bit of bother using the STR2FUNC function. For sake of argument I'll use the synthetic function 'foo' defined as $ cat foo.m function h = foo() h = @sub1; end function h = sub1() h = str2func('sub2'); end function h = sub2() h = @(x) sub3(x, 10); end function q = sub3(a, b) q = fprintf('sub3: (a,b) = (%f,%d)\n', a, b); end $ In Octave I then get --------------------8<----------------------------------------8<------------------------- octave:29> f = foo(), s1 = f(), s2 = s1(), s3 = s2(pi) f = sub1 error: error creating function handle "@sub2" error: called from: error: /home/bska/tmp/build/octave/3.2.2/foo.m at line 6, column 9 --------------------8<----------------------------------------8<------------------------- while MATLAB yields the, to me, expected output --------------------8<----------------------------------------8<------------------------- >> f = foo(), s1 = f(), s2 = s1(), s3 = s2(pi) f = @sub1 s1 = @sub2 s2 = @(x)sub3(x,10) sub3: (a,b) = (3.141593,10) s3 = 28 --------------------8<----------------------------------------8<------------------------- My question is if this (failing to construct a function handle to 'sub2') is an error in Octave or if Octave's STR2FUNC implementation is not expected to have the ability to construct handles to (other) sub-functions of a "main" function. I should note that if I replace the above 'sub1' function by the (equivalent, in this case) function h = sub1() h = @sub2; end the above error goes away. In the general case, however, I would really like the ability to use STR2FUNC here because the function name is not generally known until runtime in code. Admittedly, my code uses only a bounded set of possible string values (roughly 5-10 alternatives), but I'd rather not insert a big SWITCH statement in there. Any and all suggestions will be greatly appreciated. Best regards, -- B?rd Skaflestad SINTEF ICT, Applied mathematics Forskningsveien 1, No-0314 Oslo Tel.: (+47) 2206 7642 For the record, I have --------------------8<----------------------------------------8<------------------------- octave:26> ver ---------------------------------------------------------------------- GNU Octave Version 3.2.2 GNU Octave License: GNU General Public License Operating System: Linux 2.6.22.14-72.fc6 #1 SMP Wed Nov 21 14:10:25 EST 2007 x86_64 ---------------------------------------------------------------------- no packages installed. octave:27> --------------------8<----------------------------------------8<------------------------- The interpreter is freshly built today (Friday the 11th of September 2009), and configured as --------------------8<----------------------------------------8<------------------------- /home/bska/tmp/downloads/octave-3.2.2/configure --enable-shared --enable-dl --prefix='/home/bska/system/usr/local' --libdir='/home/bska/system/usr/local/lib64' CXX='g++43' CC='gcc43' F77='gfortran43' FC='gfortran43' CPPFLAGS='-I/home/bska/system/usr/local/include -I/home/bska/system/usr/local/include/SuiteSparse' LDFLAGS='-L/home/bska/system/usr/local/lib64 -L/usr/local/lib64 -L/usr/lib64 -L/lib64' LIBS='-lmetis' --------------------8<----------------------------------------8<------------------------- whence 'configure' reports --------------------8<----------------------------------------8<------------------------- Octave is now configured for x86_64-unknown-linux-gnu Source directory: /home/bska/tmp/downloads/octave-3.2.2 Installation prefix: /home/bska/system/usr/local C compiler: gcc43 -Wall -W -Wshadow -Wformat -g -O2 C++ compiler: g++43 -Wall -W -Wshadow -Wold-style-cast -Wformat -g -O2 Fortran compiler: gfortran43 -O Fortran libraries: -L/home/bska/system/usr/local/lib64 -L/usr/local/lib64 -L/usr/lib64 -L/lib64 -L/usr/local/lib/gcc/x86_64-unknown-linux-gnu/4.3.3 -L/usr/local/lib/gcc/x86_64-unknown-linux-gnu/4.3.3/../../../../lib64 - L/lib/../lib64 -L/usr/lib/../lib64 -L/usr/local/lib/gcc/x86_64-unknown-linux-gnu/4.3.3/../../.. -lhdf5 -lz -lgfortranbegin -lgfortran -lm -lmetis BLAS libraries: -llapack -lblas FFTW libraries: -lfftw3 -lfftw3f GLPK libraries: UMFPACK libraries: -lumfpack AMD libraries: -lamd CAMD libraries: -lcamd COLAMD libraries: -lcolamd CCOLAMD libraries: -lccolamd CHOLMOD libraries: -lcholmod CXSPARSE libraries: -lcxsparse ARPACK libraries: -larpack QRUPDATE libraries: -lqrupdate HDF5 libraries: -lhdf5 CURL libraries: REGEX libraries: -L/home/bska/system/usr/local/lib64 -lpcre QHULL libraries: -lqhull OPENGL libraries: FLTK backend libs: X11 include flags: X11 libraries: CARBON libraries: LIBS: -lreadline -lncurses -ldl -lblas -lhdf5 -lz -lm -lmetis Default pager: less gnuplot: gnuplot Magick config: Do internal array bounds checking: false Build static libraries: false Build shared libraries: true Dynamic Linking: true (dlopen) Include support for GNU readline: true 64-bit array dims and indexing: false configure:34470: WARNING: I didn't find gperf, but it's only a problem if you need to reconstruct oct-gperf.h configure:34560: WARNING: GLPK library not found. The glpk function for solving linear programs will be disabled. configure:34566: WARNING: GraphicsMagick++ config script not found. Assuming GraphicsMagic++ library and header files are missing, so imread will not be fully functional configure:34614: WARNING: I didn't find texi2dvi, but it's only a problem if you need to reconstruct the DVI version of the manual configure:34701: WARNING: "FLTK config script not found. Native graphics will be disabled." configure:34717: WARNING: configure:34719: WARNING: I didn't find the necessary libraries to compile native configure:34721: WARNING: graphics. It isn't necessary to have native graphics configure:34723: WARNING: but you will have to use gnuplot or you won't be able configure:34725: WARNING: to use any of Octave's plotting commands configure:34727: WARNING: configure:34737: NOTE: libraries may be skipped if a library is not found OR if the library on your system is missing required features. --------------------8<----------------------------------------8<------------------------- From martin.ecarnot at free.fr Fri Sep 11 07:08:55 2009 From: martin.ecarnot at free.fr (Martin) Date: Fri, 11 Sep 2009 14:08:55 +0200 Subject: Plot - Remove points Message-ID: <1252670935.4aaa3dd7014ef@imp.free.fr> Hi, I'm trying to plot several series of points on a same figure, and be able to remove part of them. I saw Matlab can do it with: h1=plot([1 1]); set(h1,'visible','off'); Is it possible to do something like that with Octave? It seems 'visible' property is only available for a figure object, not for a plot object. Thank you Martin From Pascal.Dupuis at worldonline.be Fri Sep 11 04:55:14 2009 From: Pascal.Dupuis at worldonline.be (Dupuis) Date: Fri, 11 Sep 2009 02:55:14 -0700 (PDT) Subject: non-linear programming - constraints Message-ID: <25398227.post@talk.nabble.com> Hello, I'm trying to solve a non-linear minimisation problems where elements to determine are part of a matrix: M = [a b; b c], with a and c >0. The objective function requires that M be positive definite, i.e. ac - b^2 >=0. I introduced an inequality constraint in sqp, yet during the search in phi_L1, x sometimes is not acceptable with respect to the inequality constraint. Is there a mean to strictly enforce the inequality constraint to be valid ? Another way would be to take beff = sign(b)*(min(abs(b), sqrt(a*c)) but I fear to introduce discontinuities in the inequality function. Any hint ? Regards Pascal -- View this message in context: http://www.nabble.com/non-linear-programming---constraints-tp25398227p25398227.html Sent from the Octave - General mailing list archive at Nabble.com. From Potorti at isti.cnr.it Fri Sep 11 09:59:33 2009 From: Potorti at isti.cnr.it (Francesco Potorti`) Date: Fri, 11 Sep 2009 16:59:33 +0200 Subject: Benchmarking Octave 322 In-Reply-To: <69d8d540909110538u296bc919neede8a1f9252f927@mail.gmail.com> References: <200909111111.57102.ct529@york.ac.uk> <69d8d540909110321s19e6c6bbg6c9bfcc21370b484@mail.gmail.com> <69d8d540909110538u296bc919neede8a1f9252f927@mail.gmail.com> Message-ID: >The package is also low priority for me; besides, it seems almost >nobody uses it. It's not user friendly. While the disadvantege of my old package is that it is not so modular as yours. That is another reason why I always thought about merging. If someone wanted to do that... -- Francesco Potort? (ricercatore) Voice: +39 050 315 3058 (op.2111) ISTI - Area della ricerca CNR Fax: +39 050 315 2040 via G. Moruzzi 1, I-56124 Pisa Email: Potorti at isti.cnr.it (entrance 20, 1st floor, room C71) Web: http://fly.isti.cnr.it/ From bpabbott at mac.com Fri Sep 11 10:29:32 2009 From: bpabbott at mac.com (Ben Abbott) Date: Fri, 11 Sep 2009 11:29:32 -0400 Subject: Plot - Remove points In-Reply-To: <1252670935.4aaa3dd7014ef@imp.free.fr> References: <1252670935.4aaa3dd7014ef@imp.free.fr> Message-ID: <31127779484647633785705558090964518241-Webmail@me.com> On Friday, September 11, 2009, at 08:08AM, "Martin" wrote: >Hi, >I'm trying to plot several series of points on a same figure, and be able to >remove part of them. >I saw Matlab can do it with: >h1=plot([1 1]); >set(h1,'visible','off'); > >Is it possible to do something like that with Octave? >It seems 'visible' property is only available for a figure object, not for a >plot object. > >Thank you > >Martin That works for Octave 3.2.2. If you are running an older version, I recommend an upgrade. Ben From dfslezak at dc.uba.ar Fri Sep 11 10:46:53 2009 From: dfslezak at dc.uba.ar (=?ISO-8859-1?Q?Diego_Fern=E1ndez_Slezak?=) Date: Fri, 11 Sep 2009 11:46:53 -0400 Subject: Adding packages Message-ID: Hello, I have Octave 3.2.2 compiled for BlueGene/P and I want to add a package. As I'm in a cross-compiling scenario I cannot run Octave and the "pkg install ..." I've tried to copy the .m files included in the package to the share/packages directory, and adding the package dir to the path. But it fails because it needs a .oct file. How could I generate that oct in the cross-compiling situation and where do I have to place it? Thanks Diego From ct529 at york.ac.uk Fri Sep 11 11:00:38 2009 From: ct529 at york.ac.uk (Corrado) Date: Fri, 11 Sep 2009 17:00:38 +0100 Subject: Benchmarking Octave 322 In-Reply-To: References: <200909111111.57102.ct529@york.ac.uk> <69d8d540909110538u296bc919neede8a1f9252f927@mail.gmail.com> Message-ID: <200909111700.39331.ct529@york.ac.uk> How is that for a laptop? octave:1> benchmark Octave benchmark version bm 2.3 Speed of octave 3.2.2 on x86_64-unknown-linux-gnu Pentium II 350 MHz has score 1.0, higher numbers are better Matrix inversion (LAPACK) 14.98 +/- 0.1% (252 runs) Schur decomposition (LAPACK) 54.52 +/- 0.4% (322 runs) Differential equation (LSODE) 40.81 +/- 0.2% (980 runs) Fourier transforms (FFTPACK) 23.09 +/- 0.4% (609 runs) for loop 75.20 +/- 3.6% (1365 runs) -- Performance index (bm 2.3): 36 octave:2> I think I could still optimise Matrix inversion though On Friday 11 September 2009 15:59:33 Francesco Potorti` wrote: > >The package is also low priority for me; besides, it seems almost > >nobody uses it. > > It's not user friendly. While the disadvantege of my old package is > that it is not so modular as yours. That is another reason why I always > thought about merging. If someone wanted to do that... -- Corrado Topi Global Climate Change & Biodiversity Indicators Area 18,Department of Biology University of York, York, YO10 5YW, UK Phone: + 44 (0) 1904 328645, E-mail: ct529 at york.ac.uk From rob at jlab.org Fri Sep 11 09:44:13 2009 From: rob at jlab.org (Rob Mahurin) Date: Fri, 11 Sep 2009 10:44:13 -0400 Subject: Plot - Remove points In-Reply-To: <1252670935.4aaa3dd7014ef@imp.free.fr> References: <1252670935.4aaa3dd7014ef@imp.free.fr> Message-ID: <20090911144413.GA18250@dyn21924539.dz.ornl.gov> On Fri, Sep 11, 2009 at 02:08:55PM +0200, Martin wrote: > I'm trying to plot several series of points on a same figure, and be able to > remove part of them. > I saw Matlab can do it with: > h1=plot([1 1]); > set(h1,'visible','off'); > > Is it possible to do something like that with Octave? > It seems 'visible' property is only available for a figure object, not for a > plot object. Your example works for me in Octave 3.2.2. Cheers, Rob From sraevsky at gmail.com Fri Sep 11 12:15:40 2009 From: sraevsky at gmail.com (Scott Raevsky) Date: Fri, 11 Sep 2009 10:15:40 -0700 Subject: freqz plot question Message-ID: Hello, It's been years since I used Matlab, but one thing I remember is freqz plotting the mag and phase response. In octave, freqz plots a pass band, a stop band, and phase. What is the stop band for, and why is it seperate from the pass band? Seems like it should be just mag and phase, where the pass and stop bands are part of the mag plot. Thanks -- Sent from my mobile device From christy1865 at yahoo.com Fri Sep 11 13:19:28 2009 From: christy1865 at yahoo.com (Kristen Richter) Date: Fri, 11 Sep 2009 11:19:28 -0700 (PDT) Subject: avifile (and all that jazz) Message-ID: <887085.21640.qm@web30205.mail.mud.yahoo.com> Dear helpful mailing list, I am attempting to turn a series of plots into an avifile. While I've installed the video add-on package from Octave-forge, I can't add frames to my .avi because the AVHandler can't seem to find the appropriate codecs. Using the example below, found here: http://neacm.fe.up.pt/pub/octave/MAILING-LISTS/help-octave/2005/3694 # Open the AVI file m = avifile("test.avi", "codec", "msmpeg4v2") # Generate and add frames for i = 1:100 I = zeros(100,100); I(i,:) = i; I(:,i) = 200-i; addframe(m, I/255) printf(".") endfor printf("\n") # Close the file clear mI get the following error: AVHandler: cannot find codec msmpeg4v2 error: avifile: AVHandler setup failed addframe: error adding frame to avifile I've tried the example, specifying many different codecs, including cinepak, indeo5, and indeo3. I've checked my synaptic package manager for appropriate codecs... currently I've installed libavifile (vs. 0.7), which mentions the indeo library by name. Are the codecs supposed to be installed in a specific directory? Has anyone come across similar issues in the past? The example is pretty old... dated 2005, and I know the video package was updated last this past May. Any insight on the situation would be greatly appreciated. As always, your help in the past has been invaluable. -Kristen Richter By the way, does anyone know of a good work around for the getframe function?... I have yet to think of a good way to capture the figure on the screen into an appropriately formatted image matrix. From manishdkulkarni at gmail.com Fri Sep 11 15:03:26 2009 From: manishdkulkarni at gmail.com (Manish Kulkarni) Date: Fri, 11 Sep 2009 13:03:26 -0700 Subject: imread error In-Reply-To: <8feb35460909111257nc1a42bx7868a4e430d98481@mail.gmail.com> References: <8feb35460909111257nc1a42bx7868a4e430d98481@mail.gmail.com> Message-ID: <8feb35460909111303g2ce1337ckd0acb2edca24b4c5@mail.gmail.com> On Fri, Sep 11, 2009 at 12:57 PM, Manish Kulkarni wrote: > Dear everyone, > > I'm getting the following error with imread > > > tftimage = imread("Waterfall.jpg"); > error: imread: invalid image file: Magick++ exception: Magick: Unable to > access configuration file (magic.mgk) reported > by > d:/files/admin/octaveforge_svn/trunk/octave-forge/admin/Windows/mingw32/graphicsmagick/GraphicsMagick-1.3.3/magick/bl > ob.c:1824 (GetConfigureBlob) > error: called from: > error: C:\Octave\3.2.0_gcc-4.3.0\share\octave\3.2.0\m\image\imread.m at > line 74, column 7 > octave-3.2.0.exe:12:c:\Users\laptopGuru\Documents\mSilica\tftOctave > > would anyone advise how to fix this? > > Thanks a lot. > Manish > -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090911/709c95ec/attachment.html From wilson.rosa at gmail.com Fri Sep 11 15:56:25 2009 From: wilson.rosa at gmail.com (Wilson de Oliveira) Date: Fri, 11 Sep 2009 17:56:25 -0300 Subject: Netlab on Octave In-Reply-To: <20090911001904.22946.qmail@web3802.mail.bbt.yahoo.co.jp> References: <91e5dab20909100829r19723a32teb8d9f19c151b0f3@mail.gmail.com> <20090911001904.22946.qmail@web3802.mail.bbt.yahoo.co.jp> Message-ID: <91e5dab20909111356r7eaa6b8frea30f79f91b342c1@mail.gmail.com> Tatsuro, great! Thanks for your effort! Much appreciated! After your help with the Octave right version and discovering that the real problem was with the *uicontroI* function which creates user interface control, I went google?ing and found out that the subject of importing gui related MATLAB functions is a trick one; particularly those defining an user interface, making wide use of commands like uicontrol and uimenu. I found the sourceforge project Octawrap which I am about to try which aims at resolving this incompatibility. I am also going to try later the Octave extra package Java Graphic Handles at sourceforge. Many thanks for help and patient. Best regards Wilson de Oliveira UFRPE-DEInfo http://www.cin.ufpe.br/~wrdo 2009/9/10 Tatsuro MATSUOKA > Hello Wilson de Oliveira > > --- Wilson de Oliveira wrote: > > > Ok. Sorry. > > For a start, Netlab is a Matlab toolbox for Pattern Recognition which > > includes amongst others models Neural Networks. It is freely available > at: > > http://www.ncrg.aston.ac.uk/netlab/index.php > > demnlab.m is a demonstration program which runs several models in gui > > interface. > > > > As regard the version of the octave, thanks for your help! The octave > 3.0.0 > > came with qtoctave - a gui interface for octave; Now that I?ve installed > the > > 3.2.2 version available at sourceforge.net I got fewer errors: > > > > > demnlab > > error: `uicontrol' undefined near line 33 column 3 > > error: called from: > > error: C:\Octave\Netlab\demnlab.m at line 33, column 3 > > octave-3.2.2.exe:6:C:\Octave\Netlab > > > > > > > Thanks for your help > > Wilson de Oliveira > > UFRPE-DEInfo > > http://www.cin.ufpe.br/~wrdo > > > > > > Unfortunately Octave does not support GUI graphic control. > You should control graphics with graphic handle functions. > Please see section 15 "Plotting" in octave manual. > You should read care fully "15.1 Plotting Basics" band "15.2 Advanced > Plotting". > Perhaps these types functions are compatible to MATLAB. > > > I have tried a simple example in web page. > > ndata=20 > % Generate the matrix of inputs x and targets t. > x = [0:1/19:1]'; > t = sin(2*pi*x) + 0.2*randn(ndata, 1); > > % Set up network parameters. > net = mlp(1, 3, 1, 'linear') > > net = > { > type = mlp > nin = 1 > nhidden = 3 > nout = 1 > nwts = 10 > outfn = linear > w1 = > > -1.148633 1.104356 0.049478 > > b1 = > > -0.070054 0.902782 1.349561 > > w2 = > > 0.17895 > 0.27658 > 0.36492 > > b2 = 0.66142 > } > **************** > % Set up vector of options for the optimiser. > options = zeros(1,18); > options(1) = 1; > options(9) = 1; > options(14) = 100; > > % Train using scaled conjugate gradients. > [net, options] = netopt(net, options, x, t, 'scg'); > error: `fcnchk' undefined near line 68 column 5 > error: called from: > error: D:\usr\Tatsu\program\Octave\netlab\scg.m at line 68, column 3 > error: D:\usr\Tatsu\program\Octave\netlab\netopt.m at line 36, column 17 > > Octave does not support `fcnchk' > But I found > > http://en.wikibooks.org/wiki/MATLAB_Programming/Differences_between_Octave_and_MATLAB > > ******** > If something (like Netlab) need a function called fcnchk you can just put > the following into a file > called fcnchk.m and put it somewhere Octave can find it: > function f=fcnchk(x, n) > f = x; > end > ******** > I placed fcnchk.m under the same folder of netlab > > SO I get > > Checking gradient ... > > analytic diffs delta > > 1.1904e+000 1.1904e+000 -1.3890e-009 > 4.8963e-001 4.8963e-001 8.2556e-010 > 1.1238e+000 1.1238e+000 -5.8918e-010 > 2.3292e+000 2.3292e+000 -1.3039e-010 > 1.1362e+000 1.1362e+000 -1.2848e-009 > 1.8523e+000 1.8523e+000 6.3412e-010 > -1.3883e+001 -1.3883e+001 -1.9210e-010 > 2.0438e+001 2.0438e+001 5.2320e-010 > 1.9960e+001 1.9960e+001 -9.0928e-011 > 2.2659e+001 2.2659e+001 -8.4377e-010 > Cycle 1 Error 4.629483 Scale 1.000000e+000 > Cycle 2 Error 4.629483 Scale 5.000000e-001 > Cycle 3 Error 4.629483 Scale 2.000000e+000 > Cycle 4 Error 4.259136 Scale 8.000000e+000 > Cycle 5 Error 4.050134 Scale 4.000000e+000 > Cycle 6 Error 3.775366 Scale 2.000000e+000 > Cycle 7 Error 3.390233 Scale 2.000000e+000 > Cycle 8 Error 3.288238 Scale 1.000000e+000 > Cycle 9 Error 3.286530 Scale 5.000000e-001 > Cycle 10 Error 3.235898 Scale 2.500000e-001 > Cycle 11 Error 3.212532 Scale 1.250000e-001 > Cycle 12 Error 3.192542 Scale 6.250000e-002 > Cycle 13 Error 3.187294 Scale 3.125000e-002 > : > : > ***************************************** > % Plot the trained network predictions. > plotvals = [0:0.01:1]'; > y = mlpfwd(net, plotvals); > plot(plotvals, y, 'ob') > > gives a plot like attatchment files. > > ******** > Honestly I am not familiar with this type of work. > In addition, I have no experience of MATLAB > > Hopefully users who use both MATLAB and octave give you much better > suggestions. > > The aboves are all what I can do for you. > > Good luck!! > > Regards > > Tatsuro > > > -------------------------------------- > Thanks 10 years! Yahoo! Shopping and Yahoo! Auctions > http://pr.mail.yahoo.co.jp/ec10years/ > -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090911/0d0199bd/attachment.html From romain.cotte at usherbrooke.ca Fri Sep 11 16:07:51 2009 From: romain.cotte at usherbrooke.ca (R.C.) Date: Fri, 11 Sep 2009 14:07:51 -0700 (PDT) Subject: Wrapper fortran Message-ID: <25408339.post@talk.nabble.com> Hello, I followed example from http://wiki.octave.org/wiki.pl?OctaveFortran but I have some trouble with my fortran subroutine. Compilation works but when i call my function it gives ; [f, xb] = wrapper (2, 4, rand(4,1), 1) *** glibc detected *** octave: free(): invalid next size (fast): 0x09c20450 *** ======= Backtrace: ========= /lib/tls/i686/cmov/libc.so.6[0xb5d31604] /lib/tls/i686/cmov/libc.so.6(cfree+0x96)[0xb5d335b6] /usr/lib/libstdc++.so.6(_ZdlPv+0x21)[0xb5eed231] /usr/lib/libstdc++.so.6(_ZdaPv+0x1d)[0xb5eed28d] /usr/lib/octave-3.0.1/liboctinterp.so(_ZN5ArrayIdED2Ev+0xc6)[0xb7a30c66] etc... My wrapper *********************************************************************************** #include #include "f77-fcn.h" extern "C" { int F77_FUNC (rosenf_b, ROSENF_b) (const int& ind, const int& n, const double* x, double* xb, double& f, const double& fb, double& g, double& ti, double& tr, double& td ); } DEFUN_DLD (wrapper, args, , "- Loadable Function: [f, xb] = wrapper (ind, n, x, fb)\n\ \n\ Returns the f,xb.") { octave_value_list retval; Matrix X; const int IND = args(0).int_value(), N = args(1).int_value(); const double FB; double G; NDArray XB; double F,TI,TR,TD; double *av; FB = args(3).double_value(); X = args(2).matrix_value(); av = XB.fortran_vec(); F77_XFCN (rosenf_b, ROSENF_B, (IND, N, X.fortran_vec(), av, F, FB, G, TI, TR, TD) ); if (f77_exception_encountered) { error ("unrecoverable error in rosenf_b"); return retval; } retval(0) = octave_value (F); retval(1) = octave_value(XB); return retval; } ************************************************************************* Fortran function ************************************************************************ SUBROUTINE ROSENF_B(ind, n, x, xb, f, fb, g, ti, tr, td) IMPLICIT NONE INTEGER ind, n, ti(*) DOUBLE PRECISION x(n), f, g(n), td(*) DOUBLE PRECISION xb(n), fb REAL tr(*) C DOUBLE PRECISION y, p INTEGER i DOUBLE PRECISION tempb INTEGER ii1 p = 100.0d0 IF (ind .EQ. 2 .OR. ind .EQ. 4) THEN DO ii1=1,n xb(ii1) = 0.D0 ENDDO DO i=n,2,-1 tempb = p*2*(x(i)-x(i-1)**2)*fb xb(i) = xb(i) + tempb - 2*(1.0d0-x(i))*fb xb(i-1) = xb(i-1) - 2*x(i-1)*tempb ENDDO fb = 0.D0 ELSE DO ii1=1,n xb(ii1) = 0.D0 ENDDO END IF END ********************************************************************** What do you suggest ? Thanks -- View this message in context: http://www.nabble.com/Wrapper-fortran-tp25408339p25408339.html Sent from the Octave - General mailing list archive at Nabble.com. From manishdkulkarni at gmail.com Fri Sep 11 14:57:11 2009 From: manishdkulkarni at gmail.com (Manish Kulkarni) Date: Fri, 11 Sep 2009 12:57:11 -0700 Subject: imread error Message-ID: <8feb35460909111257nc1a42bx7868a4e430d98481@mail.gmail.com> Dear everyone, I'm getting the following error with imread > tftimage = imread("Waterfall.jpg"); error: imread: invalid image file: Magick++ exception: Magick: Unable to access configuration file (magic.mgk) reported by d:/files/admin/octaveforge_svn/trunk/octave-forge/admin/Windows/mingw32/graphicsmagick/GraphicsMagick-1.3.3/magick/bl ob.c:1824 (GetConfigureBlob) error: called from: error: C:\Octave\3.2.0_gcc-4.3.0\share\octave\3.2.0\m\image\imread.m at line 74, column 7 octave-3.2.0.exe:12:c:\Users\laptopGuru\Documents\mSilica\tftOctave would anyone advise how to fix this? Thanks a lot. Manish -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090911/ae8c30bb/attachment-0001.html From bharat at arithos.com Fri Sep 11 17:23:22 2009 From: bharat at arithos.com (bharat pathak) Date: Sat, 12 Sep 2009 03:53:22 +0530 Subject: freqz plot question References: Message-ID: <4687E502E05B47299150BD8C2426D928@bharatPC> Dear Scott, when we design any digital filter, example low pass, high pass, band pass and band stop. the filter is supposed to pass certain frequencies to the output and stop certain other frequencies. practically we cannot stop the frequencies, we just attenuate them enough such that they do not fall in the dynamic range of the datapath. for example if your datapath is 8 bit (DR = 40 dB) then if you provide 40dB attenuation (1/100 in linear) to incoming signal of full strength then we would not see such signal at the output, provided the output datapath is also having 8 bit precision. hence stop band is the region in frequency domain magnitude response plot where those input signals whose frequency lies in the stop band region would undergo certain attenuation before coming out of the processing module. hope this gives some clarity, Regards Bharat Pathak Arithos Designs www.Arithos.com DSP Design Consultancy and Technical Trainings. -------------------------------------------------- From: "Scott Raevsky" Sent: Friday, September 11, 2009 10:45 PM To: Subject: freqz plot question > Hello, > > It's been years since I used Matlab, but one thing I remember is freqz > plotting the mag and phase response. In octave, freqz plots a pass > band, a stop band, and phase. What is the stop band for, and why is > it seperate from the pass band? Seems like it should be just mag and > phase, where the pass and stop bands are part of the mag plot. > > Thanks > > -- > Sent from my mobile device > _______________________________________________ > Help-octave mailing list > Help-octave at octave.org > https://www-old.cae.wisc.edu/mailman/listinfo/help-octave From sraevsky at gmail.com Fri Sep 11 17:34:51 2009 From: sraevsky at gmail.com (Scott Raevsky) Date: Fri, 11 Sep 2009 15:34:51 -0700 Subject: freqz plot question In-Reply-To: <4687E502E05B47299150BD8C2426D928@bharatPC> References: <4687E502E05B47299150BD8C2426D928@bharatPC> Message-ID: Thanks. I should clarify that I know these concepts well. However, whenever I have seen frequency plots before, they include magnitude and phase--two separate plots. The "pass band" and "stop band" (if they truly exist) are plotted on the magnitude plot. But freqz in octave plots two separate plots for "pass band" and "stop band," which makes no sense to me. Why does it do this? On 9/11/09, bharat pathak wrote: > Dear Scott, > > when we design any digital filter, example low pass, high pass, > band pass and band stop. the filter is supposed to pass certain > frequencies to the output and stop certain other frequencies. > > practically we cannot stop the frequencies, we just attenuate > them enough such that they do not fall in the dynamic range > of the datapath. for example if your datapath is 8 bit (DR = 40 dB) > then if you provide 40dB attenuation (1/100 in linear) to incoming > signal of full strength then we would not see such signal at the > output, provided the output datapath is also having 8 bit precision. > > hence stop band is the region in frequency domain magnitude response > plot where those input signals whose frequency lies in the stop band > region would undergo certain attenuation before coming out of the > processing module. > > hope this gives some clarity, > > Regards > Bharat Pathak > > Arithos Designs > www.Arithos.com > > DSP Design Consultancy and Technical Trainings. > > -------------------------------------------------- > From: "Scott Raevsky" > Sent: Friday, September 11, 2009 10:45 PM > To: > Subject: freqz plot question > >> Hello, >> >> It's been years since I used Matlab, but one thing I remember is freqz >> plotting the mag and phase response. In octave, freqz plots a pass >> band, a stop band, and phase. What is the stop band for, and why is >> it seperate from the pass band? Seems like it should be just mag and >> phase, where the pass and stop bands are part of the mag plot. >> >> Thanks >> >> -- >> Sent from my mobile device >> _______________________________________________ >> Help-octave mailing list >> Help-octave at octave.org >> https://www-old.cae.wisc.edu/mailman/listinfo/help-octave > -- Sent from my mobile device From tmacchant at yahoo.co.jp Fri Sep 11 18:02:33 2009 From: tmacchant at yahoo.co.jp (Tatsuro MATSUOKA) Date: Sat, 12 Sep 2009 08:02:33 +0900 (JST) Subject: Netlab on Octave In-Reply-To: <91e5dab20909111356r7eaa6b8frea30f79f91b342c1@mail.gmail.com> Message-ID: <20090911230233.44339.qmail@web3815.mail.bbt.yahoo.co.jp> Hello --- Wilson de Oliveira wrote: > I am also going to try later the Octave extra > package Java > Graphic Handles at > sourceforge. If you try to install jhandle, please see suggestions by Michael: http://www.nabble.com/Octave-3.2.0-mingw-jhandles-td24024734.html Regards Tatsuro -------------------------------------- Thanks 10 years! Yahoo! Shopping and Yahoo! Auctions http://pr.mail.yahoo.co.jp/ec10years/ From hinow at uwm.edu Fri Sep 11 18:11:59 2009 From: hinow at uwm.edu (Peter Hinow) Date: Fri, 11 Sep 2009 18:11:59 -0500 (CDT) Subject: error with my octave installation? In-Reply-To: <896547768.6004571252710623182.JavaMail.root@mail02.pantherlink.uwm.edu> Message-ID: <1193948361.6004791252710719677.JavaMail.root@mail02.pantherlink.uwm.edu> Hello all, as I'm totally new to octave, I don't know yet how to report a problem or how to diagnose one. I did not install octave 3.0.1 explicitly, it came with the installation of Ubuntu 9.04 from a live CD. Then I encountered a problem using the pdist.m function. I got pdist.m and squareform.m from http://octave.sourceforge.net/doc/funref_statistics.html The following set of commands works just fine a=rand(257,3); d1=squareform(pdist(a,"euclidean")); However, increasing the size of the data by one a=rand(258,3); d1=squareform(pdist(a,"euclidean")); gives a large number of error messages that are all error: called from `nchoosek' in file `/usr/share/octave/3.0.1/m/specfun/nchoosek.m' error: evaluating assignment expression near line 79, column 7 error: evaluating if command near line 69, column 3 How do I check whether my octave installation is correct? Thank you and best regards, Peter From rabuter at eso.org Sat Sep 12 06:07:18 2009 From: rabuter at eso.org (Roberto Abuter) Date: Sat, 12 Sep 2009 13:07:18 +0200 Subject: interp1 - bug Message-ID: <4AAB80E6.7040106@eso.org> Hi : I am using the most basic form of interp1 in both matlab and octave. To my surprise interp1 in octave (3.0.2) is producing some very strange results on my data. I have a set of two vectors X, Y where X has a sawtooth shape (4 repetitions) and Y has 4 repetitions of an increasing/decreasing amplitude sine wave. to start very simple I just check the interp1 engine by making : XI = X; YI = interp1(X,Y,XI) to my surprise, the result YI comes out not identical to Y . well, if I try to interp1 with XI as my target grid ( a regular one ) I get absolutely wierd results. hope someone can give me a hint. many thanks in advance, Roberto Abuter VLTI project- E.S.O ( Europeam Southern Observatory) From jwe at octave.org Sat Sep 12 06:12:12 2009 From: jwe at octave.org (John W. Eaton) Date: Sat, 12 Sep 2009 07:12:12 -0400 Subject: interp1 - bug In-Reply-To: <4AAB80E6.7040106@eso.org> References: <4AAB80E6.7040106@eso.org> Message-ID: <19115.33292.209692.398085@segfault.lan> On 12-Sep-2009, Roberto Abuter wrote: | I am using the most basic form of interp1 in both matlab and octave. | To my surprise interp1 in octave (3.0.2) is producing some very | strange results on my data. | | I have a set of two vectors X, Y where X has a sawtooth shape (4 | repetitions) and Y has 4 repetitions of an increasing/decreasing | amplitude sine wave. | to start very simple I just check the interp1 engine by making : | | XI = X; | YI = interp1(X,Y,XI) | | | to my surprise, the result YI comes out not identical to Y . | | well, if I try to interp1 with XI as my target grid ( a regular one | ) I get absolutely wierd results. | | hope someone can give me a hint. Is X monotonically increasing (or decreasing)? From your description it sounds like it is not. If you think you've found a bug, then please include enough information so that someone can reproduce precisely what you are doing and report it to bug at octave.org. In any case, there is no need to cross post to both the bug and help lists. jwe From rabuter at eso.org Sat Sep 12 06:41:37 2009 From: rabuter at eso.org (Roberto Abuter) Date: Sat, 12 Sep 2009 13:41:37 +0200 Subject: interp1 - bug In-Reply-To: <19115.33292.209692.398085@segfault.lan> References: <4AAB80E6.7040106@eso.org> <19115.33292.209692.398085@segfault.lan> Message-ID: <4AAB88F1.8040608@eso.org> I am sorry for the double posting, I am very new to this list. Indeed, X is not monotonically increasing and I now see in the Octave function description that X has to be monotonic. Sorry for missing that ! I guess it is just a difference in behavior between Matlab and Octave. one can always reshuffle (X,Y) in such a way X becames monotonic. many thanks again, Roberto AButer John W. Eaton wrote: >On 12-Sep-2009, Roberto Abuter wrote: > >| I am using the most basic form of interp1 in both matlab and octave. >| To my surprise interp1 in octave (3.0.2) is producing some very >| strange results on my data. >| >| I have a set of two vectors X, Y where X has a sawtooth shape (4 >| repetitions) and Y has 4 repetitions of an increasing/decreasing >| amplitude sine wave. >| to start very simple I just check the interp1 engine by making : >| >| XI = X; >| YI = interp1(X,Y,XI) >| >| >| to my surprise, the result YI comes out not identical to Y . >| >| well, if I try to interp1 with XI as my target grid ( a regular one >| ) I get absolutely wierd results. >| >| hope someone can give me a hint. > >Is X monotonically increasing (or decreasing)? From your description >it sounds like it is not. > >If you think you've found a bug, then please include enough >information so that someone can reproduce precisely what you are >doing and report it to bug at octave.org. > >In any case, there is no need to cross post to both the bug and help >lists. > >jwe > > From soren at hauberg.org Sat Sep 12 06:48:28 2009 From: soren at hauberg.org (=?ISO-8859-1?Q?S=F8ren?= Hauberg) Date: Sat, 12 Sep 2009 13:48:28 +0200 Subject: interp1 - bug In-Reply-To: <4AAB88F1.8040608@eso.org> References: <4AAB80E6.7040106@eso.org> <19115.33292.209692.398085@segfault.lan> <4AAB88F1.8040608@eso.org> Message-ID: <1252756108.4464.62.camel@sh-t400> l?r, 12 09 2009 kl. 13:41 +0200, skrev Roberto Abuter: > I guess it is just a difference in behavior between Matlab and Octave. > one can always reshuffle (X,Y) in such a way X becames monotonic. Is there any particular reason why we are not doing this in 'interp1'? Couldn't just add [x, idx] = sort (x); y = y (idx); to 'interp1' ? S?ren From jwe at octave.org Sat Sep 12 07:04:07 2009 From: jwe at octave.org (John W. Eaton) Date: Sat, 12 Sep 2009 08:04:07 -0400 Subject: interp1 - bug In-Reply-To: <1252756108.4464.62.camel@sh-t400> References: <4AAB80E6.7040106@eso.org> <19115.33292.209692.398085@segfault.lan> <4AAB88F1.8040608@eso.org> <1252756108.4464.62.camel@sh-t400> Message-ID: <19115.36407.147312.466204@segfault.lan> On 12-Sep-2009, S?ren Hauberg wrote: | l?r, 12 09 2009 kl. 13:41 +0200, skrev Roberto Abuter: | > I guess it is just a difference in behavior between Matlab and Octave. | > one can always reshuffle (X,Y) in such a way X becames monotonic. | | Is there any particular reason why we are not doing this in 'interp1'? | Couldn't just add | | [x, idx] = sort (x); | y = y (idx); | | to 'interp1' ? Suppose I have a set of points that approximate a circle: theta = 0:0.2:2*pi; x = cos(theta); y = sin(theta); plot (x, y); and I want to interpolate between two of these points. If I leave the points ordered as they are, I need to pick a range where the interpolation will make sense. If I just blindly sort the X and Y values, I get something that doesn't look a lot like a circle, so interpolating between two of the points is not likely to give me the result I'm looking for: [x, idx] = sort (x); y = y (idx); plot (x, y); jwe From soren at hauberg.org Sat Sep 12 07:15:48 2009 From: soren at hauberg.org (=?ISO-8859-1?Q?S=F8ren?= Hauberg) Date: Sat, 12 Sep 2009 14:15:48 +0200 Subject: interp1 - bug In-Reply-To: <19115.36407.147312.466204@segfault.lan> References: <4AAB80E6.7040106@eso.org> <19115.33292.209692.398085@segfault.lan> <4AAB88F1.8040608@eso.org> <1252756108.4464.62.camel@sh-t400> <19115.36407.147312.466204@segfault.lan> Message-ID: <1252757748.4464.63.camel@sh-t400> l?r, 12 09 2009 kl. 08:04 -0400, skrev John W. Eaton: > Suppose I have a set of points that approximate a circle: > > theta = 0:0.2:2*pi; > x = cos(theta); > y = sin(theta); > plot (x, y); > > and I want to interpolate between two of these points. If I leave the > points ordered as they are, I need to pick a range where the > interpolation will make sense. If I just blindly sort the X and Y > values, I get something that doesn't look a lot like a circle, so > interpolating between two of the points is not likely to give me the > result I'm looking for: > > [x, idx] = sort (x); > y = y (idx); > plot (x, y); Good point! I was only considering surjective data. Thanks S?ren From highegg at gmail.com Sat Sep 12 14:33:06 2009 From: highegg at gmail.com (Jaroslav Hajek) Date: Sat, 12 Sep 2009 21:33:06 +0200 Subject: interp1 - bug In-Reply-To: <1252756108.4464.62.camel@sh-t400> References: <4AAB80E6.7040106@eso.org> <19115.33292.209692.398085@segfault.lan> <4AAB88F1.8040608@eso.org> <1252756108.4464.62.camel@sh-t400> Message-ID: <69d8d540909121233n58d58248o9f871d7a814a8c0@mail.gmail.com> On Sat, Sep 12, 2009 at 1:48 PM, S?ren Hauberg wrote: > l?r, 12 09 2009 kl. 13:41 +0200, skrev Roberto Abuter: >> I guess it is just a difference in behavior between Matlab and Octave. >> one can always reshuffle (X,Y) in such a way X becames monotonic. > > Is there any particular reason why we are not doing this in 'interp1'? > Couldn't just add > > ?[x, idx] = sort (x); > ?y = y (idx); > > to 'interp1' ? > > S?ren > Another reason is performance. At least for the default linear interpolation, interpolating a single point in a table of length N costs O(log(N)). By always first sorting the table you would degrade that to O(N). This is precisely why for a binary search, you normally "trust" the table to be sorted - checking for that would often defeat the purpose of binary search in the first place (not always, but often). -- RNDr. Jaroslav Hajek computing expert & GNU Octave developer Aeronautical Research and Test Institute (VZLU) Prague, Czech Republic url: www.highegg.matfyz.cz From smpearson at hotmail.com Sat Sep 12 15:08:23 2009 From: smpearson at hotmail.com (mark8) Date: Sat, 12 Sep 2009 13:08:23 -0700 (PDT) Subject: Statically linking Octave to C++ program Message-ID: <25417085.post@talk.nabble.com> Hi, I need to statically link the Octave library within a C++ program so that it can be used on a distributed grid. For other libraries, I have made symlinks with altered names to the static library (such as libgsl-s.a for the gsl library) in the same library directory, and then compile with, for example, -lgsl-s. This works fine for any other library except Octave. With Octave, I can #include and of course it links in fine so long as I don't call any octave functions. As soon as I try to declare an octave object (such as Matrix m(2,2);), I get hundreds of lines of "undefined symbols" followed by ld: symbol(s) not found Right now, I'm working with not much more than a "Hello World" program. It is fine if I use -loctave but not if I use -loctave-s where liboctave-s.a is a symlink to liboctave.a. I've also tried to use the -static compiler flag I do have the static libraries octave-3.2.2/liboctave.a (and libcruft.a and liboctinterp.a) Other details: I'm using octave 3.2.2 on Mac OSX 10.5 Octave obtained via macports (but I've also built it myself with no differences) Compiler: gcc 4.0.1 (but other versions give the same result) Is it possible to do this static linking? If so, can anyone suggest how? Thank you very much, Mark -- View this message in context: http://www.nabble.com/Statically-linking-Octave-to-C%2B%2B-program-tp25417085p25417085.html Sent from the Octave - General mailing list archive at Nabble.com. From Scott.Raevsky at kmob.com Sat Sep 12 15:03:23 2009 From: Scott.Raevsky at kmob.com (Scott.Raevsky) Date: Sat, 12 Sep 2009 13:03:23 -0700 Subject: freqz question (clarified) Message-ID: <8A83011125D82746BD74D09F439F4E2016AEE15F@oc-exchange-3.kmob.com> Hello, Just to clarify my previous question, Matlab's output of freqz is as follows: freqz(b,a,...) plots the magnitude and unwrapped phase of the frequency response of the filter. The plot is displayed in the current figure window. Why does Octave's freqz not plot magnitude and phase? Instead it plots 1) pass band, 2) stop band, and 3) phase. Plotting a separate pass band and stop band doesn't make sense to me. Thanks MAIL.KMOB.COM made the following annotations --------------------------------------------------------------------- PRIVILEGED AND CONFIDENTIAL COMMUNICATION This electronic transmission, and any documents attached hereto, may contain confidential and/or legally privileged information. The information is intended only for use by the recipient named above. If you have received this electronic message in error, please notify the sender and delete the electronic message. Any disclosure, copying, distribution, or use of the contents of information received in error is strictly prohibited. --------------------------------------------------------------------- -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090912/4c2ea81c/attachment.html From smpearson at hotmail.com Sat Sep 12 13:40:13 2009 From: smpearson at hotmail.com (mark8) Date: Sat, 12 Sep 2009 11:40:13 -0700 (PDT) Subject: Statically linking Octave to C++ program Message-ID: <25417085.post@talk.nabble.com> Hi, I need to statically link the Octave library within a C++ program so that it can be used on a distributed grid. For other libraries, I have made symlinks with altered names to the static library (such as libgsl-s.a for the gsl library) in the same library directory, and then compile with, for example, -lgsl-s. This works fine for any other library except Octave. With Octave, I can #include and of course it links in fine so long as I don't call any octave functions. As soon as I try to declare an octave object (such as Matrix m(2,2);), I get hundreds of lines of "undefined symbols" followed by ld: symbol(s) not found Right now, I'm working with not much more than a "Hello World" program. It is fine if I use -loctave but not if I use -loctave-s where liboctave-s.a is a symlink to liboctave.a. I've also tried to use the -static compiler flag I do have the static libraries octave-3.2.2/liboctave.a (and libcruft.a and liboctinterp.a) Other details: I'm using octave 3.2.2 on Mac OSX 10.5 Octave obtained via macports (but I've also built it myself with no differences) Compiler: gcc 4.0.1 (but other versions give the same result) Is it possible to do this static linking? If so, can anyone suggest how? Thank you very much, Mark -- View this message in context: http://www.nabble.com/Statically-linking-Octave-to-C%2B%2B-program-tp25417085p25417085.html Sent from the Octave - General mailing list archive at Nabble.com. From dbateman at dbateman.org Sat Sep 12 16:24:26 2009 From: dbateman at dbateman.org (David Bateman) Date: Sat, 12 Sep 2009 23:24:26 +0200 Subject: Statically linking Octave to C++ program In-Reply-To: <25417085.post@talk.nabble.com> References: <25417085.post@talk.nabble.com> Message-ID: <4AAC118A.9030403@dbateman.org> mark8 wrote: > Hi, > I need to statically link the Octave library within a C++ program so that it > can be used on a distributed grid. For other libraries, I have made symlinks > with altered names to the static library (such as libgsl-s.a for the gsl > library) in the same library directory, and then compile with, for example, > -lgsl-s. > > This works fine for any other library except Octave. With Octave, I can > #include and of course it links in fine so long as I don't > call any octave functions. As soon as I try to declare an octave object > (such as Matrix m(2,2);), I get hundreds of lines of "undefined symbols" > followed by > ld: symbol(s) not found > > Right now, I'm working with not much more than a "Hello World" program. It > is fine if I use -loctave but not if I use -loctave-s where liboctave-s.a is > a symlink to liboctave.a. > I've also tried to use the -static compiler flag > I do have the static libraries octave-3.2.2/liboctave.a (and libcruft.a and > liboctinterp.a) > > Other details: > I'm using octave 3.2.2 on Mac OSX 10.5 > Octave obtained via macports (but I've also built it myself with no > differences) > Compiler: gcc 4.0.1 (but other versions give the same result) > > Is it possible to do this static linking? If so, can anyone suggest how? > Thank you very much, > Mark > > > Try the "-static" flag to the octave configuration script.. The reason for your issues is that the octave oct-files are essentially libraries and these need to be linked in as well. Note that any octave-forge or home built oct-file that you will want to use will also have to be linked in... This gets messy pretty quickly D. From smpearson at hotmail.com Sat Sep 12 17:02:13 2009 From: smpearson at hotmail.com (mark8) Date: Sat, 12 Sep 2009 15:02:13 -0700 (PDT) Subject: Statically linking Octave to C++ program In-Reply-To: <4AAC118A.9030403@dbateman.org> References: <25417085.post@talk.nabble.com> <4AAC118A.9030403@dbateman.org> Message-ID: <25418627.post@talk.nabble.com> dbateman wrote: > > mark8 wrote: >> Hi, >> I need to statically link the Octave library within a C++ program so that >> it >> can be used on a distributed grid. For other libraries, I have made >> symlinks >> with altered names to the static library (such as libgsl-s.a for the gsl >> library) in the same library directory, and then compile with, for >> example, >> -lgsl-s. >> >> This works fine for any other library except Octave. With Octave, I can >> #include and of course it links in fine so long as I don't >> call any octave functions. As soon as I try to declare an octave object >> (such as Matrix m(2,2);), I get hundreds of lines of "undefined symbols" >> followed by >> ld: symbol(s) not found >> >> Right now, I'm working with not much more than a "Hello World" program. >> It >> is fine if I use -loctave but not if I use -loctave-s where liboctave-s.a >> is >> a symlink to liboctave.a. >> I've also tried to use the -static compiler flag >> I do have the static libraries octave-3.2.2/liboctave.a (and libcruft.a >> and >> liboctinterp.a) >> >> Other details: >> I'm using octave 3.2.2 on Mac OSX 10.5 >> Octave obtained via macports (but I've also built it myself with no >> differences) >> Compiler: gcc 4.0.1 (but other versions give the same result) >> >> Is it possible to do this static linking? If so, can anyone suggest how? >> Thank you very much, >> Mark >> >> >> > Try the "-static" flag to the octave configuration script.. The reason > for your issues is that the octave oct-files are essentially libraries > and these need to be linked in as well. Note that any octave-forge or > home built oct-file that you will want to use will also have to be > linked in... This gets messy pretty quickly > > D. > > > Do you mean: ./configure --enable-static Doesn't the fact that I have the libraries liboctave.a etc. suggest that was done already? Or do you mean adding the --static flag to the Makefile? If so, where? I tried adding it to the 'all' target so that it reads: all: header-msg config-check $(MAKE) -f octMakefile all but make complained. -- View this message in context: http://www.nabble.com/Statically-linking-Octave-to-C%2B%2B-program-tp25417085p25418627.html Sent from the Octave - General mailing list archive at Nabble.com. From smpearson at hotmail.com Sat Sep 12 22:21:06 2009 From: smpearson at hotmail.com (mark8) Date: Sat, 12 Sep 2009 20:21:06 -0700 (PDT) Subject: Statically linking Octave to C++ program In-Reply-To: <25418627.post@talk.nabble.com> References: <25417085.post@talk.nabble.com> <4AAC118A.9030403@dbateman.org> <25418627.post@talk.nabble.com> Message-ID: <25420243.post@talk.nabble.com> mark8 wrote: > > > Do you mean: > ./configure --enable-static > Doesn't the fact that I have the libraries liboctave.a etc. suggest that > was done already? > > Or do you mean adding the --static flag to the Makefile? If so, where? I > tried adding it to the 'all' target so that it reads: > all: header-msg config-check > $(MAKE) -f octMakefile all > but make complained. > For what it's worth, I just tried ./configure --enable-static which produced liboctave.a. However, if I run ranlib liboctave.a, I get: > ranlib liboctave.a ranlib: file: liboctave.a(oct-fftw.o) has no symbols ranlib: file: liboctave.a(f2c-main.o) has no symbols ranlib: file: liboctave.a(mkdir.o) has no symbols ranlib: file: liboctave.a(rename.o) has no symbols ranlib: file: liboctave.a(rmdir.o) has no symbols ranlib: file: liboctave.a(strftime.o) has no symbols ranlib: file: liboctave.a(strptime.o) has no symbols ranlib: file: liboctave.a(strcasecmp.o) has no symbols ranlib: file: liboctave.a(strncase.o) has no symbols ranlib: file: liboctave.a(tempname.o) has no symbols ranlib: file: liboctave.a(tempnam.o) has no symbols ranlib: file: liboctave.a(oct-rl-edit.o) has no symbols ranlib: file: liboctave.a(oct-rl-hist.o) has no symbols feeling stumped... -- View this message in context: http://www.nabble.com/Statically-linking-Octave-to-C%2B%2B-program-tp25417085p25420243.html Sent from the Octave - General mailing list archive at Nabble.com. From dbateman at dbateman.org Sun Sep 13 04:55:07 2009 From: dbateman at dbateman.org (David Bateman) Date: Sun, 13 Sep 2009 11:55:07 +0200 Subject: Statically linking Octave to C++ program In-Reply-To: <25418627.post@talk.nabble.com> References: <25417085.post@talk.nabble.com> <4AAC118A.9030403@dbateman.org> <25418627.post@talk.nabble.com> Message-ID: <4AACC17B.3050708@dbateman.org> mark8 wrote: > > Do you mean: > ./configure --enable-static > Doesn't the fact that I have the libraries liboctave.a etc. suggest that was > done already? > > yes. You might need --disable-shared as well D. From dbateman at dbateman.org Sun Sep 13 04:56:10 2009 From: dbateman at dbateman.org (David Bateman) Date: Sun, 13 Sep 2009 11:56:10 +0200 Subject: Statically linking Octave to C++ program In-Reply-To: <25420243.post@talk.nabble.com> References: <25417085.post@talk.nabble.com> <4AAC118A.9030403@dbateman.org> <25418627.post@talk.nabble.com> <25420243.post@talk.nabble.com> Message-ID: <4AACC1BA.8050908@dbateman.org> mark8 wrote: > > mark8 wrote: > >> Do you mean: >> ./configure --enable-static >> Doesn't the fact that I have the libraries liboctave.a etc. suggest that >> was done already? >> >> Or do you mean adding the --static flag to the Makefile? If so, where? I >> tried adding it to the 'all' target so that it reads: >> all: header-msg config-check >> $(MAKE) -f octMakefile all >> but make complained. >> >> > > For what it's worth, I just tried > ./configure --enable-static > which produced liboctave.a. However, if I run ranlib liboctave.a, I get: > >> ranlib liboctave.a >> > ranlib: file: liboctave.a(oct-fftw.o) has no symbols > ranlib: file: liboctave.a(f2c-main.o) has no symbols > ranlib: file: liboctave.a(mkdir.o) has no symbols > ranlib: file: liboctave.a(rename.o) has no symbols > ranlib: file: liboctave.a(rmdir.o) has no symbols > ranlib: file: liboctave.a(strftime.o) has no symbols > ranlib: file: liboctave.a(strptime.o) has no symbols > ranlib: file: liboctave.a(strcasecmp.o) has no symbols > ranlib: file: liboctave.a(strncase.o) has no symbols > ranlib: file: liboctave.a(tempname.o) has no symbols > ranlib: file: liboctave.a(tempnam.o) has no symbols > ranlib: file: liboctave.a(oct-rl-edit.o) has no symbols > ranlib: file: liboctave.a(oct-rl-hist.o) has no symbols > > feeling stumped... > > Is that really a problem.. Does the statically build octave run? D. From johny1888 at gmail.com Sun Sep 13 05:59:30 2009 From: johny1888 at gmail.com (johny gaddar) Date: Sun, 13 Sep 2009 16:29:30 +0530 Subject: Help-octave Digest, Vol 42, Issue 28 In-Reply-To: References: Message-ID: Hello i am new user to octave i have a c program whose output which is two colums of data should be plotted by octave as X and Y i am using red hat machine. any suggestions are appreciated. regards Johny -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090913/b2eb0717/attachment.html From lindnerben at gmx.net Sun Sep 13 05:39:29 2009 From: lindnerben at gmx.net (Benjamin Lindner) Date: Sun, 13 Sep 2009 12:39:29 +0200 Subject: imread error In-Reply-To: <8feb35460909111257nc1a42bx7868a4e430d98481@mail.gmail.com> References: <8feb35460909111257nc1a42bx7868a4e430d98481@mail.gmail.com> Message-ID: <4AACCBE1.8050201@gmx.net> Manish Kulkarni wrote: > Dear everyone, > > I'm getting the following error with imread > > > tftimage = imread("Waterfall.jpg"); > error: imread: invalid image file: Magick++ exception: Magick: Unable to > access configuration file (magic.mgk) reported > by > d:/files/admin/octaveforge_svn/trunk/octave-forge/admin/Windows/mingw32/graphicsmagick/GraphicsMagick-1.3.3/magick/bl > ob.c:1824 (GetConfigureBlob) > error: called from: > error: C:\Octave\3.2.0_gcc-4.3.0\share\octave\3.2.0\m\image\imread.m > at line 74, column 7 > octave-3.2.0.exe:12:c:\Users\laptopGuru\Documents\mSilica\tftOctave > > would anyone advise how to fix this? > Update to the 3.2.2 binary. This issue has been fixed there. benjamin From rob.webinator at gmail.com Sun Sep 13 07:04:35 2009 From: rob.webinator at gmail.com (Rob Redmon) Date: Sun, 13 Sep 2009 08:04:35 -0400 Subject: Trouble installing Symbolic package, GiNaC, etc Message-ID: <5514c9050909130504m307f8806sbccfc4e5fd5a085e@mail.gmail.com> I'm getting these errors when trying to install the symbolic package: octave-3.2.2:1> pkg install symbolic-1.0.9.tar.gz symbols.cc:37:25: error: ginac/ginac.h: No such file or directory My computer: OS X, 10.5.8 I did this: 1) Downloaded and installed prebuilt Octave binary 3.2.2 for OS X from http://octave.sourceforge.net 2) Realized I need the Symbolic library. 3) Installed GiNaC from MacPorts: sudo port install ginac ---> Fetching gmp ---> Attempting to fetch gmp-4.2.4.tar.bz2 from http://mirrors.ibiblio.org/pub/mirrors/gnu/ftp/gnu/gmp ---> Verifying checksum(s) for gmp ---> Extracting gmp ---> Configuring gmp ---> Building gmp ---> Staging gmp into destroot ---> Installing gmp @4.2.4_3 ---> Activating gmp @4.2.4_3 ---> Cleaning gmp ---> Fetching cln ---> Attempting to fetch cln-1.2.2.tar.bz2 from http://distfiles.macports.org/cln ---> Verifying checksum(s) for cln ---> Extracting cln ---> Configuring cln ---> Building cln ---> Staging cln into destroot ---> Installing cln @1.2.2_0+test ---> Activating cln @1.2.2_0+test ---> Cleaning cln ---> Fetching GiNaC ---> Attempting to fetch ginac-1.4.4.tar.bz2 from http://distfiles.macports.org/GiNaC ---> Verifying checksum(s) for GiNaC ---> Extracting GiNaC ---> Configuring GiNaC ---> Building GiNaC ---> Staging GiNaC into destroot ---> Installing GiNaC @1.4.4_0+test ---> Activating GiNaC @1.4.4_0+test ---> Cleaning GiNaC 4) Tried to install the symbolic library: octave-3.2.2:1> pkg install symbolic-1.0.9.tar.gz symbols.cc:37:25: error: ginac/ginac.h: No such file or directory ov-vpa.h:39: error: ?GiNaC? has not been declared ov-vpa.h:39: error: expected ?,? or ?...? before ?&? token ... hundreds of errors follow 5) Do I need to build and install Octave from source? Thanks, Rob -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090913/3f9bd01f/attachment.html From dastew at sympatico.ca Sun Sep 13 07:16:47 2009 From: dastew at sympatico.ca (dastew at sympatico.ca) Date: Sun, 13 Sep 2009 12:16:47 +0000 Subject: Help-octave Digest, Vol 42, Issue 28 In-Reply-To: References: Message-ID: In octave do pwd (present working directory pwd) this is where octave will look for the file, so copy the data file to there and then octave will find it. Doug Date: Sun, 13 Sep 2009 16:59:33 +0530 Subject: Re: Help-octave Digest, Vol 42, Issue 28 From: johny1888 at gmail.com To: dastew at sympatico.ca thanks. i am saving the output data of c program in data file named data.dat now to load the file into octave, octave will need to know where the file is. how i should tell octave where to find it i saw the help on load, but it is not giving this info. regards, Johny On Sun, Sep 13, 2009 at 4:39 PM, wrote: One way to do it is to write the data to a text file, and then use the load command in octave to read the data from the file, and then plot it in octave. Doug Date: Sun, 13 Sep 2009 16:29:30 +0530 Subject: Re: Help-octave Digest, Vol 42, Issue 28 From: johny1888 at gmail.com To: help-octave at octave.org Hello i am new user to octave i have a c program whose output which is two colums of data should be plotted by octave as X and Y i am using red hat machine. any suggestions are appreciated. regards Johny -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090913/eb085760/attachment.html From martin at mhelm.de Sun Sep 13 07:44:01 2009 From: martin at mhelm.de (martin_helm) Date: Sun, 13 Sep 2009 05:44:01 -0700 (PDT) Subject: Help-octave Digest, Vol 42, Issue 28 In-Reply-To: References: Message-ID: <25422926.post@talk.nabble.com> dastew wrote: > > > In octave do > > pwd > > (present working directory pwd) > > this is where octave will look for the file, so copy the data file to > there and then octave will find it. > > Doug > > > > Date: Sun, 13 Sep 2009 16:59:33 +0530 > Subject: Re: Help-octave Digest, Vol 42, Issue 28 > From: johny1888 at gmail.com > To: dastew at sympatico.ca > > thanks. > > i am saving the output data of c program in data file named data.dat > now to load the file into octave, octave will need to know where the file > is. > how i should tell octave where to find it > i saw the help on load, but it is not giving this info. > > > regards, > Johny > > On Sun, Sep 13, 2009 at 4:39 PM, wrote: > > > > > > > One way to do it is to write the data to a text file, and then use the > load command in octave to read the data from the file, and then plot it in > octave. > > Doug > > Date: Sun, 13 Sep 2009 16:29:30 +0530 > Subject: Re: Help-octave Digest, Vol 42, Issue 28 > > From: johny1888 at gmail.com > To: help-octave at octave.org > > > Hello > > i am new user to octave > > i have a c program whose output which is two colums of data should be > plotted by octave as X and Y > i am using red hat machine. > > any suggestions are appreciated. > > > regards > > Johny > > > > > _______________________________________________ > Help-octave mailing list > Help-octave at octave.org > https://www-old.cae.wisc.edu/mailman/listinfo/help-octave > > If you do not want to copy the file by hand you can load also tell to use a path for example load -ascii "/path/to/datafile/data.dat" plot(data(1,:), data(2,:)) - mh -- View this message in context: http://www.nabble.com/Re%3A-Help-octave-Digest%2C-Vol-42%2C-Issue-28-tp25422282p25422926.html Sent from the Octave - General mailing list archive at Nabble.com. From lukas.reichlin at swissonline.ch Sun Sep 13 09:32:42 2009 From: lukas.reichlin at swissonline.ch (Lukas Reichlin) Date: Sun, 13 Sep 2009 16:32:42 +0200 Subject: OOP in Octave Message-ID: <9830987E-56AA-4947-9FBA-C4C2700A0B1B@swissonline.ch> Dear Octave Community Since the control package needs to be rewritten in an oop fashion, I started to play around with some Matlab examples. However, Octave gives a parsing error when I try to run an example: parse error near line 9 of file /Users/lukas/Desktop/polynom/ @DocPolynom/DocPolynom.m syntax error >>> end ^ error: evaluating argument list element number 1 parse error near line 9 of file /Users/lukas/Desktop/polynom/ @DocPolynom/DocPolynom.m syntax error >>> end ^ error: evaluating argument list element number 1 error: called from: error: /Users/lukas/Desktop/polynom/polytest.m at line 5, column 3 octave-3.2.2:5> The code is from the MathWorks without any changes, it runs perfectly in Matlab, so it should be OK. What do I need to change to get it up and running in Octave? Thanks for any help Regards, Lukas classdef DocPolynom % Documentation example % A value class that implements a data type for polynonials % See Implementing a Class for Polynomials in the % MATLAB documentation for more information. properties coef end % Class methods methods function obj = DocPolynom(c) % Construct a DocPolynom object using the coefficients supplied if isa(c,'DocPolynom') obj.coef = c.coef; else obj.coef = c(:).'; end end % DocPolynom function obj = set.coef(obj,val) ind = find(val(:).'~=0); if ~isempty(ind); obj.coef = val(ind(1):end); else obj.coef = val; end end function c = double(obj) c = obj.coef; end % double function s = char(obj) % Created a formated display of the polynom % as powers of x if all(obj.coef == 0) s = '0'; else d = length(obj.coef)-1; s = cell(1,d); ind = 1; for a = obj.coef; if a ~= 0; if ind ~= 1 if a > 0 s(ind) = {' + '}; ind = ind + 1; else s(ind) = {' - '}; a = -a; ind = ind + 1; end end if a ~= 1 || d == 0 if a == -1 s(ind) = {'-'}; ind = ind + 1; else s(ind) = {num2str(a)}; ind = ind + 1; if d > 0 s(ind) = {'*'}; ind = ind + 1; end end end if d >= 2 s(ind) = {['x^' int2str(d)]}; ind = ind + 1; elseif d == 1 s(ind) = {'x'}; ind = ind + 1; end end d = d - 1; end end end % char function disp(obj) % DISP Display object in MATLAB syntax c = char(obj); if iscell(c) disp([' ' c{:}]) else disp(c) end end % disp function b = subsref(a,s) % SUBSREF Implementing the following syntax: % obj([1 ...]) % obj.coef % obj.plot % out = obj.method(args) % out = obj.method switch s(1).type case '()' ind = s.subs{:}; b = a.polyval(ind); case '.' switch s(1).subs case 'coef' b = a.coef; case 'plot' a.plot; otherwise if length(s)>1 b = a.(s(1).subs)(s(2).subs{:}); else b = a.(s.subs); end end otherwise error('Specify value for x as obj(x)') end end % subsref function r = plus(obj1,obj2) % PLUS Implement obj1 + obj2 for DocPolynom obj1 = DocPolynom(obj1); obj2 = DocPolynom(obj2); k = length(obj2.coef) - length(obj1.coef); r = DocPolynom([zeros(1,k) obj1.coef] + [zeros(1,-k) obj2.coef]); end % plus function r = minus(obj1,obj2) % MINUS Implement obj1 - obj2 for DocPolynoms. obj1 = DocPolynom(obj1); obj2 = DocPolynom(obj2); k = length(obj2.coef) - length(obj1.coef); r = DocPolynom([zeros(1,k) obj1.coef] - [zeros(1,-k) obj2.coef]); end % minus function r = mtimes(obj1,obj2) % MTIMES Implement obj1 * obj2 for DocPolynoms. obj1 = DocPolynom(obj1); obj2 = DocPolynom(obj2); r = DocPolynom(conv(obj1.coef,obj2.coef)); end % mtimes function r = roots(obj) % ROOTS. ROOTS(obj) is a vector containing the roots of obj. r = roots(obj.coef); end % roots function y = polyval(obj,x) % POLYVAL POLYVAL(obj,x) evaluates obj at the points x. y = polyval(obj.coef,x); end % polyval function q = diff(obj) % DIFF DIFF(obj) is the derivative of the polynom obj. c = obj.coef; d = length(c) - 1; % degree q = DocPolynom(obj.coef(1:d).*(d:-1:1)); end % diff function plot(obj) % PLOT PLOT(obj) plots the polynom obj r = max(abs(roots(obj))); x = (-1.1:0.01:1.1)*r; y = polyval(obj,x); plot(x,y); c = char(obj); title(['y = ' c{:}]) xlabel('X') ylabel('Y','Rotation',0) grid on end % plot end % methods end % classdef -------------- next part -------------- A non-text attachment was scrubbed... Name: polynom.zip Type: application/zip Size: 1886 bytes Desc: not available Url : https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090913/b5019f92/attachment-0001.zip From johny1888 at gmail.com Sun Sep 13 10:13:47 2009 From: johny1888 at gmail.com (johny gaddar) Date: Sun, 13 Sep 2009 20:43:47 +0530 Subject: Help-octave Digest, Vol 42, Issue 28 In-Reply-To: <200909131354.32995.martin@mhelm.de> References: <200909131354.32995.martin@mhelm.de> Message-ID: yes, i am storing the output of the program in .dat kind of file the file contents look like this..... 0 1 1 3 4 7 7 8 and so on. there are only two columns. of integers. thats all. i want to plot second column against first column in octave. other than this, file does not contain anything else. regards, Johny On Sun, Sep 13, 2009 at 5:24 PM, Martin Helm wrote: > Am Sonntag, 13. September 2009 12:59:30 schrieb johny gaddar: > > Hello > > > > i am new user to octave > > > > i have a c program whose output which is two colums of data should be > > plotted by octave as X and Y > > i am using red hat machine. > > > > any suggestions are appreciated. > > > > regards > > Johny > > Dear Johny, > > from your description I asume that your program creates some file which you > want to read in octave to plot it (is that correct). > Can you provide a simple example of such file to see the format of the > numbers > how they are delimited and if the file contains some header? > Then I can give you a hint how to read and display it. > > In general you can for example look at csvread and similar functions > > help csvread > `csvread' is a function from the file > /usr/share/octave/3.2.0/m/io/csvread.m > > -- Function File: X = csvread (FILENAME) > Read the matrix X from a file. > > This function is equivalent to > dlmread (FILENAME, "," , ...) > > See also: dlmread, dlmwrite, csvwrite > > - mh > -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090913/a9478ba2/attachment.html From martin at mhelm.de Sun Sep 13 10:38:56 2009 From: martin at mhelm.de (Martin Helm) Date: Sun, 13 Sep 2009 17:38:56 +0200 Subject: Help-octave Digest, Vol 42, Issue 28 In-Reply-To: References: <200909131354.32995.martin@mhelm.de> Message-ID: <200909131738.56949.martin@mhelm.de> Am Sonntag, 13. September 2009 17:13:47 schrieb johny gaddar: > yes, i am storing the output of the program in .dat kind of file > > the file contents look like this..... > > > 0 1 > 1 3 > 4 7 > 7 8 > > and so on. > there are only two columns. of integers. thats all. > i want to plot second column against first column in octave. > other than this, file does not contain anything else. > > regards, > Johny > So the form load -ascii "/path/to/datafile/data.dat" plot(data(1,:), data(2,:)) should work (assuming data.dat) otherwise the resulting variable has simply a different name mymatrix.dat -> mymatrix cointains the data and so on. > On Sun, Sep 13, 2009 at 5:24 PM, Martin Helm wrote: > > Am Sonntag, 13. September 2009 12:59:30 schrieb johny gaddar: > > > Hello > > > > > > i am new user to octave > > > > > > i have a c program whose output which is two colums of data should be > > > plotted by octave as X and Y > > > i am using red hat machine. > > > > > > any suggestions are appreciated. > > > > > > regards > > > Johny > > > > Dear Johny, > > > > from your description I asume that your program creates some file which > > you want to read in octave to plot it (is that correct). > > Can you provide a simple example of such file to see the format of the > > numbers > > how they are delimited and if the file contains some header? > > Then I can give you a hint how to read and display it. > > > > In general you can for example look at csvread and similar functions > > > > help csvread > > `csvread' is a function from the file > > /usr/share/octave/3.2.0/m/io/csvread.m > > > > -- Function File: X = csvread (FILENAME) > > Read the matrix X from a file. > > > > This function is equivalent to > > dlmread (FILENAME, "," , ...) > > > > See also: dlmread, dlmwrite, csvwrite > > > > - mh From martin at mhelm.de Sun Sep 13 06:54:32 2009 From: martin at mhelm.de (Martin Helm) Date: Sun, 13 Sep 2009 13:54:32 +0200 Subject: Help-octave Digest, Vol 42, Issue 28 In-Reply-To: References: Message-ID: <200909131354.32995.martin@mhelm.de> Am Sonntag, 13. September 2009 12:59:30 schrieb johny gaddar: > Hello > > i am new user to octave > > i have a c program whose output which is two colums of data should be > plotted by octave as X and Y > i am using red hat machine. > > any suggestions are appreciated. > > regards > Johny Dear Johny, from your description I asume that your program creates some file which you want to read in octave to plot it (is that correct). Can you provide a simple example of such file to see the format of the numbers how they are delimited and if the file contains some header? Then I can give you a hint how to read and display it. In general you can for example look at csvread and similar functions help csvread `csvread' is a function from the file /usr/share/octave/3.2.0/m/io/csvread.m -- Function File: X = csvread (FILENAME) Read the matrix X from a file. This function is equivalent to dlmread (FILENAME, "," , ...) See also: dlmread, dlmwrite, csvwrite - mh From dbateman at dbateman.org Sun Sep 13 12:08:09 2009 From: dbateman at dbateman.org (David Bateman) Date: Sun, 13 Sep 2009 19:08:09 +0200 Subject: OOP in Octave In-Reply-To: <9830987E-56AA-4947-9FBA-C4C2700A0B1B@swissonline.ch> References: <9830987E-56AA-4947-9FBA-C4C2700A0B1B@swissonline.ch> Message-ID: <4AAD26F9.100@dbateman.org> Lukas Reichlin wrote: > Dear Octave Community > > Since the control package needs to be rewritten in an oop fashion, I > started to play around with some Matlab examples. However, Octave > gives a parsing error when I try to run an example: > > parse error near line 9 of file > /Users/lukas/Desktop/polynom/@DocPolynom/DocPolynom.m > > syntax error > > >>> end > ^ > > error: evaluating argument list element number 1 > parse error near line 9 of file > /Users/lukas/Desktop/polynom/@DocPolynom/DocPolynom.m > > syntax error > > >>> end > ^ > > error: evaluating argument list element number 1 > error: called from: > error: /Users/lukas/Desktop/polynom/polytest.m at line 5, column 3 > octave-3.2.2:5> > > The code is from the MathWorks without any changes, it runs perfectly > in Matlab, so it should be OK. What do I need to change to get it up > and running in Octave? > > Thanks for any help > > Regards, > Lukas > > > classdef DocPolynom There is no classdef in Octave yet, though some preliminary work is done.. There is only the old matlab OOP style code in octave (ie tough with the @ directories). The matlab docs for this style of coding are at http://www.mathworks.com/access/helpdesk/help/pdf_doc/matlab/pre-version_7.6_oop.pdf and there is a chapter in the Octave manual in 3.2.2 on the OOP support in octave D. -- David Bateman dbateman at dbateman.org 35 rue Gambetta +33 1 46 04 02 18 (Home) 92100 Boulogne-Billancourt FRANCE +33 6 72 01 06 33 (Mob) From phil at beadling.co.uk Sun Sep 13 16:19:11 2009 From: phil at beadling.co.uk (Philip Beadling) Date: Sun, 13 Sep 2009 22:19:11 +0100 Subject: Yapso scales surf plots wrong? Message-ID: <1252876751.7374.26.camel@phil-desktop> Hi all, I Stumbled across Yapso today - it has some very nice plotting functionality. I can get the examples working fine, but when I try to plot some of my own data I get a scaling issue. My data ranges are created using linspace like: n=50 x = linspace(0,2,n) y = linspace(20,80,n) [X,Y] = meshgrid(x,y) % Z's range is approx 30-50. Z = func(X,Y) surf(X,Y,Z,Z) shading faceted colorbar Using the standard Gnuplot this is scaled perfectly. But with Yapso the same scale is used for all 3 axis (as far as I can tell). Hence the x axis being from 0 to 2 is compressed to the point where the graph looks really messed up. First question is - why doesn't Yapso scale automatically, am I missing something? I note all the examples on the webpage seem to only have examples where scales are on the same order of magnitude, so there are no examples to confirm my issue. Secondly, if I need to specify that x axis has a much finer granularity scale how do I do that? Thanks very much, Phil From manishdkulkarni at gmail.com Sun Sep 13 23:39:15 2009 From: manishdkulkarni at gmail.com (Manish Kulkarni) Date: Sun, 13 Sep 2009 21:39:15 -0700 Subject: imread error In-Reply-To: <4AACCBE1.8050201@gmx.net> References: <8feb35460909111257nc1a42bx7868a4e430d98481@mail.gmail.com> <4AACCBE1.8050201@gmx.net> Message-ID: <8feb35460909132139w2d87af10r1fcfa177910c6779@mail.gmail.com> Thanks a lot Benjamin, will try this out. Cheers Manish On Sun, Sep 13, 2009 at 3:39 AM, Benjamin Lindner wrote: > Manish Kulkarni wrote: > >> Dear everyone, >> >> I'm getting the following error with imread >> >> > tftimage = imread("Waterfall.jpg"); >> error: imread: invalid image file: Magick++ exception: Magick: Unable to >> access configuration file (magic.mgk) reported >> by >> d:/files/admin/octaveforge_svn/trunk/octave-forge/admin/Windows/mingw32/graphicsmagick/GraphicsMagick-1.3.3/magick/bl >> ob.c:1824 (GetConfigureBlob) >> error: called from: >> error: C:\Octave\3.2.0_gcc-4.3.0\share\octave\3.2.0\m\image\imread.m at >> line 74, column 7 >> octave-3.2.0.exe:12:c:\Users\laptopGuru\Documents\mSilica\tftOctave >> >> would anyone advise how to fix this? >> >> > Update to the 3.2.2 binary. This issue has been fixed there. > > benjamin > > -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090913/d7193eb8/attachment.html From linuxdieg at gmail.com Mon Sep 14 01:43:35 2009 From: linuxdieg at gmail.com (diego vega) Date: Mon, 14 Sep 2009 01:43:35 -0500 Subject: help me Message-ID: comunidad de octave, cordial saludo me dirijo a ustedes poque tengo una duda acerca de ciertas funciones que no he podido usar en octave, quisiera saber si existen o hay que crearlas; las funciones son: funcion escalon, funcion signo, pulso triangular , inpulso unitario. muchas gracias -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090914/52caad67/attachment.html From lukas.reichlin at swissonline.ch Mon Sep 14 02:01:33 2009 From: lukas.reichlin at swissonline.ch (Lukas Reichlin) Date: Mon, 14 Sep 2009 09:01:33 +0200 Subject: OOP in Octave In-Reply-To: <4AAD26F9.100@dbateman.org> References: <9830987E-56AA-4947-9FBA-C4C2700A0B1B@swissonline.ch> <4AAD26F9.100@dbateman.org> Message-ID: <7683DFC4-C36F-408E-A4E7-1A03AD77E352@swissonline.ch> On 13.09.2009, at 19:08, David Bateman wrote: > Lukas Reichlin wrote: >> Dear Octave Community >> >> Since the control package needs to be rewritten in an oop fashion, >> I started to play around with some Matlab examples. However, Octave >> gives a parsing error when I try to run an example: >> >> parse error near line 9 of file /Users/lukas/Desktop/polynom/ >> @DocPolynom/DocPolynom.m >> >> syntax error >> >> >>> end >> ^ >> >> error: evaluating argument list element number 1 >> parse error near line 9 of file /Users/lukas/Desktop/polynom/ >> @DocPolynom/DocPolynom.m >> >> syntax error >> >> >>> end >> ^ >> >> error: evaluating argument list element number 1 >> error: called from: >> error: /Users/lukas/Desktop/polynom/polytest.m at line 5, column 3 >> octave-3.2.2:5> >> >> The code is from the MathWorks without any changes, it runs >> perfectly in Matlab, so it should be OK. What do I need to change >> to get it up and running in Octave? >> >> Thanks for any help >> >> Regards, >> Lukas >> >> >> classdef DocPolynom > There is no classdef in Octave yet, though some preliminary work is > done.. There is only the old matlab OOP style code in octave (ie > tough with the @ directories). The matlab docs for this style of > coding are at > > http://www.mathworks.com/access/helpdesk/help/pdf_doc/matlab/pre-version_7.6_oop.pdf > > and there is a chapter in the Octave manual in 3.2.2 on the OOP > support in octave > > D. > > > -- > David Bateman dbateman at dbateman.org > 35 rue Gambetta +33 1 46 04 02 18 (Home) > 92100 Boulogne-Billancourt FRANCE +33 6 72 01 06 33 (Mob) > Thanks for your quick reply. Do you know when the new style should be ready to use? (in one year, in two years or Octave 3.4, 3.6 ...) Regards Lukas From highegg at gmail.com Mon Sep 14 02:31:08 2009 From: highegg at gmail.com (Jaroslav Hajek) Date: Mon, 14 Sep 2009 09:31:08 +0200 Subject: Wrapper fortran In-Reply-To: <25408339.post@talk.nabble.com> References: <25408339.post@talk.nabble.com> Message-ID: <69d8d540909140031uee193cj2a8f0d00bf40763b@mail.gmail.com> On Fri, Sep 11, 2009 at 11:07 PM, R.C. wrote: > > Hello, > > > I followed example ?from http://wiki.octave.org/wiki.pl?OctaveFortran but I > have some trouble with my fortran subroutine. > Compilation works but when i call my function it gives ; > > [f, xb] = wrapper (2, 4, rand(4,1), 1) > *** glibc detected *** octave: free(): invalid next size (fast): 0x09c20450 > *** > ======= Backtrace: ========= > /lib/tls/i686/cmov/libc.so.6[0xb5d31604] > /lib/tls/i686/cmov/libc.so.6(cfree+0x96)[0xb5d335b6] > /usr/lib/libstdc++.so.6(_ZdlPv+0x21)[0xb5eed231] > /usr/lib/libstdc++.so.6(_ZdaPv+0x1d)[0xb5eed28d] > /usr/lib/octave-3.0.1/liboctinterp.so(_ZN5ArrayIdED2Ev+0xc6)[0xb7a30c66] > etc... > > > My wrapper > *********************************************************************************** > #include > #include "f77-fcn.h" > extern "C" > ?{ > ? ?int F77_FUNC (rosenf_b, ROSENF_b) (const int& ind, const int& n, > ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?const double* x, > ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?double* xb, double& f, > ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?const double& fb, > ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?double& g, double& ti, double& tr, double& td ); > ?} > ?DEFUN_DLD (wrapper, args, , > ? ? ? ? ? ?"- Loadable Function: [f, xb] = wrapper (ind, n, x, fb)\n\ > ?\n\ > ?Returns the f,xb.") > ?{ > ? ?octave_value_list retval; > ? ?Matrix X; > > ? ?const int IND = args(0).int_value(), N = args(1).int_value(); > ? ?const double FB; > ? ?double G; > ? ?NDArray XB; > ? ?double F,TI,TR,TD; > ? ?double *av; > > ? ? FB = args(3).double_value(); > ? ? X = args(2).matrix_value(); > ? ? av = XB.fortran_vec(); > > > ? ?F77_XFCN (rosenf_b, ROSENF_B, > ? ? ? ? ? ?(IND, N, > ? ? ? ? ? ?X.fortran_vec(), > ? ? ? ? ? ?av, > ? ? ? ? ? ?F, > ? ? ? ? ? ?FB, > ? ? ? ? ? ?G, > ? ? ? ? ? ?TI, TR, TD) ); > ? ?if (f77_exception_encountered) > ? ? ?{ > ? ? ? ?error ("unrecoverable error in rosenf_b"); > ? ? ? ?return retval; > ? ? ?} > ? ?retval(0) = octave_value (F); > ? ?retval(1) = octave_value(XB); > > ? ?return retval; > ?} > ************************************************************************* > > > > > Fortran function > ************************************************************************ > ? ? ?SUBROUTINE ROSENF_B(ind, n, x, xb, f, fb, g, ti, tr, td) > ? ? ?IMPLICIT NONE > ? ? ?INTEGER ind, n, ti(*) > ? ? ?DOUBLE PRECISION x(n), f, g(n), td(*) > ? ? ?DOUBLE PRECISION xb(n), fb > ? ? ?REAL tr(*) > C > ? ? ?DOUBLE PRECISION y, p > ? ? ?INTEGER i > ? ? ?DOUBLE PRECISION tempb > ? ? ?INTEGER ii1 > ? ? ?p = 100.0d0 > ? ? ?IF (ind .EQ. 2 .OR. ind .EQ. 4) THEN > ? ? ? ?DO ii1=1,n > ? ? ? ? ?xb(ii1) = 0.D0 > ? ? ? ?ENDDO > ? ? ? ?DO i=n,2,-1 > ? ? ? ? ?tempb = p*2*(x(i)-x(i-1)**2)*fb > ? ? ? ? ?xb(i) = xb(i) + tempb - 2*(1.0d0-x(i))*fb > ? ? ? ? ?xb(i-1) = xb(i-1) - 2*x(i-1)*tempb > ? ? ? ?ENDDO > ? ? ? ?fb = 0.D0 > ? ? ?ELSE > ? ? ? ?DO ii1=1,n > ? ? ? ? ?xb(ii1) = 0.D0 > ? ? ? ?ENDDO > ? ? ?END IF > ? ? ?END > ********************************************************************** > > > > What do you suggest ? > Thanks > To fix your code. XB needs to be allocated (av points to buffer of size 0 in your example). Btw., it makes little sense to pass n to the function, when it can be inferred from x. hth -- RNDr. Jaroslav Hajek computing expert & GNU Octave developer Aeronautical Research and Test Institute (VZLU) Prague, Czech Republic url: www.highegg.matfyz.cz From highegg at gmail.com Mon Sep 14 04:41:19 2009 From: highegg at gmail.com (Jaroslav Hajek) Date: Mon, 14 Sep 2009 11:41:19 +0200 Subject: Using STR2FUNC in sub-function to refer to other sub-function(s) In-Reply-To: <47AC1666471FFC41873637D50D111B812679568394@SINTEFEXMBX01.sintef.no> References: <47AC1666471FFC41873637D50D111B812679568394@SINTEFEXMBX01.sintef.no> Message-ID: <69d8d540909140241m4f52be6ek847b8c574f993e8c@mail.gmail.com> On Fri, Sep 11, 2009 at 4:04 PM, B?rd Skaflestad wrote: > All, > > I'm experiencing a bit of bother using the STR2FUNC function. ?For sake of argument I'll use the synthetic function 'foo' defined as > > $ cat foo.m > ? function h = foo() > ? ? ?h = @sub1; > ? end > > ? function h = sub1() > ? ? ?h = str2func('sub2'); > ? end > > ? function h = sub2() > ? ? ?h = @(x) sub3(x, 10); > ? end > > ? function q = sub3(a, b) > ? ? ?q = fprintf('sub3: (a,b) = (%f,%d)\n', a, b); > ? end > $ > > In Octave I then get > > --------------------8<----------------------------------------8<------------------------- > > ? ?octave:29> f = foo(), s1 = f(), s2 = s1(), s3 = s2(pi) > ? ?f = > > ? ?sub1 > > ? ?error: error creating function handle "@sub2" > ? ?error: called from: > ? ?error: ? /home/bska/tmp/build/octave/3.2.2/foo.m at line 6, column 9 > > --------------------8<----------------------------------------8<------------------------- > > while MATLAB yields the, to me, expected output > > --------------------8<----------------------------------------8<------------------------- > > ? ?>> f = foo(), s1 = f(), s2 = s1(), s3 = s2(pi) > > ? ?f = > > ? ? ? ?@sub1 > > ? ?s1 = > > ? ? ? ?@sub2 > > ? ?s2 = > > ? ? ? ?@(x)sub3(x,10) > > ? ?sub3: (a,b) = (3.141593,10) > > ? ?s3 = > > ? ? ? ?28 > > --------------------8<----------------------------------------8<------------------------- > > My question is if this (failing to construct a function handle to 'sub2') is an error in Octave or if Octave's STR2FUNC implementation is not expected to have the ability to construct handles to (other) sub-functions of a "main" function. ?I should note that if I replace the above 'sub1' function by the (equivalent, in this case) > > ? ?function h = sub1() > ? ? ? h = @sub2; > ? ?end > > the above error goes away. ?In the general case, however, I would really like the ability to use STR2FUNC here because the function name is not generally known until runtime in code. ?Admittedly, my code uses only a bounded set of possible string values (roughly 5-10 alternatives), but I'd rather not insert a big SWITCH statement in there. ?Any and all suggestions will be greatly appreciated. > > > Best regards, > -- > B?rd Skaflestad ? ? ? ? ? ? ? ? ? ? ? ? ? ? > SINTEF ICT, Applied mathematics > Forskningsveien 1, No-0314 Oslo > Tel.: (+47) 2206 7642 > > The following patch fixes the problem in the development tree: http://hg.savannah.gnu.org/hgweb/octave/rev/8d79f36ebdde this patch is not directly applicable to 3.2.x (breaks ABI), so it will need a separate patch. It may not make it into 3.2.3 which is just days away. thanks -- RNDr. Jaroslav Hajek computing expert & GNU Octave developer Aeronautical Research and Test Institute (VZLU) Prague, Czech Republic url: www.highegg.matfyz.cz From Bard.Skaflestad at sintef.no Mon Sep 14 06:53:38 2009 From: Bard.Skaflestad at sintef.no (=?ISO-8859-1?Q?B=E5rd?= Skaflestad) Date: Mon, 14 Sep 2009 13:53:38 +0200 Subject: Using STR2FUNC in sub-function to refer to other sub-function(s) In-Reply-To: <69d8d540909140241m4f52be6ek847b8c574f993e8c@mail.gmail.com> References: <47AC1666471FFC41873637D50D111B812679568394@SINTEFEXMBX01.sintef.no> <69d8d540909140241m4f52be6ek847b8c574f993e8c@mail.gmail.com> Message-ID: <1252929218.14408.1.camel@skuffe.math.sintef.no> On Mon, 2009-09-14 at 11:41 +0200, Jaroslav Hajek wrote: > On Fri, Sep 11, 2009 at 4:04 PM, B?rd Skaflestad > wrote: [A problem description] > The following patch fixes the problem in the development tree: > http://hg.savannah.gnu.org/hgweb/octave/rev/8d79f36ebdde > > this patch is not directly applicable to 3.2.x (breaks ABI), so it > will need a separate patch. It may not make it into 3.2.3 which is > just days away. > > thanks Thank you so much for the swift response and solution. I'll try the development tree later this week. Best regards, -- B?rd Skaflestad SINTEF ICT, Applied mathematics Forskningsveien 1, No-0314 Oslo Tel.: (+47) 2206 7642 From christy1865 at yahoo.com Mon Sep 14 07:06:25 2009 From: christy1865 at yahoo.com (Kristen Richter) Date: Mon, 14 Sep 2009 05:06:25 -0700 (PDT) Subject: octave function 'avifile' help Message-ID: <111889.53914.qm@web30208.mail.mud.yahoo.com> Hello all, I am attempting to create a movie from a series of plots using octave function 'avifile'. I found this function in the video add-on package available from Octave-forge, but I am having some trouble using it because octave can't seem to find the appropriate codecs. I am trying out some example code I found in the mailing list archives. Link:http://neacm.fe.up.pt/pub/octave/MAILING-LISTS/help-octave/2005/3694 I have pasted the code below: # Open the AVI file m = avifile("test.avi", "codec", "msmpeg4v2") # Generate and add frames for i = 1:100 I = zeros(100,100); I(i,:) = i; I(:,i) = 200-i; addframe(m, I/255) printf(".") endfor printf("\n") # Close the file clear m However, after running these commands on the octave command line, I get the following error: AVHandler: cannot find codec msmpeg4v2 error: avifile: AVHandler setup failed addframe: error adding frame to avifile I've tried the example, specifying different kinds of audio codecs, including cinepak, indeo5, and indeo3. I've checked my synaptic package manager to make sure I have these audio codecs installed. During troubleshooting, I've installed libavifile (vs. 0.7), which mentions the indeo library by name. Are the codecs supposed to be installed in a specific directory? Are they supposed to be referred to by a text string that also contains the directory name? Has anyone come across similar issues in the past? The example is pretty old... dated 2005, and I know the video package was updated last this past May. Any insight on the situation would be greatly appreciated. As always, your help in the past has been invaluable. -Kristen Richter From mangostein17 at googlemail.com Mon Sep 14 10:33:03 2009 From: mangostein17 at googlemail.com (matt) Date: Mon, 14 Sep 2009 16:33:03 +0100 Subject: octave vs. matlab vectorization Message-ID: <343F894B-E4BD-43F7-9F2A-9383829E302C@gmail.com> i have used octave exclusively for a number of years and just recently had to use matlab for teaching purposes. since i was raised to vectorize loop structures whenever possible, i thought i would illustrate the the speed-up for the students in the class by comparing execution time for two codes--code 1 with loops, and code 2 vectorized. here is code 1: t0=clock; for m=1:1000000 q=zeros(1,10); for k=1:10, tmp=k^2; if tmp>50, q(k)=tmp; else q(k)=0; end end end etime(clock,t0) here is code 2: t0=clock; for m=1:1000000 q=zeros(1,10); tmp=(1:10).^2; q=tmp.*(tmp>50); end etime(clock,t0) on my laptop, octave (3.0.5) takes 200 secs for the first code and just 24 secs for the second--i thought i had proved my point. however, on the department server (admittedly a much faster machine), matlab ground through the first code in 0.82 secs while the second code took 4.3 secs. so, my question: has matlab been optimized for loops? is there some sort of compilation going on? any insight gratefully received. i have been writing code in octave for a while now and had assumed it would almost be a straight port to matlab. cheers, matt. From storrsjm at email.uc.edu Mon Sep 14 11:07:33 2009 From: storrsjm at email.uc.edu (Judd Storrs) Date: Mon, 14 Sep 2009 12:07:33 -0400 Subject: octave vs. matlab vectorization In-Reply-To: <343F894B-E4BD-43F7-9F2A-9383829E302C@gmail.com> References: <343F894B-E4BD-43F7-9F2A-9383829E302C@gmail.com> Message-ID: Matlab has used a JIT compiler for a while now so the vectorization penalty in loops often isn't nearly as severe as it once was. In the Q&A of a sales presentation a few years ago, I remember it was mentioned that Matlab's JIT compiler is able to recognize and vectorize some loops more efficiently than others. Octave doesn't have JIT. --judd On Mon, Sep 14, 2009 at 11:33 AM, matt wrote: > i have used octave exclusively for a number of years and just > recently had to use matlab for teaching purposes. > > since i was raised to vectorize loop structures whenever possible, i > thought i would illustrate the the speed-up for the students in the > class by comparing execution time for two codes--code 1 with loops, > and code 2 vectorized. > > here is code 1: > > t0=clock; > for m=1:1000000 > q=zeros(1,10); > for k=1:10, > tmp=k^2; > if tmp>50, > q(k)=tmp; > else > q(k)=0; > end > end > end > etime(clock,t0) > > here is code 2: > > t0=clock; > for m=1:1000000 > q=zeros(1,10); > tmp=(1:10).^2; > q=tmp.*(tmp>50); > end > etime(clock,t0) > > on my laptop, octave (3.0.5) takes 200 secs for the first code and > just 24 secs for the second--i thought i had proved my point. > > however, on the department server (admittedly a much faster machine), > matlab ground through the first code in 0.82 secs while the second > code took 4.3 secs. > > so, my question: has matlab been optimized for loops? is there some > sort of compilation going on? any insight gratefully received. i have > been writing code in octave for a while now and had assumed it would > almost be a straight port to matlab. > > cheers, > > matt. > > _______________________________________________ > Help-octave mailing list > Help-octave at octave.org > https://www-old.cae.wisc.edu/mailman/listinfo/help-octave > -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090914/4823a2b5/attachment.html From Potorti at isti.cnr.it Mon Sep 14 11:31:35 2009 From: Potorti at isti.cnr.it (Francesco Potorti`) Date: Mon, 14 Sep 2009 18:31:35 +0200 Subject: octave vs. matlab vectorization In-Reply-To: <343F894B-E4BD-43F7-9F2A-9383829E302C@gmail.com> References: <343F894B-E4BD-43F7-9F2A-9383829E302C@gmail.com> Message-ID: >since i was raised to vectorize loop structures whenever possible, i >thought i would illustrate the the speed-up for the students in the >class by comparing execution time for two codes--code 1 with loops, >and code 2 vectorized. > >here is code 1: > >t0=clock; >for m=1:1000000 > q=zeros(1,10); > for k=1:10, > tmp=k^2; > if tmp>50, > q(k)=tmp; > else > q(k)=0; > end > end >end >etime(clock,t0) > >here is code 2: > >t0=clock; >for m=1:1000000 > q=zeros(1,10); > tmp=(1:10).^2; > q=tmp.*(tmp>50); >end >etime(clock,t0) > >on my laptop, octave (3.0.5) takes 200 secs for the first code and >just 24 secs for the second--i thought i had proved my point. A ratio of 8.3:1 >however, on the department server (admittedly a much faster machine), >matlab ground through the first code in 0.82 secs while the second >code took 4.3 secs. A ratio of 5.2:1. Not quite the same, but I think the point is proven nonetheless. -- Francesco Potort? (ricercatore) Voice: +39 050 315 3058 (op.2111) ISTI - Area della ricerca CNR Fax: +39 050 315 2040 via G. Moruzzi 1, I-56124 Pisa Email: Potorti at isti.cnr.it (entrance 20, 1st floor, room C71) Web: http://fly.isti.cnr.it/ From mangostein17 at googlemail.com Mon Sep 14 11:57:10 2009 From: mangostein17 at googlemail.com (matt) Date: Mon, 14 Sep 2009 17:57:10 +0100 Subject: octave vs. matlab vectorization In-Reply-To: References: <343F894B-E4BD-43F7-9F2A-9383829E302C@gmail.com> Message-ID: ah, no! code 1 was *faster* under matlab! the ratio is 0.19:1 i find this result quite staggering. On 14 Sep 2009, at 17:31, Francesco Potorti` wrote: >> >> on my laptop, octave (3.0.5) takes 200 secs for the first code and >> just 24 secs for the second--i thought i had proved my point. > > A ratio of 8.3:1 > >> however, on the department server (admittedly a much faster machine), >> matlab ground through the first code in 0.82 secs while the second >> code took 4.3 secs. > > A ratio of 5.2:1. Not quite the same, but I think the point is proven > nonetheless. > > -- > Francesco Potort? (ricercatore) Voice: +39 050 315 3058 (op. > 2111) > ISTI - Area della ricerca CNR Fax: +39 050 315 2040 > via G. Moruzzi 1, I-56124 Pisa Email: Potorti at isti.cnr.it > (entrance 20, 1st floor, room C71) Web: http://fly.isti.cnr.it/ From jwe at octave.org Mon Sep 14 12:29:52 2009 From: jwe at octave.org (John W. Eaton) Date: Mon, 14 Sep 2009 13:29:52 -0400 Subject: octave vs. matlab vectorization In-Reply-To: References: <343F894B-E4BD-43F7-9F2A-9383829E302C@gmail.com> Message-ID: <19118.32144.109057.627543@segfault.lan> On 14-Sep-2009, matt wrote: | ah, no! code 1 was *faster* under matlab! the ratio is 0.19:1 | | i find this result quite staggering. Why? As someone else already explained, Matlab has a JIT compiler that can, in some cases at least, compile loops into native code so that it runs faster and Octave does not have a JIT compiler. jwe From shermanj at umd.edu Mon Sep 14 12:43:54 2009 From: shermanj at umd.edu (James Sherman Jr.) Date: Mon, 14 Sep 2009 13:43:54 -0400 Subject: octave vs. matlab vectorization In-Reply-To: <19118.32144.109057.627543@segfault.lan> References: <343F894B-E4BD-43F7-9F2A-9383829E302C@gmail.com> <19118.32144.109057.627543@segfault.lan> Message-ID: <6800c3890909141043g32e6891ds4bde74e8bc78ec71@mail.gmail.com> >ah, no! code 1 was *faster* under matlab! the ratio is 0.19:1 > >i find this result quite staggering. I ran those two codes with the matlab I have on my laptop (7.7.0.471 R2008b) and got 16.9 for the for loops code and 3.54 for the vectorized code. I don't know why there would be such a discrepancy. This may sound dumb, but are you sure you didn't confuse the two times? -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090914/6ebe439a/attachment.html From highegg at gmail.com Mon Sep 14 12:46:32 2009 From: highegg at gmail.com (Jaroslav Hajek) Date: Mon, 14 Sep 2009 19:46:32 +0200 Subject: octave vs. matlab vectorization In-Reply-To: <6800c3890909141043g32e6891ds4bde74e8bc78ec71@mail.gmail.com> References: <343F894B-E4BD-43F7-9F2A-9383829E302C@gmail.com> <19118.32144.109057.627543@segfault.lan> <6800c3890909141043g32e6891ds4bde74e8bc78ec71@mail.gmail.com> Message-ID: <69d8d540909141046r75cef779g7829dad3ab41b571@mail.gmail.com> On Mon, Sep 14, 2009 at 7:43 PM, James Sherman Jr. wrote: >>ah, no! code 1 was *faster* under matlab! the ratio is 0.19:1 >> >>i find this result quite staggering. > > I ran those two codes with the matlab I have on my laptop (7.7.0.471 R2008b) > and got 16.9 for the for loops code and 3.54 for the vectorized code. > > I don't know why there would be such a discrepancy.? This may sound dumb, > but are you sure you didn't confuse the two times? > IIRC, it may make a difference whether the code is in a function/script/entered from cmd-line. Functions are best optimized, I think. -- RNDr. Jaroslav Hajek computing expert & GNU Octave developer Aeronautical Research and Test Institute (VZLU) Prague, Czech Republic url: www.highegg.matfyz.cz From highegg at gmail.com Mon Sep 14 12:51:43 2009 From: highegg at gmail.com (Jaroslav Hajek) Date: Mon, 14 Sep 2009 19:51:43 +0200 Subject: octave vs. matlab vectorization In-Reply-To: <343F894B-E4BD-43F7-9F2A-9383829E302C@gmail.com> References: <343F894B-E4BD-43F7-9F2A-9383829E302C@gmail.com> Message-ID: <69d8d540909141051lbbf3030qe7d53fe8bdd1f4f4@mail.gmail.com> On Mon, Sep 14, 2009 at 5:33 PM, matt wrote: > i have used octave exclusively for a number of years and just > recently had to use matlab for teaching purposes. > > since i was raised to vectorize loop structures whenever possible, i > thought i would illustrate the the speed-up for the students in the > class by comparing execution time for two codes--code 1 with loops, > and code 2 vectorized. > > here is code 1: > > t0=clock; > for m=1:1000000 > ? ? ? ?q=zeros(1,10); > ? ? ? ?for k=1:10, > ? ? ? ? ? ? ? ?tmp=k^2; > ? ? ? ? ? ? ? ?if tmp>50, > ? ? ? ? ? ? ? ? ? ? ? ?q(k)=tmp; > ? ? ? ? ? ? ? ?else > ? ? ? ? ? ? ? ? ? ? ? ?q(k)=0; > ? ? ? ? ? ? ? ?end > ? ? ? ?end > end > etime(clock,t0) > > here is code 2: > > t0=clock; > for m=1:1000000 > ? ? ? ?q=zeros(1,10); > ? ? ? ?tmp=(1:10).^2; > ? ? ? ?q=tmp.*(tmp>50); > end > etime(clock,t0) > > on my laptop, octave (3.0.5) takes 200 secs for the first code and > just 24 secs for the second--i thought i had proved my point. > > however, on the department server (admittedly a much faster machine), > matlab ground through the first code in 0.82 secs while the second > code took 4.3 secs. > > so, my question: has matlab been optimized for loops? is there some > sort of compilation going on? any insight gratefully received. i have > been writing code in octave for a while now and had assumed it would > almost be a straight port to matlab. > Octave mailing list is not the best place to ask technical questions about Matlab. But yes, one of the primary performance differences between Octave and Matlab is that Octave is purely interpreted, while Matlab is JIT compiled. I think this situation is unlikely to change in the near future. -- RNDr. Jaroslav Hajek computing expert & GNU Octave developer Aeronautical Research and Test Institute (VZLU) Prague, Czech Republic url: www.highegg.matfyz.cz From Potorti at isti.cnr.it Mon Sep 14 15:12:35 2009 From: Potorti at isti.cnr.it (Francesco Potorti`) Date: Mon, 14 Sep 2009 22:12:35 +0200 Subject: octave vs. matlab vectorization In-Reply-To: References: <343F894B-E4BD-43F7-9F2A-9383829E302C@gmail.com> Message-ID: >ah, no! code 1 was *faster* under matlab! the ratio is 0.19:1 >i find this result quite staggering. Mh. That vectorised code is slower than jit compiled code is strange, indeed. If your measurements are correct, this may depend on various things, but these are Matlab's implementation issues. -- Francesco Potort? (ricercatore) Voice: +39 050 315 3058 (op.2111) ISTI - Area della ricerca CNR Fax: +39 050 315 2040 via G. Moruzzi 1, I-56124 Pisa Email: Potorti at isti.cnr.it (entrance 20, 1st floor, room C71) Web: http://fly.isti.cnr.it/ From abce at Live.cn Mon Sep 14 21:25:25 2009 From: abce at Live.cn (flyrain) Date: Mon, 14 Sep 2009 19:25:25 -0700 (PDT) Subject: unofficial octave 3.2.2 msvc2008 solution/project files In-Reply-To: <25368142.post@talk.nabble.com> References: <25368142.post@talk.nabble.com> Message-ID: <25446848.post@talk.nabble.com> Hi choonway ***************************************** 1. download and unzip sources octave-3.2.2.tar.bz2 2. move the folder build_vc2008 inside the source folder ***************************************** does the point 2 means I should create a new folder named source and then move the build_vs2008 inside? there are some build errors.. ****************************** 2>Generating Code... 2>Build log was saved at "file://f:\Library\octave-3.2.2-msvc9-20090909.tar\octave-3.2.2-msvc9-20090909\octave-3.2.2\build_vs2008\libcruft\Debug\BuildLog.htm" 2>libcruft - 3 error(s), 2865 warning(s) 3>------ Build started: Project: liboctave, Configuration: Debug Win32 ------ 3>Compiling... 3>Array-b.cc 3>c1xx : fatal error C1083: Cannot open source file: '..\..\liboctave\Array-b.cc': No such file or directory 3>Array-C.cc 3>c1xx : fatal error C1083: Cannot open source file: '..\..\liboctave\Array-C.cc': No such file or directory 3>Array-ch.cc 3>c1xx : fatal error C1083: Cannot open source file: '..\..\liboctave\Array-ch.cc': No such file or directory 3>Array-d.cc 3>c1xx : fatal error C1083: Cannot open source file: '..\..\liboctave\Array-d.cc': No such file or directory 3>Array-f.cc 3>c1xx : fatal error C1083: Cannot open source file: '..\..\liboctave\Array-f.cc': No such file or directory 3>Array-fC.cc ****************************** Liao Choon Way wrote: > > hi all, > > i have prepared a _rough_ set of files for those interested in embedding > octave > into windows applications and have problems with mingw dlls. > > Get them > http://sourceforge.net/projects/el-rekka/files/octave-3.2.2-msvc9-20090909.tar.gz/download > here . > > instructions enclosed. read before use. check the repository for updates. > > choonway > -- View this message in context: http://www.nabble.com/unofficial-octave-3.2.2-msvc2008-solution-project-files-tp25368142p25446848.html Sent from the Octave - General mailing list archive at Nabble.com. From highegg at gmail.com Tue Sep 15 01:37:36 2009 From: highegg at gmail.com (Jaroslav Hajek) Date: Tue, 15 Sep 2009 08:37:36 +0200 Subject: octave vs. matlab vectorization In-Reply-To: References: <343F894B-E4BD-43F7-9F2A-9383829E302C@gmail.com> Message-ID: <69d8d540909142337o51b620b8sa76d3f48aa178200@mail.gmail.com> On Mon, Sep 14, 2009 at 10:12 PM, Francesco Potorti` wrote: >>ah, no! code 1 was *faster* under matlab! the ratio is 0.19:1 >>i find this result quite staggering. > > Mh. ?That vectorised code is slower than jit compiled code is strange, > indeed. ?If your measurements are correct, this may depend on various > things, but these are Matlab's implementation issues. > Not necessarily. Compiled loops will often be somewhat faster than equivalent vectorized code. Look at the original example - in the loopy code, there's two inner loops; one is zeros() and one the fill. Compared to that, the semi-vectorized case comprises three loops, which the JIT compiler may or may not (apparently not in this case) be able to merge. I intentionally wrote "semi-vectorized" because, from Octave's point of view, neither code is vectorized. I'm sure that in Octave, the "interpreter overhead" plays the major part in *both* cases. Such example is just unrealistic for real-life coding in Octave, because it actually failed to vectorize anything. Vectorizing an inner loop often helps, but not when the ratio inner:outer number of cycles is 1:1e6. To get good performance, generally the ratio inner:outer should be at most 1 in terms of orders of magnitude. A final thought about the JIT compilation: Imprecisely quoting MathWorks site, "MathWorks is committed to make Matlab as fast as traditional HPC languages such as C, C++ and Fortran". Besides the general unreasonability of the statement (comparing speed of languages is usually a nonsense), I consider this a clever marketing strategy. MathWorks surely realizes that the MEX interface sucks. I think there were number of third-party attempts to create an OOP interface to the Matlab engine, but MathWorks adopted none, neither they invented their own one. And for good reason, I think - improving interoperability with C/C++/Fortran could make customers to invest in compilers and better C/C++/Fortran programming skills. On the contrary, the situation where everything is written in the Matlab language is much more favorable for the company - in case your code is not fast enough, your best option is to buy a newer Matlab and hope the JIT compiler has improved enough to do what you meant to do. I think Matlab comes with little documentation on what exactly the JIT compiler can handle, let alone any guarantees, so you're entirely left at its mercy. In short, Matlab is now improving in the area where C and Fortran compilers have been shining for decades. The Matlab language was designed to be interpreted, and is almost uniquely ill-suited for compilation. Despite that, the company made remarkable progress in teaching the elephant to dance. Of course, MathWorks needed some way forward, or they would lose revenues, and they picked up this one. But that does not necessarily mean Octave will follow. I daresay that most of those who actively contribute to Octave *can* speak C, C++ or Fortran. And people will not stop using C, C++ and Fortran anywhere in near future. So I don't reckon Octave will JIT-compile in near future; I think there's just not enough interest. Still, I might be wrong. regards -- RNDr. Jaroslav Hajek computing expert & GNU Octave developer Aeronautical Research and Test Institute (VZLU) Prague, Czech Republic url: www.highegg.matfyz.cz From choonway at gmail.com Tue Sep 15 02:04:28 2009 From: choonway at gmail.com (Liao Choon Way) Date: Tue, 15 Sep 2009 00:04:28 -0700 (PDT) Subject: unofficial octave 3.2.2 msvc2008 solution/project files In-Reply-To: <25446848.post@talk.nabble.com> References: <25368142.post@talk.nabble.com> <25446848.post@talk.nabble.com> Message-ID: <25449018.post@talk.nabble.com> Hi, Oops. the folder should be in the root directory, where the README.* files are. Apologies, choonway. flyrain wrote: > > Hi choonway > ***************************************** > 1. download and unzip sources octave-3.2.2.tar.bz2 > 2. move the folder build_vc2008 inside the source folder > ***************************************** > does the point 2 means I should create a new folder named source and then > move the build_vs2008 inside? > there are some build errors.. > ****************************** > 2>Generating Code... > 2>Build log was saved at > "file://f:\Library\octave-3.2.2-msvc9-20090909.tar\octave-3.2.2-msvc9-20090909\octave-3.2.2\build_vs2008\libcruft\Debug\BuildLog.htm" > 2>libcruft - 3 error(s), 2865 warning(s) > 3>------ Build started: Project: liboctave, Configuration: Debug Win32 > ------ > 3>Compiling... > 3>Array-b.cc > 3>c1xx : fatal error C1083: Cannot open source file: > '..\..\liboctave\Array-b.cc': No such file or directory > 3>Array-C.cc > 3>c1xx : fatal error C1083: Cannot open source file: > '..\..\liboctave\Array-C.cc': No such file or directory > 3>Array-ch.cc > 3>c1xx : fatal error C1083: Cannot open source file: > '..\..\liboctave\Array-ch.cc': No such file or directory > 3>Array-d.cc > 3>c1xx : fatal error C1083: Cannot open source file: > '..\..\liboctave\Array-d.cc': No such file or directory > 3>Array-f.cc > 3>c1xx : fatal error C1083: Cannot open source file: > '..\..\liboctave\Array-f.cc': No such file or directory > 3>Array-fC.cc > ****************************** > > Liao Choon Way wrote: >> >> hi all, >> >> i have prepared a _rough_ set of files for those interested in embedding >> octave >> into windows applications and have problems with mingw dlls. >> >> Get them >> http://sourceforge.net/projects/el-rekka/files/octave-3.2.2-msvc9-20090909.tar.gz/download >> here . >> >> instructions enclosed. read before use. check the repository for updates. >> >> choonway >> > > -- View this message in context: http://www.nabble.com/unofficial-octave-3.2.2-msvc2008-solution-project-files-tp25368142p25449018.html Sent from the Octave - General mailing list archive at Nabble.com. From lgjsheron at gmail.com Tue Sep 15 01:41:46 2009 From: lgjsheron at gmail.com (Sheron Gerard Jeshuran) Date: Tue, 15 Sep 2009 12:41:46 +0600 Subject: Linespace Message-ID: <72ee9c210909142341h31615ff1nf87a9bb84c749706@mail.gmail.com> Dear SIr, I have a problem to draw a graph in Octave my function is f(x)=4-3x and also i need f inverse also, and new and the time i run the command following error message comes octave-3.2.2.exe:1:C:\Octave\3.2.2_gcc-4.3.0\bin > linespace(0, 2*pi, 100); error: `linespace' undefined near line 1 column 1 octave-3.2.2.exe:1:C:\Octave\3.2.2_gcc-4.3.0\bin > -- Sheron -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090915/5612f6d7/attachment-0001.html From mangostein17 at googlemail.com Tue Sep 15 03:58:21 2009 From: mangostein17 at googlemail.com (matt) Date: Tue, 15 Sep 2009 09:58:21 +0100 Subject: octave vs. matlab vectorization In-Reply-To: <6800c3890909141043g32e6891ds4bde74e8bc78ec71@mail.gmail.com> References: <343F894B-E4BD-43F7-9F2A-9383829E302C@gmail.com> <19118.32144.109057.627543@segfault.lan> <6800c3890909141043g32e6891ds4bde74e8bc78ec71@mail.gmail.com> Message-ID: <17E8A775-B0BD-4A2F-BB8B-DD1D09C6B6C0@gmail.com> hi james, good point! i have rechecked and the loop code *is* 5x quicker--this with matlab 7.5.0.338 and, i just noticed, matlab compiler 4.7. On 14 Sep 2009, at 18:43, James Sherman Jr. wrote: > >ah, no! code 1 was *faster* under matlab! the ratio is 0.19:1 > > > >i find this result quite staggering. > > I ran those two codes with the matlab I have on my laptop > (7.7.0.471 R2008b) and got 16.9 for the for loops code and 3.54 for > the vectorized code. > > I don't know why there would be such a discrepancy. This may sound > dumb, but are you sure you didn't confuse the two times? From mangostein17 at googlemail.com Tue Sep 15 04:28:35 2009 From: mangostein17 at googlemail.com (matt) Date: Tue, 15 Sep 2009 10:28:35 +0100 Subject: octave vs. matlab vectorization In-Reply-To: <19118.32144.109057.627543@segfault.lan> References: <343F894B-E4BD-43F7-9F2A-9383829E302C@gmail.com> <19118.32144.109057.627543@segfault.lan> Message-ID: <704BE6F4-E39F-40C5-B201-EDF8D97D5E6A@gmail.com> Hi John, First let me take this opportunity to thank you for all the great work you have done on Octave over the years. I am using it constantly and couldn't be happier. On vectorization issue, I was staggered for two reasons. First, I couldn't believe that Matlab had "given up" on software vectorization. Did they tell anyone?! I only really care because I sometimes send Octave code to Matlab users; it's nice to know what the differences are. The second reason is that I was surprised the JIT compiler worked as well as it did--to use Jaroslav's quote, the elephant can dance. Having said that, James found the vectorized code ran 5x faster on his Matlab--so who knows what is going on? Perhaps the Matlab compiler is cheating? Anyway, many thanks again for Octave. Best, Matt. On 14 Sep 2009, at 18:29, John W. Eaton wrote: > On 14-Sep-2009, matt wrote: > > | ah, no! code 1 was *faster* under matlab! the ratio is 0.19:1 > | > | i find this result quite staggering. > > Why? As someone else already explained, Matlab has a JIT compiler > that can, in some cases at least, compile loops into native code so > that it runs faster and Octave does not have a JIT compiler. > > jwe From mangostein17 at googlemail.com Tue Sep 15 07:01:05 2009 From: mangostein17 at googlemail.com (matt) Date: Tue, 15 Sep 2009 13:01:05 +0100 Subject: octave vs. matlab vectorization In-Reply-To: <69d8d540909142337o51b620b8sa76d3f48aa178200@mail.gmail.com> References: <343F894B-E4BD-43F7-9F2A-9383829E302C@gmail.com> <69d8d540909142337o51b620b8sa76d3f48aa178200@mail.gmail.com> Message-ID: <6CAC17DF-3E81-4E6F-9E5C-2CE07B3F847D@gmail.com> thanks for the insight on compiler issues. the matlab JIT compiler is doing something clever in the simple- minded codes i was experimenting with but i realise now that a lot of the problem is the overhead in allocating and defining arrays. i had a vector q of length 10. in the loops code, it was fast to check through it elementwise; in the (semi) vectorized code, time was being spent setting up q and also tmp and (tmp>50), both length 10. replacing 10 by 1000 puts the two codes on a par as now the overhead to set up the vectors is relatively small. in octave, of course, the vectorized version wins by miles. From soren at hauberg.org Tue Sep 15 08:22:14 2009 From: soren at hauberg.org (=?ISO-8859-1?Q?S=F8ren?= Hauberg) Date: Tue, 15 Sep 2009 15:22:14 +0200 Subject: Linespace In-Reply-To: <72ee9c210909142341h31615ff1nf87a9bb84c749706@mail.gmail.com> References: <72ee9c210909142341h31615ff1nf87a9bb84c749706@mail.gmail.com> Message-ID: <1253020934.14685.0.camel@sh-t400> tir, 15 09 2009 kl. 12:41 +0600, skrev Sheron Gerard Jeshuran: > Dear SIr, > > I have a problem to draw a graph in Octave my function is f(x)=4-3x > and also i need f inverse also, and new and the time i run the command > following error message comes > > octave-3.2.2.exe:1:C:\Octave\3.2.2_gcc-4.3.0\bin > > linespace(0, 2*pi, 100); > error: `linespace' undefined near line 1 column 1 > octave-3.2.2.exe:1:C:\Octave\3.2.2_gcc-4.3.0\bin The function you want is called 'linspace' From bpabbott at mac.com Tue Sep 15 08:23:01 2009 From: bpabbott at mac.com (Ben Abbott) Date: Tue, 15 Sep 2009 09:23:01 -0400 Subject: Linespace In-Reply-To: <72ee9c210909142341h31615ff1nf87a9bb84c749706@mail.gmail.com> References: <72ee9c210909142341h31615ff1nf87a9bb84c749706@mail.gmail.com> Message-ID: <7A60E532-D8B1-4FD2-AEF5-989919967A3E@mac.com> On Sep 15, 2009, at 2:41 AM, Sheron Gerard Jeshuran wrote: > Dear SIr, > > I have a problem to draw a graph in Octave my function is f(x)=4-3x > and also i need f inverse also, and new and the time i run the > command following error message comes > > octave-3.2.2.exe:1:C:\Octave\3.2.2_gcc-4.3.0\bin > > linespace(0, 2*pi, 100); > error: `linespace' undefined near line 1 column 1 > octave-3.2.2.exe:1:C:\Octave\3.2.2_gcc-4.3.0\bin > > Try "linspace" instead of "linespace". Ben From storrsjm at email.uc.edu Tue Sep 15 10:32:23 2009 From: storrsjm at email.uc.edu (Judd Storrs) Date: Tue, 15 Sep 2009 11:32:23 -0400 Subject: octave vs. matlab vectorization In-Reply-To: <704BE6F4-E39F-40C5-B201-EDF8D97D5E6A@gmail.com> References: <343F894B-E4BD-43F7-9F2A-9383829E302C@gmail.com> <19118.32144.109057.627543@segfault.lan> <704BE6F4-E39F-40C5-B201-EDF8D97D5E6A@gmail.com> Message-ID: On Tue, Sep 15, 2009 at 5:28 AM, matt wrote: > Having said that, James found the vectorized code ran 5x faster on > his Matlab--so who knows what is going on? Perhaps the Matlab > compiler is cheating? > I wouldn't call working well cheating ;) As it was explained to me when 7.0 came out, the JIT compiler is able to detect certain idioms and to replace them with very optimized code. In the 7.0 days it was pretty hit or miss whether the JIT optimizations would kick in or not and I remember at a training session that the application engineer from Mathworks described in great detail how to monkey around with loop structure and variable use in order to help the JIT detect the idioms. In the following years I imagine their idiom detection has improved substantially. --judd -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090915/c1c9fb17/attachment.html From arnoques at gmail.com Mon Sep 14 20:16:29 2009 From: arnoques at gmail.com (Pablo) Date: Mon, 14 Sep 2009 21:16:29 -0400 Subject: Randomly generate 10 different integers In-Reply-To: References: <7a394d4e0906301045v2c1f13b9gdff231dcac4cdd6@mail.gmail.com> Message-ID: <4AAEEAED.3020308@gmail.com> Rob Mahurin wrote: > On Jun 30, 2009, at 1:45 PM, Xin Dong wrote: >> I wanna randomly generate 10 different integers in a given range. I >> know I can use random function and discard duplicate values. But is >> there any other simple way to do it? > > One way is > > [junk, index] = sort(rand(1,10)); > disp(index) > > Rob > I had to do this recently. The above example just gives a random permutation of the numbers 1 to 10 (the randperm function does exactly that). To get N random numbers from dmin to dmax you sholud do: D = randperm(dmax - dmin + 1); D = D(:,1:N); D = D + dmin - 1; This is not very efficient if you need to select very few numbers, or almost all, from a very large range, because I was not interested in the order of the numbers, and you have to sort every number of the range. If you have a very large range (I used randperm(10000), and it gets VERY slow!) you might replace the above with a custom sort function, that only sorts the first N numbers. That way, you can shave off a LOT of time. I know this comes a little late, but it might still help somebody! Arnoques From donwalkertt at hotmail.com Tue Sep 15 12:27:10 2009 From: donwalkertt at hotmail.com (donwalker) Date: Tue, 15 Sep 2009 10:27:10 -0700 (PDT) Subject: LSODE-opts.h Message-ID: <25458273.post@talk.nabble.com> // Generated automatically from LSODE-opts.in. ... #include ... I am using a tutorial I found for using octave functions in C++. One of the examples uses LSODE-opts.h. The line above generates an error. Shouldn't it be #include "ODE.h" ? Thanks for help from anyone -- View this message in context: http://www.nabble.com/LSODE-opts.h-tp25458273p25458273.html Sent from the Octave - General mailing list archive at Nabble.com. From tmacchant at yahoo.co.jp Tue Sep 15 13:33:45 2009 From: tmacchant at yahoo.co.jp (Tatsuro MATSUOKA) Date: Wed, 16 Sep 2009 03:33:45 +0900 (JST) Subject: Linespace In-Reply-To: <72ee9c210909142341h31615ff1nf87a9bb84c749706@mail.gmail.com> Message-ID: <20090915183345.63295.qmail@web3814.mail.bbt.yahoo.co.jp> Hello I guess that 'lin' means 'linear' so that 'lin' is proper than 'line' as an abbreviation. For logarithmic scale, the 'logspace' is used. Regards Tatsuro --- Sheron Gerard Jeshuranwrote: > Dear SIr, > > I have a problem to draw a graph in Octave my function is f(x)=4-3x and also > i need f inverse also, and new and the time i run the command following > error message comes > > octave-3.2.2.exe:1:C:\Octave\3.2.2_gcc-4.3.0\bin > > linespace(0, 2*pi, 100); > error: `linespace' undefined near line 1 column 1 > octave-3.2.2.exe:1:C:\Octave\3.2.2_gcc-4.3.0\bin > > > > > -- > Sheron > > _______________________________________________ > Help-octave mailing list > Help-octave at octave.org > https://www-old.cae.wisc.edu/mailman/listinfo/help-octave > -------------------------------------- Thanks 10 years! Yahoo! Shopping and Yahoo! Auctions http://pr.mail.yahoo.co.jp/ec10years/ From fl at ifi.uio.no Tue Sep 15 14:20:22 2009 From: fl at ifi.uio.no (Fredrik Lingvall) Date: Tue, 15 Sep 2009 21:20:22 +0200 Subject: avifile (and all that jazz) In-Reply-To: <887085.21640.qm@web30205.mail.mud.yahoo.com> References: <887085.21640.qm@web30205.mail.mud.yahoo.com> Message-ID: <355366570909151220i340b68b5sffb8ebcd9ea1929c@mail.gmail.com> You can do this by generating a series of, for example, png-images and then let mencoder put them together to an avi-file. Something like: png_path = 'png/'; for k=1:K % Plot the k:th image here. image(A(:,:,k)); if k<10 eval(['print("' png_path 'snapshot_000' num2str(k) '.png", "-dpng");']); elseif k<100 eval(['print("' png_path 'snapshot_00' num2str(k) '.png", "-dpng");']); elseif k<1000 eval(['print("' png_path 'snapshot_0' num2str(k) '.png", "-dpng");']); else eval(['print("' png_path 'snapshot_' num2str(k) '.png", "-dpng");']); end end system(['mencoder -quiet mf://png/*.png -mf w=640:h=480:fps=' ... '25:type=png -ovc lavc -lavcopts vcodec=wmv1 -oac copy -' ... 'o snapshots.avi']); /Fredrik On Fri, Sep 11, 2009 at 8:19 PM, Kristen Richter wrote: > Dear helpful mailing list, > > I am attempting to turn a series of plots into an avifile. While I've > installed the video add-on package from Octave-forge, I can't add frames to > my .avi because the AVHandler can't seem to find the appropriate codecs. > Using the example below, found here: > http://neacm.fe.up.pt/pub/octave/MAILING-LISTS/help-octave/2005/3694 > > # Open the AVI file > m = avifile("test.avi", "codec", "msmpeg4v2") > > # Generate and add frames > for i = 1:100 > I = zeros(100,100); > I(i,:) = i; > I(:,i) = 200-i; > addframe(m, I/255) > printf(".") > endfor > printf("\n") > > # Close the file > clear mI get the following error: > > AVHandler: cannot find codec msmpeg4v2 > error: avifile: AVHandler setup failed > addframe: error adding frame to avifile > I've tried the example, specifying many different codecs, including > cinepak, indeo5, and indeo3. I've checked my synaptic package manager for > appropriate codecs... currently I've installed libavifile (vs. 0.7), which > mentions the indeo library by name. > > Are the codecs supposed to be installed in a specific directory? Has anyone > come across similar issues in the past? > The example is pretty old... dated 2005, and I know the video package was > updated last this past May. > > Any insight on the situation would be greatly appreciated. As always, your > help in the past has been invaluable. > > -Kristen Richter > > By the way, does anyone know of a good work around for the getframe > function?... I have yet to think of a good way to capture the figure on the > screen into an appropriately formatted image matrix. > > > > _______________________________________________ > Help-octave mailing list > Help-octave at octave.org > https://www-old.cae.wisc.edu/mailman/listinfo/help-octave > -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090915/c7dab22c/attachment.html From soren at hauberg.org Tue Sep 15 14:26:20 2009 From: soren at hauberg.org (=?ISO-8859-1?Q?S=F8ren?= Hauberg) Date: Tue, 15 Sep 2009 21:26:20 +0200 Subject: avifile (and all that jazz) In-Reply-To: <355366570909151220i340b68b5sffb8ebcd9ea1929c@mail.gmail.com> References: <887085.21640.qm@web30205.mail.mud.yahoo.com> <355366570909151220i340b68b5sffb8ebcd9ea1929c@mail.gmail.com> Message-ID: <1253042780.4603.5.camel@sh-t400> I believe this block > if k<10 > eval(['print("' png_path 'snapshot_000' num2str(k) '.png", > "-dpng");']); > elseif k<100 > eval(['print("' png_path 'snapshot_00' num2str(k) '.png", > "-dpng");']); > elseif k<1000 > eval(['print("' png_path 'snapshot_0' num2str(k) '.png", > "-dpng");']); > else > eval(['print("' png_path 'snapshot_' num2str(k) '.png", > "-dpng");']); > end can be replaced by print (sprintf ("%s/snapshot_%.5d.png", png_path, k)); but I haven't tested it, so it might need slight alterations. I principle you should be using 'fullfile' concatenate the directory name with the file name as that would give you platform independence, but I didn't bother doing that here. S?ren From estebanvoehringer at hotmail.com Tue Sep 15 15:14:25 2009 From: estebanvoehringer at hotmail.com (esteban1) Date: Tue, 15 Sep 2009 13:14:25 -0700 (PDT) Subject: regdatasmooth Message-ID: <25461009.post@talk.nabble.com> Hi, I have a problem with the regdatasmooth function implemented in the data-smoothing-1.2.0 package. Whenever I want to run a demo or the function itself I get the following error: error: unary operator `'' not implemented for `list' operands. The regdatasmooth function calls the rgdtsmcore function. This function works fine, when I run it with my parameters. But I would like to use regdatasmooth since it optimizes the smoothing through lambda and other parameters. I allready searched the web and the mailing list but I was not able to find something. Thanks for the help! -- View this message in context: http://www.nabble.com/regdatasmooth-tp25461009p25461009.html Sent from the Octave - General mailing list archive at Nabble.com. From sttt at gmx.de Tue Sep 15 12:28:07 2009 From: sttt at gmx.de (Steffen Titze) Date: Tue, 15 Sep 2009 19:28:07 +0200 Subject: Load data with script Message-ID: <4AAFCEA7.50903@gmx.de> Hello, i have written a script to load some values from a data file. With old version of octave (3.0.3) i don?t had anyproblems. But with the new version i cann?t load the data file with the script. if i load the data file with same syntax with out the script, i don?t have any problems. x = load ('C:\Test\090811.txt') Error massage with script error: invalid call to script How can i solve the problem? I use a windows pc. Thanks Steffen From jwe at octave.org Wed Sep 16 02:45:30 2009 From: jwe at octave.org (John W. Eaton) Date: Wed, 16 Sep 2009 03:45:30 -0400 Subject: Load data with script In-Reply-To: <4AAFCEA7.50903@gmx.de> References: <4AAFCEA7.50903@gmx.de> Message-ID: <19120.38810.727236.986407@segfault.lan> On 15-Sep-2009, Steffen Titze wrote: | i have written a script to load some values from a data file. With old | version of octave (3.0.3) i don?t had anyproblems. But with the new | version i cann?t load the data file with the script. | | if i load the data file with same syntax with out the script, i don?t | have any problems. | | x = load ('C:\Test\090811.txt') | | Error massage with script | error: invalid call to script | | How can i solve the problem? I use a windows pc. Is there a load.m file somewhere in Octave's path? Try which load and see what it tells you. jwe From ct529 at york.ac.uk Wed Sep 16 03:10:37 2009 From: ct529 at york.ac.uk (Corrado) Date: Wed, 16 Sep 2009 09:10:37 +0100 Subject: What did I do wrong with this funtion? - Implementing msplines and isplines in Octave Message-ID: <200909160910.37821.ct529@york.ac.uk> Dear friends, I am trying to implement in Octave the two spline families as in the documentation here below attached. I am a newbie to Octave, and this is my first function. I built the function: function retspline = mspline (i,x,k,t) # i is the spline index in the family # x is the variable # t is the vector of knots, t(h) is the h-th knot # k is the Mspline degree I=i if(k==1) if(x=t(i)) td=t(i+1)-t(i) M=1/td else M=0 endif else kk=(k-1) if (x>=t(i) & x=t(i+k)) M=0 endif endif retspline=M endfunction but for some reason it does not work .... I add that I am a newbie with Octave, please do not shut me. What did I do wrong? Best, -- Corrado Topi Global Climate Change & Biodiversity Indicators Area 18,Department of Biology University of York, York, YO10 5YW, UK Phone: + 44 (0) 1904 328645, E-mail: ct529 at york.ac.uk -------------- next part -------------- A non-text attachment was scrubbed... Name: mspline Type: image/png Size: 71260 bytes Desc: not available Url : https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090916/3421d5ed/attachment-0002.png -------------- next part -------------- A non-text attachment was scrubbed... Name: ispline.png Type: image/png Size: 51862 bytes Desc: not available Url : https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090916/3421d5ed/attachment-0003.png From highegg at gmail.com Wed Sep 16 04:26:43 2009 From: highegg at gmail.com (Jaroslav Hajek) Date: Wed, 16 Sep 2009 11:26:43 +0200 Subject: What did I do wrong with this funtion? - Implementing msplines and isplines in Octave In-Reply-To: <200909160910.37821.ct529@york.ac.uk> References: <200909160910.37821.ct529@york.ac.uk> Message-ID: <69d8d540909160226x9b81ad8l4be77f639b5b1a3b@mail.gmail.com> On Wed, Sep 16, 2009 at 10:10 AM, Corrado wrote: > Dear friends, > > I am trying to implement in Octave the two spline families as in the > documentation here below attached. I am a newbie to Octave, and this is my > first function. > > I built the function: > > function retspline = mspline (i,x,k,t) > ? ? ? ?# i is the spline index in the family > ? ? ? ?# x is the variable > ? ? ? ?# t is the vector of knots, t(h) is the h-th knot > ? ? ? ?# k is the Mspline degree > > ? ? ? ?I=i > > ? ? ? ?if(k==1) > > ? ? ? ? ? ? ? ?if(x=t(i)) > ? ? ? ? ? ? ? ? ? ? ? ?td=t(i+1)-t(i) > ? ? ? ? ? ? ? ? ? ? ? ?M=1/td > ? ? ? ? ? ? ? ?else > ? ? ? ? ? ? ? ? ? ? ? ?M=0 > ? ? ? ? ? ? ? ?endif > > ? ? ? ?else > > ? ? ? ? ? ? ? ?kk=(k-1) > > ? ? ? ? ? ? ? ?if (x>=t(i) & x ? ? ? ? ? ? ? ? ? ? ? ?M=k*((x-t(i))*mspline(i=I,x=x,k=kk,t=t)+(t(i+k)- > x)*mspline(i=(I+1),x=x,k=kk,t=t))/((k-1)*(t(i+k)-t(i))) > ? ? ? ? ? ? ? ?elseif (x=t(i+k)) > ? ? ? ? ? ? ? ? ? ? ? ?M=0 > ? ? ? ? ? ? ? ?endif > > ? ? ? ?endif > > ? ? ? ?retspline=M > > endfunction > > but for some reason it does not work .... > > I add that I am a newbie with Octave, please do not shut me. > > What did I do wrong? > > Best, > -- > Corrado Topi > You're probably misinterpreting the expression `mspline(i=I,x=x,k=kk,t=t)' (did you program in Python or Fortran?) In Octave, there is no passing parameters by name, and the expression is interpreted like in C, so that it means: i=I,x=x,k=kk,t=t,mspline(i,x,k,t) which probably spoils your script by overwriting variables. I didn't check for other problems. Note that even if you succeed, this will be a very inefficient implementation in Octave, but probably good enough to start programming. hth -- RNDr. Jaroslav Hajek computing expert & GNU Octave developer Aeronautical Research and Test Institute (VZLU) Prague, Czech Republic url: www.highegg.matfyz.cz From ct529 at york.ac.uk Wed Sep 16 04:33:11 2009 From: ct529 at york.ac.uk (Corrado) Date: Wed, 16 Sep 2009 10:33:11 +0100 Subject: What did I do wrong with this funtion? - Implementing msplines In-Reply-To: <69d8d540909160226x9b81ad8l4be77f639b5b1a3b@mail.gmail.com> References: <200909160910.37821.ct529@york.ac.uk> <69d8d540909160226x9b81ad8l4be77f639b5b1a3b@mail.gmail.com> Message-ID: <200909161033.11564.ct529@york.ac.uk> Dear Jaroslav, thanks for your help. I prototyped using R originally, and then rewrote it in Octave. Two quick questions: 1) How can I make the function more efficient? 2) Do you think I should rather write it in Fortran or any other language, instead of Octave? Regards On Wednesday 16 September 2009 10:26:43 Jaroslav Hajek wrote: > On Wed, Sep 16, 2009 at 10:10 AM, Corrado wrote: > > Dear friends, > > > > I am trying to implement in Octave the two spline families as in the > > documentation here below attached. I am a newbie to Octave, and this is > > my first function. > > > > I built the function: > > > > function retspline = mspline (i,x,k,t) > > # i is the spline index in the family > > # x is the variable > > # t is the vector of knots, t(h) is the h-th knot > > # k is the Mspline degree > > > > I=i > > > > if(k==1) > > > > if(x=t(i)) > > td=t(i+1)-t(i) > > M=1/td > > else > > M=0 > > endif > > > > else > > > > kk=(k-1) > > > > if (x>=t(i) & x > M=k*((x-t(i))*mspline(i=I,x=x,k=kk,t=t)+(t(i+k)- > > x)*mspline(i=(I+1),x=x,k=kk,t=t))/((k-1)*(t(i+k)-t(i))) > > elseif (x=t(i+k)) > > M=0 > > endif > > > > endif > > > > retspline=M > > > > endfunction > > > > but for some reason it does not work .... > > > > I add that I am a newbie with Octave, please do not shut me. > > > > What did I do wrong? > > > > Best, > > -- > > Corrado Topi > > You're probably misinterpreting the expression > `mspline(i=I,x=x,k=kk,t=t)' (did you program in Python or Fortran?) > In Octave, there is no passing parameters by name, and the expression > is interpreted like in C, so that it means: > i=I,x=x,k=kk,t=t,mspline(i,x,k,t) > which probably spoils your script by overwriting variables. I didn't > check for other problems. > Note that even if you succeed, this will be a very inefficient > implementation in Octave, but probably good enough to start > programming. > > hth -- Corrado Topi Global Climate Change & Biodiversity Indicators Area 18,Department of Biology University of York, York, YO10 5YW, UK Phone: + 44 (0) 1904 328645, E-mail: ct529 at york.ac.uk From highegg at gmail.com Wed Sep 16 04:45:27 2009 From: highegg at gmail.com (Jaroslav Hajek) Date: Wed, 16 Sep 2009 11:45:27 +0200 Subject: What did I do wrong with this funtion? - Implementing msplines In-Reply-To: <200909161033.11564.ct529@york.ac.uk> References: <200909160910.37821.ct529@york.ac.uk> <69d8d540909160226x9b81ad8l4be77f639b5b1a3b@mail.gmail.com> <200909161033.11564.ct529@york.ac.uk> Message-ID: <69d8d540909160245i5ee2d7d8y17b89cd01587cdd9@mail.gmail.com> On Wed, Sep 16, 2009 at 11:33 AM, Corrado wrote: > Dear Jaroslav, > > thanks for your help. I prototyped using R originally, and then rewrote it in > Octave. Two quick questions: > > 1) How can I make the function more efficient? I can hardly give advices given my little knowledge about your problem, but it seems to me that M forms a sort of divided-differences table, which is common with splines. In such case, it is much better to build the table using loops (this is true for any language) and vectorize the inner loops (this is for Octave). > 2) Do you think I should rather write it in Fortran or any other language, > instead of Octave? > With Fortran or C++ you can often (but not always) achieve a higher performance, but my common practice is write in Octave first, debug etc, and possibly recode later if more performance is needed. Octave is just ideal for that sort of work. Btw. please DON'T change the subject of the topic arbitrarily, it confuses mailers. hth -- RNDr. Jaroslav Hajek computing expert & GNU Octave developer Aeronautical Research and Test Institute (VZLU) Prague, Czech Republic url: www.highegg.matfyz.cz From ct529 at york.ac.uk Wed Sep 16 04:53:21 2009 From: ct529 at york.ac.uk (Corrado) Date: Wed, 16 Sep 2009 10:53:21 +0100 Subject: What did I do wrong with this funtion? - Implementing msplines In-Reply-To: <69d8d540909160245i5ee2d7d8y17b89cd01587cdd9@mail.gmail.com> References: <200909160910.37821.ct529@york.ac.uk> <200909161033.11564.ct529@york.ac.uk> <69d8d540909160245i5ee2d7d8y17b89cd01587cdd9@mail.gmail.com> Message-ID: <200909161053.21313.ct529@york.ac.uk> On Wednesday 16 September 2009 10:45:27 Jaroslav Hajek wrote: > Btw. please DON'T change the subject of the topic arbitrarily, it > confuses mailers. I did not change the subject at all .... why are you saying that? -- Corrado Topi Global Climate Change & Biodiversity Indicators Area 18,Department of Biology University of York, York, YO10 5YW, UK Phone: + 44 (0) 1904 328645, E-mail: ct529 at york.ac.uk From highegg at gmail.com Wed Sep 16 04:56:53 2009 From: highegg at gmail.com (Jaroslav Hajek) Date: Wed, 16 Sep 2009 11:56:53 +0200 Subject: What did I do wrong with this funtion? - Implementing msplines In-Reply-To: <200909161053.21313.ct529@york.ac.uk> References: <200909160910.37821.ct529@york.ac.uk> <200909161033.11564.ct529@york.ac.uk> <69d8d540909160245i5ee2d7d8y17b89cd01587cdd9@mail.gmail.com> <200909161053.21313.ct529@york.ac.uk> Message-ID: <69d8d540909160256n21a2bc96w239b9cb54a1de42e@mail.gmail.com> On Wed, Sep 16, 2009 at 11:53 AM, Corrado wrote: > On Wednesday 16 September 2009 10:45:27 Jaroslav Hajek wrote: >> Btw. please DON'T change the subject of the topic arbitrarily, it >> confuses mailers. > > I did not change the subject at all .... why are you saying that? > > -- > Corrado Topi > > Global Climate Change & Biodiversity Indicators > Area 18,Department of Biology > University of York, York, YO10 5YW, UK > Phone: + 44 (0) 1904 328645, E-mail: ct529 at york.ac.uk > > Your first message was "What did I do wrong with this funtion? - Implementing msplines and isplines in Octave" but your subsequent replies had the subject "Re: What did I do wrong with this funtion? - Implementing msplines" (trailing words truncated). If this happened without your intention, maybe your mailer is misconfigured, but it surely isn't a good idea. -- RNDr. Jaroslav Hajek computing expert & GNU Octave developer Aeronautical Research and Test Institute (VZLU) Prague, Czech Republic url: www.highegg.matfyz.cz From ct529 at york.ac.uk Wed Sep 16 05:38:36 2009 From: ct529 at york.ac.uk (Corrado) Date: Wed, 16 Sep 2009 11:38:36 +0100 Subject: What did I do wrong with this funtion? - Implementing msplines In-Reply-To: <69d8d540909160245i5ee2d7d8y17b89cd01587cdd9@mail.gmail.com> References: <200909160910.37821.ct529@york.ac.uk> <200909161033.11564.ct529@york.ac.uk> <69d8d540909160245i5ee2d7d8y17b89cd01587cdd9@mail.gmail.com> Message-ID: <200909161138.36444.ct529@york.ac.uk> Dear Octave list, I reached a point where the Octave prototype of the mspline function works really well, and produces the desired output. The final function can be downloaded from here: http://scsys.co.uk:8002/33893 And the bibliographic reference is attached to the email in jpeg image format (mspline_.jpeg). Now the mspline(i,x,k,t) function returns the correct value when I pass a real number on as x. For example: t=[0,0,0,.3,.5,.6,1,1,1] mspline(1,.02,3,t) returns the correct value. I would now like to optimise it so that if I pass as x a vector of values or a matrix, the function does transform the vector / matrix (that is all values in them) in an efficient way. The idea is to create a "for" cycle that spans the entire vector or matrix, which calls the mspline function and applies it to each element of the vector or matrix. Is that a good idea? Any alternative suggestion? I particular: 1) What language to use for higher performance (Octave, Fortran, ....) 2) How to change the structure of the function so that it is better performing in Octave. Please remember I am an Octave newbie, and this is my first attempt at writing a package. The aim of the package is to provide mspline and ispline based regressions on large size distance matrices to Octave. Regards -- Corrado Topi Global Climate Change & Biodiversity Indicators Area 18,Department of Biology University of York, York, YO10 5YW, UK Phone: + 44 (0) 1904 328645, E-mail: ct529 at york.ac.uk -------------- next part -------------- A non-text attachment was scrubbed... Name: mspline_.jpeg Type: image/jpeg Size: 18384 bytes Desc: not available Url : https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090916/df8b47b6/attachment-0001.jpeg From Potorti at isti.cnr.it Wed Sep 16 07:43:45 2009 From: Potorti at isti.cnr.it (Francesco Potorti`) Date: Wed, 16 Sep 2009 14:43:45 +0200 Subject: avifile (and all that jazz) In-Reply-To: <355366570909151220i340b68b5sffb8ebcd9ea1929c@mail.gmail.com> References: <887085.21640.qm@web30205.mail.mud.yahoo.com> <355366570909151220i340b68b5sffb8ebcd9ea1929c@mail.gmail.com> Message-ID: >You can do this by generating a series of, for example, png-images and then >let mencoder put them together to an avi-file. Or else use this function of mine. By the way, wahat people think: would it be reasonable to add it to the video package? function movie (action, mmov="octave_movie.mp4") ## Create a movie from plots ## ## Example usage: ## figure("visible","off"); movie("init") ## a=zeros(100,100); a(1:20,41:60)=1; ## for i=1:100; a=shift(a,1); imshow(a); movie("add"); endfor ## movie("close"); close; system("totem octave_movie.mp4") ## ## There are three commands used as first argment: "init", "add", ## "close". By default, a movie named "octave_movie.mp4" is created ## using ffmpeg. An optional second argument allows one changing both ## the name and the type of movie. The type ".dir" creates a ## directory containing a png file per frame. The type ".zip" ## archives it using zip. Types ".mp4", ".ogg", ".mov", ".mjpeg", ## ".avi", ".flv" are created using ffmpeg; types ".mng", ".gif" are ## created using convert; type ".swf" is created using png2swf. You ## must have the relevant program installed to create a movie with the ## corresponding extension; no program is required for ".dir". ## Francesco Potort?, 2008 ## Revision 1.10 ## License: GPL version 3 or later verbose = false; rate = 5; # frames per second actions = {"init" "add" "close"}; # gif swf types = {".mp4" ".mng" ".gif" ".zip" ".ogg" ".swf" ".mov" ... ".mjpeg" ".avi" ".flv" ".dir"}; if (nargin < 1 || !ischar(action) || !any(strcmp(action, actions))) error("first argument must be one of:%s", sprintf(" %s",actions{:})); endif if (nargin != 2 || !ischar(mmov)) error("second arg must be a string"); endif [mpath mname mtype] = fileparts(mmov); mdir = fullfile(mpath, [mname ".d"]); ppat = "%06d.png"; mpat = fullfile(mdir, ppat); mglob = fullfile(mdir, strrep(sprintf(ppat,0),"0","[0-9]")); fnof = fullfile(mdir, "+frame-number+"); switch (action) case actions{1} # init a movie if (isdir(mmov)) cleandir(mmov, verbose) else unlink(mmov); endif while (!([allgood msg] = mkdir(mdir))) if (stat(fnof) && load(fnof).frameno == 0) error("while creating dir '%s': %s", mdir, msg); else cleandir(mdir, verbose); endif endwhile frameno = 0; save("-text",fnof,"frameno"); if (verbose) printf("Directory '%s' created.\n", mdir); endif case actions{2} # add a frame load(fnof); mfile = sprintf(mpat, ++frameno); drawnow("png", mfile); save("-text",fnof,"frameno"); if (verbose) printf("Frame '%s' added.\n", mfile); endif case actions{3} # close the movie switch (mtype) case {types{[1 5 7 8 9 10]}} # mp4, ogg, mov, mjpeg, avi, flv cmd = sprintf("ffmpeg -y -r %d -sameq -i %s %s 2>&1", rate, mpat, mmov); case {types{[2 3]}} # mng, gif cmd = sprintf("convert %s -adjoin %s 2>&1", mglob, mpat); case types{4} # zip cmd = sprintf("zip -qr9 %s %s 2>&1", mmov, mglob); case types{6} # swf cmd = sprintf("png2swf -z -r %d -o %s %s", rate, mmov, mglob); case types{end} # dir rename(mdir, mmov); return otherwise error("second arg must end with one of:%s", sprintf(" %s",types{:})); endswitch [status output] = system(cmd); if (status != 0) load(fnof); error("Creation of movie '%s' containing %d frames failed:\n%s", mmov, frameno, output); endif if (verbose) printf("Movie '%s' contains %d frames:\n%s", mmov, frameno, output); endif cleandir(mdir, verbose); endswitch endfunction function cleandir(mdir, verbose) unwind_protect save_crr = confirm_recursive_rmdir(false); [allgood msg] = rmdir(mdir,"s"); if (!allgood) error("while removing dir '%s': %s", mdir, msg); endif unwind_protect_cleanup confirm_recursive_rmdir(save_crr); end_unwind_protect if (verbose) printf("Directory '%s' removed\n", mdir); endif endfunction -- Francesco Potort? (ricercatore) Voice: +39 050 315 3058 (op.2111) ISTI - Area della ricerca CNR Fax: +39 050 315 2040 via G. Moruzzi 1, I-56124 Pisa Email: Potorti at isti.cnr.it (entrance 20, 1st floor, room C71) Web: http://fly.isti.cnr.it/ From jjstickel at vcn.com Wed Sep 16 08:57:28 2009 From: jjstickel at vcn.com (Jonathan Stickel) Date: Wed, 16 Sep 2009 07:57:28 -0600 Subject: regdatasmooth In-Reply-To: References: Message-ID: <4AB0EEC8.3060508@vcn.com> On 9/16/09 help-octave-request at octave.org wrote: > Date: Tue, 15 Sep 2009 13:14:25 -0700 (PDT) > From: esteban1 > Subject: regdatasmooth > To: help-octave at octave.org > Message-ID: <25461009.post at talk.nabble.com> > Content-Type: text/plain; charset=us-ascii > > > Hi, > > I have a problem with the regdatasmooth function implemented in the > data-smoothing-1.2.0 package. Whenever I want to run a demo or the function > itself I get the following error: > error: unary operator `'' not implemented for `list' operands. > > The regdatasmooth function calls the rgdtsmcore function. This function > works fine, when I run it with my parameters. > > But I would like to use regdatasmooth since it optimizes the smoothing > through lambda and other parameters. > I allready searched the web and the mailing list but I was not able to find > something. > > Thanks for the help! There have been some changes to the optimization functions in Octave and Octave-forge recently. There is a new fminunc function with a different implementation in Octave that takes different arguments. To get the latest regdatasmooth, download it from here: http://octave.svn.sourceforge.net/viewvc/octave/trunk/octave-forge/main/data-smoothing/inst/ Unfortunately, there is a bug in Octave <= 3.2.2 related to cholesky factorizations that causes fminunc not to work for single variable functions. A patch is available that may be included in the upcoming 3.2.3 release (not completely sure). As a workaround, you may put the fminunc from /Octave-forge/ in a place in your path so that it supersedes the fminunc in /Octave/. If you do that, you should use the previous version of regdatasmooth (the one that is currently not working for you). Let me know if you have more trouble or if you get it working. Jonathan P.S. I am moving this thread to octave-dev since it is about an octave-forge function. When replying, please remove "help-octave" from the send list. From Pascal.Dupuis at worldonline.be Wed Sep 16 05:22:16 2009 From: Pascal.Dupuis at worldonline.be (Dupuis) Date: Wed, 16 Sep 2009 03:22:16 -0700 (PDT) Subject: Randomly generate 10 different integers In-Reply-To: <7a394d4e0906301045v2c1f13b9gdff231dcac4cdd6@mail.gmail.com> References: <7a394d4e0906301045v2c1f13b9gdff231dcac4cdd6@mail.gmail.com> Message-ID: <25469653.post@talk.nabble.com> Xin Dong wrote: > > Hi, > > I wanna randomly generate 10 different integers in a given range. I know I > can use random function and discard duplicate values. But is there any > other > simple way to do it? > > What you're searching for is an implementation of the Fisher-Yates algortihm, see http://en.wikipedia.org/wiki/Fisher?Yates_shuffle Here is a possible way: x=(1:10); n = length(x); while n >= 2, t = ceil(unifrnd(0, n)); %# returns 1 <= t <= n if (n != t), dummy = x(n); x(n) = x(t); x(t) = dummy; endif %# permute n = n - 1; endwhile -- View this message in context: http://www.nabble.com/Randomly-generate-10-different-integers-tp24277099p25469653.html Sent from the Octave - General mailing list archive at Nabble.com. From sttt at gmx.de Wed Sep 16 03:59:40 2009 From: sttt at gmx.de (Steffen Titze) Date: Wed, 16 Sep 2009 10:59:40 +0200 Subject: Load data with script In-Reply-To: <19120.38810.727236.986407@segfault.lan> References: <4AAFCEA7.50903@gmx.de> <19120.38810.727236.986407@segfault.lan> Message-ID: <20090916085940.226660@gmx.net> -------- Original-Nachricht -------- > Datum: Wed, 16 Sep 2009 03:45:30 -0400 > Von: "John W. Eaton" > An: Steffen Titze > CC: help-octave at octave.org > Betreff: Load data with script > On 15-Sep-2009, Steffen Titze wrote: > > | i have written a script to load some values from a data file. With old > | version of octave (3.0.3) i don?t had anyproblems. But with the new > | version i cann?t load the data file with the script. > | > | if i load the data file with same syntax with out the script, i don?t > | have any problems. > | > | x = load ('C:\Test\090811.txt') > | > | Error massage with script > | error: invalid call to script > | > | How can i solve the problem? I use a windows pc. > > Is there a load.m file somewhere in Octave's path? Try > > which load > > and see what it tells you. > > jwe "which load" tells me: load is a built-in-function in the Octave's path isn't a load.m file, also on my system i hadn't found a load.m file. -- Jetzt kostenlos herunterladen: Internet Explorer 8 und Mozilla Firefox 3 - sicherer, schneller und einfacher! http://portal.gmx.net/de/go/atbrowser From jwe at octave.org Wed Sep 16 11:09:45 2009 From: jwe at octave.org (John W. Eaton) Date: Wed, 16 Sep 2009 12:09:45 -0400 Subject: Load data with script In-Reply-To: <20090916085940.226660@gmx.net> References: <4AAFCEA7.50903@gmx.de> <19120.38810.727236.986407@segfault.lan> <20090916085940.226660@gmx.net> Message-ID: <19121.3529.662727.950169@segfault.lan> On 16-Sep-2009, Steffen Titze wrote: | -------- Original-Nachricht -------- | > Datum: Wed, 16 Sep 2009 03:45:30 -0400 | > Von: "John W. Eaton" | > An: Steffen Titze | > CC: help-octave at octave.org | > Betreff: Load data with script | | > On 15-Sep-2009, Steffen Titze wrote: | > | > | i have written a script to load some values from a data file. With old | > | version of octave (3.0.3) i don?t had anyproblems. But with the new | > | version i cann?t load the data file with the script. | > | | > | if i load the data file with same syntax with out the script, i don?t | > | have any problems. | > | | > | x = load ('C:\Test\090811.txt') | > | | > | Error massage with script | > | error: invalid call to script | > | | > | How can i solve the problem? I use a windows pc. | > | > Is there a load.m file somewhere in Octave's path? Try | > | > which load | > | > and see what it tells you. | > | > jwe | | "which load" tells me: | load is a built-in-function | | in the Octave's path isn't a load.m file, also on my system i hadn't found a load.m file. So what is the script that you are calling, and precisely how are you calling it? jwe From sttt at gmx.de Wed Sep 16 11:27:37 2009 From: sttt at gmx.de (Steffen Titze) Date: Wed, 16 Sep 2009 18:27:37 +0200 Subject: Load data with script In-Reply-To: <19121.3529.662727.950169@segfault.lan> References: <4AAFCEA7.50903@gmx.de> <19120.38810.727236.986407@segfault.lan> <20090916085940.226660@gmx.net> <19121.3529.662727.950169@segfault.lan> Message-ID: <4AB111F9.4050802@gmx.de> John W. Eaton schrieb: > On 16-Sep-2009, Steffen Titze wrote: > > | -------- Original-Nachricht -------- > | > Datum: Wed, 16 Sep 2009 03:45:30 -0400 > | > Von: "John W. Eaton" > | > An: Steffen Titze > | > CC: help-octave at octave.org > | > Betreff: Load data with script > | > | > On 15-Sep-2009, Steffen Titze wrote: > | > > | > | i have written a script to load some values from a data file. With old > | > | version of octave (3.0.3) i don?t had anyproblems. But with the new > | > | version i cann?t load the data file with the script. > | > | > | > | if i load the data file with same syntax with out the script, i don?t > | > | have any problems. > | > | > | > | x = load ('C:\Test\090811.txt') > | > | > | > | Error massage with script > | > | error: invalid call to script > | > | > | > | How can i solve the problem? I use a windows pc. > | > > | > Is there a load.m file somewhere in Octave's path? Try > | > > | > which load > | > > | > and see what it tells you. > | > > | > jwe > | > | "which load" tells me: > | load is a built-in-function > | > | in the Octave's path isn't a load.m file, also on my system i hadn't found a load.m file. > > So what is the script that you are calling, and precisely how are you > calling it? > > jwe > > it is a script to load a data file. The script is only a m file. At the time no function or call to a function is in the m file, i open only the data file and transfer the value martix to x. I comment the other things out, because at the beginning i thought their is a problem with the other code. But with verion 3.0.3 i hadn't any problems with the code. To call the m file i go to the folder of the m file in octave and start with "script.m" The m file and die Data.txt are in the same folder. Steffen From jwe at octave.org Wed Sep 16 12:01:54 2009 From: jwe at octave.org (John W. Eaton) Date: Wed, 16 Sep 2009 13:01:54 -0400 Subject: Load data with script In-Reply-To: <4AB111F9.4050802@gmx.de> References: <4AAFCEA7.50903@gmx.de> <19120.38810.727236.986407@segfault.lan> <20090916085940.226660@gmx.net> <19121.3529.662727.950169@segfault.lan> <4AB111F9.4050802@gmx.de> Message-ID: <19121.6658.414657.793801@segfault.lan> On 16-Sep-2009, Steffen Titze wrote: | it is a script to load a data file. | The script is only a m file. At the time no function or call to a | function is in the m file, i open only the data file and transfer the | value martix to x. I comment the other things out, because at the | beginning i thought their is a problem with the other code. But with | verion 3.0.3 i hadn't any problems with the code. | | To call the m file i go to the folder of the m file in octave and start | with "script.m" | The m file and die Data.txt are in the same folder. So the file is named script.m and you are typing script.m at the Octave prompt? Try typing script (without the .m extension). If that is the problem, then did you never see error: can't perform indexing operations for type when doing this with Octave 3.0.x? This used to happen because an expression like s.e is an expression to access the structure element E from the structure S. When you type script.m Octave evaluated "script" by calling the script then attempting to index the result with ".m". So the script was being evaluated, but since scripts don't return values, the indexing operation failed. Now, Octave recognizes in advance that "script" is a script, and since it can't produce a value for indexing, it gives you the error immediately instead of after evaluating the script. jwe From sttt at gmx.de Wed Sep 16 12:20:23 2009 From: sttt at gmx.de (Steffen Titze) Date: Wed, 16 Sep 2009 19:20:23 +0200 Subject: Load data with script In-Reply-To: <19121.6658.414657.793801@segfault.lan> References: <4AAFCEA7.50903@gmx.de> <19120.38810.727236.986407@segfault.lan> <20090916085940.226660@gmx.net> <19121.3529.662727.950169@segfault.lan> <4AB111F9.4050802@gmx.de> <19121.6658.414657.793801@segfault.lan> Message-ID: <4AB11E57.7080904@gmx.de> > So the file is named script.m and you are typing script.m at the > Octave prompt? Try typing script (without the .m extension). > > If that is the problem, then did you never see > > error: can't perform indexing operations for type > > when doing this with Octave 3.0.x? > > This used to happen because an expression like > > s.e > > is an expression to access the structure element E from the structure > S. When you type > > script.m > > Octave evaluated "script" by calling the script then attempting to > index the result with ".m". So the script was being evaluated, but > since scripts don't return values, the indexing operation failed. > > Now, Octave recognizes in advance that "script" is a script, and since > it can't produce a value for indexing, it gives you the error > immediately instead of after evaluating the script. > > jwe > > Thanks it works, when i call the script without the .m extension. i think i had never see this error message by Octave 3.0.x, Tomorrow i will test it on another system, where is Octave 3.0.3 still intalled. Steffen From dasergatskov at gmail.com Wed Sep 16 17:32:10 2009 From: dasergatskov at gmail.com (Dmitri A. Sergatskov) Date: Wed, 16 Sep 2009 17:32:10 -0500 Subject: plotting uint8 data Message-ID: <892b16670909161532o3c59d446v71d5cedc24d6cfae@mail.gmail.com> I have problems plotting uint8 type data. The data set seems to get truncated at index=256. I.e. if I do: x = uint8(100*(randn(1,300)+1)); plot(x) then only first 256 data points gets plotted. This is with 3.2.2 and a recent 4.3 cvs gnuplot.... Does anyone see the same? Sincerely, Dmitri. -- From rob at utk.edu Wed Sep 16 18:18:32 2009 From: rob at utk.edu (Rob Mahurin) Date: Wed, 16 Sep 2009 19:18:32 -0400 Subject: plotting uint8 data In-Reply-To: <892b16670909161532o3c59d446v71d5cedc24d6cfae@mail.gmail.com> References: <892b16670909161532o3c59d446v71d5cedc24d6cfae@mail.gmail.com> Message-ID: <20090916231831.GB12933@dyn219245190.dz.ornl.gov> On Wed, Sep 16, 2009 at 05:32:10PM -0500, Dmitri A. Sergatskov wrote: > I have problems plotting uint8 type data. The data set seems to get > truncated at index=256. I.e. if I do: > > x = uint8(100*(randn(1,300)+1)); > plot(x) > > then only first 256 data points gets plotted. > > This is with 3.2.2 and a recent 4.3 cvs gnuplot.... > > Does anyone see the same? I see this with 3.2.3rc4. A workaround is plot(double(x)). Cheers, Rob From dasergatskov at gmail.com Wed Sep 16 18:23:10 2009 From: dasergatskov at gmail.com (Dmitri A. Sergatskov) Date: Wed, 16 Sep 2009 18:23:10 -0500 Subject: plotting uint8 data In-Reply-To: <20090916231831.GB12933@dyn219245190.dz.ornl.gov> References: <892b16670909161532o3c59d446v71d5cedc24d6cfae@mail.gmail.com> <20090916231831.GB12933@dyn219245190.dz.ornl.gov> Message-ID: <892b16670909161623q2a676fd5s1559b324f4a8287f@mail.gmail.com> On Wed, Sep 16, 2009 at 6:18 PM, Rob Mahurin wrote: > On Wed, Sep 16, 2009 at 05:32:10PM -0500, Dmitri A. Sergatskov wrote: >> I have problems plotting uint8 type data. The data set seems to get >> truncated at index=256. I.e. if I do: >> >> x = uint8(100*(randn(1,300)+1)); >> plot(x) >> >> then only first 256 data points gets plotted. >> >> This is with 3.2.2 and a recent 4.3 cvs gnuplot.... >> >> Does anyone see the same? > > I see this with 3.2.3rc4. ?A workaround is plot(double(x)). I see it with 3.3.50 as well. I figure out the workaround, but I think it is a bug. It is somewhat strange to me that even plot(1:300, x) would fail. The data does not get disregarded, it is all plotted at x=256 (this is more obvious if one does plot(x,"o;;") or similar). > > Cheers, > Rob > Dmitri. -- From jwe at octave.org Wed Sep 16 19:01:35 2009 From: jwe at octave.org (John W. Eaton) Date: Wed, 16 Sep 2009 20:01:35 -0400 Subject: plotting uint8 data In-Reply-To: <892b16670909161623q2a676fd5s1559b324f4a8287f@mail.gmail.com> References: <892b16670909161532o3c59d446v71d5cedc24d6cfae@mail.gmail.com> <20090916231831.GB12933@dyn219245190.dz.ornl.gov> <892b16670909161623q2a676fd5s1559b324f4a8287f@mail.gmail.com> Message-ID: <19121.31839.828690.50008@segfault.lan> On 16-Sep-2009, Dmitri A. Sergatskov wrote: | On Wed, Sep 16, 2009 at 6:18 PM, Rob Mahurin wrote: | > On Wed, Sep 16, 2009 at 05:32:10PM -0500, Dmitri A. Sergatskov wrote: | >> I have problems plotting uint8 type data. The data set seems to get | >> truncated at index=256. I.e. if I do: | >> | >> x = uint8(100*(randn(1,300)+1)); | >> plot(x) | >> | >> then only first 256 data points gets plotted. | >> | >> This is with 3.2.2 and a recent 4.3 cvs gnuplot.... | >> | >> Does anyone see the same? | > | > I see this with 3.2.3rc4. ?A workaround is plot(double(x)). | | I see it with 3.3.50 as well. I figure out the workaround, but I think | it is a bug. | It is somewhat strange to me that even | plot(1:300, x) would fail. | The data does not get disregarded, it is all plotted at x=256 | (this is more obvious if one does plot(x,"o;;") or similar). This bug is only present in the gnuplot backend. With 3.3.50, it works as you would expect with the fltk backend. I'm no longer putting any effort into the gnuplot backend, but I would consider a contributed patch. jwe From david.sarraf at yahoo.com Wed Sep 16 22:00:43 2009 From: david.sarraf at yahoo.com (David Sarraf) Date: Wed, 16 Sep 2009 20:00:43 -0700 (PDT) Subject: gnuplot not working in RHEL4 32 bit In-Reply-To: <25347537.post@talk.nabble.com> References: <25347537.post@talk.nabble.com> Message-ID: <25484388.post@talk.nabble.com> I had the same problem using Octave under Fedora 11. Compiling from source per these instructions produced a working version. The pre-compiled .RPM file had numerous other bugs, including crashing with a dump of octave-core on simple errors such as divide by zero. The compiled version reports an error but does not crash the interpreter. Thanks for the guidance alynghy wrote: > > The problem is solved on RHEL 5.3 with the same errors : > > 1) Remove gnuplot from redhat : > > yum erase gnuplot > > 2) Remove libraries blas/lapack from redhat : > > yum erase lapack > yum erase blas > > 3) Remove oldies : > > yum erase compat-* > yum erase compat-lib* > > 4) Compile the last gnuplot and lapack : > > cd gnuplot-4.2.5 > ./configure > make > make install > cd .. > > AND > > cd lapack-3.2.1 > cp make.inc.example make.inc > make blaslib > make all > cp blas_LINUX.a /usr/local/lib/libblas.a > cp lapack_LINUX.a /usr/local/lib/liblapack.a > > 5) Compile octave : > > cd octave-3.2.2 > ./configure --with-blas=/usr/local/lib --with-lapack=/usr/local/lib > --enable-static LIBS=-lpthread > make > make install > > Best regards, > Benjamin > > > > kelvin-2 wrote: >> >> I have tried recompiling numerous times but the results have been >> consistenly unsatisfying. It should be noted that I am able to >> successfully install and plot on a 64 bit machine with RHEL4. Here are >> the error messages - does anyone know where to look or what might be >> preventing the tool from working with gnuplot? >> >> using octave-3.2.2 with gnuplot 4.3.0. >> >> bones:octave-3.2.2 >run-octave >> warning: lo_ieee_init: unrecognized floating point format! >> >> ... >> >> octave:1> plot(1:10) >> error: get: invalid handle (= 1.79769e+308) >> error: called from: >> error: >> /z/users/kmccollough/projects/octave-3.2.2/scripts/plot/__plt_get_axis_arg__.m >> at line 57, column 9 >> error: /z/users/kmccollough/projects/octave-3.2.2/scripts/plot/plot.m >> at line 178, column 18 >> octave:1> __gnuplot_version__ >> ans = 4.3.0 >> octave:2> >> >> Thanks, >> kelvin >> >> > > -- View this message in context: http://www.nabble.com/gnuplot-not-working-in-RHEL4-32-bit-tp25224366p25484388.html Sent from the Octave - General mailing list archive at Nabble.com. From jwe at octave.org Wed Sep 16 22:58:50 2009 From: jwe at octave.org (John W. Eaton) Date: Wed, 16 Sep 2009 23:58:50 -0400 Subject: OOP in Octave In-Reply-To: <7683DFC4-C36F-408E-A4E7-1A03AD77E352@swissonline.ch> References: <9830987E-56AA-4947-9FBA-C4C2700A0B1B@swissonline.ch> <4AAD26F9.100@dbateman.org> <7683DFC4-C36F-408E-A4E7-1A03AD77E352@swissonline.ch> Message-ID: <19121.46074.541221.808845@segfault.lan> On 14-Sep-2009, Lukas Reichlin wrote: | Thanks for your quick reply. Do you know when the new style should be | ready to use? (in one year, in two years or Octave 3.4, 3.6 ...) Octave development is almost entirely done by volunteers. As of now, I don't know of anyone who is actively working on this project. jwe From highegg at gmail.com Thu Sep 17 01:08:38 2009 From: highegg at gmail.com (Jaroslav Hajek) Date: Thu, 17 Sep 2009 08:08:38 +0200 Subject: Randomly generate 10 different integers In-Reply-To: <25469653.post@talk.nabble.com> References: <7a394d4e0906301045v2c1f13b9gdff231dcac4cdd6@mail.gmail.com> <25469653.post@talk.nabble.com> Message-ID: <69d8d540909162308m3a025ef8kea0c6d8827b732cb@mail.gmail.com> On Wed, Sep 16, 2009 at 12:22 PM, Dupuis wrote: > > > > Xin Dong wrote: >> >> Hi, >> >> I wanna randomly generate 10 different integers in a given range. I know I >> can use random function and discard duplicate values. But is there any >> other >> simple way to do it? >> >> > > What you're searching for is an implementation of the Fisher-Yates > algortihm, see http://en.wikipedia.org/wiki/Fisher?Yates_shuffle > > Here is a possible way: > x=(1:10); n = length(x); > while n >= 2, > ?t = ceil(unifrnd(0, n)); %# returns 1 <= t <= n > ?if (n != t), dummy = x(n); x(n) = x(t); x(t) = dummy; endif %# permute > ?n = n - 1; > endwhile > -- Btw., in current tip, randperm is a compiled function and implements the Fisher-Yates (Knuth) shuffle. It can also produce a set of permutations at once. -- RNDr. Jaroslav Hajek computing expert & GNU Octave developer Aeronautical Research and Test Institute (VZLU) Prague, Czech Republic url: www.highegg.matfyz.cz From ct529 at york.ac.uk Thu Sep 17 11:11:14 2009 From: ct529 at york.ac.uk (Topi, Corrado) Date: Thu, 17 Sep 2009 17:11:14 +0100 Subject: Solving a very strange minimization problem with Octave Message-ID: <4AB25FA2.1060507@york.ac.uk> Dear Octave-ians, I have to solve the following problem: min || D_ij - SUM p | SUM k A_pk Q_ij| || (1) or alternatively min (SUM_ij (D_ij - SUM p | SUM k A_pk Q_ij|)^2) (2) where I have to find the values of the Apk>=0 which minimize the distance (1) or alternatively the residual sum of square (2). The problem is the || aroud the second SUM. Is that feasible with Octave? All the D_ij, Q_ij are real numbers with 0 <= D_ij <= 1 D_ii =0 D_ij=D_ji for each i,j belonging to {1 .... n} I have been breaking my head on it for several days, read tons of documentation, and papers, and now I am going to ask as last resort .... Regards -- Corrado Topi Area 18,Department of Biology University of York, York, YO10 5YW, UK Phone: + 44 (0) 1904 328645, E-mail: ct529 at york.ac.uk From highegg at gmail.com Thu Sep 17 12:14:32 2009 From: highegg at gmail.com (Jaroslav Hajek) Date: Thu, 17 Sep 2009 19:14:32 +0200 Subject: Solving a very strange minimization problem with Octave In-Reply-To: <4AB25FA2.1060507@york.ac.uk> References: <4AB25FA2.1060507@york.ac.uk> Message-ID: <69d8d540909171014xf812ad0g4506922a9868c3c5@mail.gmail.com> On Thu, Sep 17, 2009 at 6:11 PM, Topi, Corrado wrote: > Dear Octave-ians, > > I have to solve the following problem: > > min || D_ij - SUM p | SUM k A_pk Q_ij| || (1) > given that Q_ij is not dependent on p,k, it is, using your notation, SUM p | SUM k A_pk Q_ij| = |Q_ij| SUM p | SUM k A_pk| = |Q_ij| * C and you need to minimize || D_ij - C*|Q_ij|||, i.e. a 2-norm of a linear combination of two given matrices? If not, please clarify your expression. -- RNDr. Jaroslav Hajek computing expert & GNU Octave developer Aeronautical Research and Test Institute (VZLU) Prague, Czech Republic url: www.highegg.matfyz.cz From ct529 at york.ac.uk Thu Sep 17 12:22:31 2009 From: ct529 at york.ac.uk (Topi, Corrado) Date: Thu, 17 Sep 2009 18:22:31 +0100 Subject: Solving a very strange minimization problem with Octave In-Reply-To: <69d8d540909171014xf812ad0g4506922a9868c3c5@mail.gmail.com> References: <4AB25FA2.1060507@york.ac.uk> <69d8d540909171014xf812ad0g4506922a9868c3c5@mail.gmail.com> Message-ID: <4AB27057.6060101@york.ac.uk> Dear Jaroslav, I apologize. The expression should read: min || D_ij - SUM p | SUM k A_pk Q_pkij| || (1) Regards Jaroslav Hajek wrote: > On Thu, Sep 17, 2009 at 6:11 PM, Topi, Corrado wrote: >> Dear Octave-ians, >> >> I have to solve the following problem: >> >> min || D_ij - SUM p | SUM k A_pk Q_ij| || (1) >> > > given that Q_ij is not dependent on p,k, it is, using your notation, > SUM p | SUM k A_pk Q_ij| = |Q_ij| SUM p | SUM k A_pk| = |Q_ij| * C and > you need to minimize || D_ij - C*|Q_ij|||, i.e. a 2-norm of a linear > combination of two given matrices? > > If not, please clarify your expression. > > -- Corrado Topi Area 18,Department of Biology University of York, York, YO10 5YW, UK Phone: + 44 (0) 1904 328645, E-mail: ct529 at york.ac.uk From hinow at uwm.edu Thu Sep 17 13:54:48 2009 From: hinow at uwm.edu (Peter Hinow) Date: Thu, 17 Sep 2009 13:54:48 -0500 (CDT) Subject: problem installing Octave 3.2.2 on my desktop (Ubuntu 9.04) Message-ID: <1196695894.8292731253213688010.JavaMail.root@mail02.pantherlink.uwm.edu> Hello all, my problem is that compilation goes on for quite a while, but then ends with the following error g++ -I. -I.. -I../liboctave -I../src -I../libcruft/misc (.....) ../libcruft/libcruft.so: undefined reference to `r_imag' (.... many more such messages ...) If I try make check ../run-octave --norc --silent --no-history ./fntests.m . exec: 73: /home/peter/octave-3.2.2/src/octave: not found and indeed, this directory does not exist. I downloaded the file octave-3.2.2.tar.gz just today from http://www.gnu.org/software/octave/download.html Please let me know what to do or how to diagnose this better. Thank you and best regards, Peter From hinow at uwm.edu Thu Sep 17 15:18:26 2009 From: hinow at uwm.edu (Peter Hinow) Date: Thu, 17 Sep 2009 15:18:26 -0500 (CDT) Subject: problem installing Octave 3.2.2 on my desktop (Ubuntu 9.04) In-Reply-To: <1196695894.8292731253213688010.JavaMail.root@mail02.pantherlink.uwm.edu> Message-ID: <1130906445.8347091253218706252.JavaMail.root@mail02.pantherlink.uwm.edu> This problam may have solved itself. It was discussed in a thread "Compiling 3.2.2 on Ubuntu 9.04" (August 2009) The recommendation is to run the following two commands sudo apt-get build-dep octave3.0 sudo apt-get install libftgl-dev ----- Original Message ----- From: "Peter Hinow" To: help-octave at octave.org Sent: Thursday, September 17, 2009 1:54:48 PM GMT -06:00 US/Canada Central Subject: problem installing Octave 3.2.2 on my desktop (Ubuntu 9.04) Hello all, my problem is that compilation goes on for quite a while, but then ends with the following error g++ -I. -I.. -I../liboctave -I../src -I../libcruft/misc (.....) ../libcruft/libcruft.so: undefined reference to `r_imag' (.... many more such messages ...) If I try make check ../run-octave --norc --silent --no-history ./fntests.m . exec: 73: /home/peter/octave-3.2.2/src/octave: not found and indeed, this directory does not exist. I downloaded the file octave-3.2.2.tar.gz just today from http://www.gnu.org/software/octave/download.html Please let me know what to do or how to diagnose this better. Thank you and best regards, Peter _______________________________________________ Help-octave mailing list Help-octave at octave.org https://www-old.cae.wisc.edu/mailman/listinfo/help-octave From hinow at uwm.edu Thu Sep 17 15:42:47 2009 From: hinow at uwm.edu (Peter Hinow) Date: Thu, 17 Sep 2009 15:42:47 -0500 (CDT) Subject: problem installing Octave 3.2.2 on my desktop (Ubuntu 9.04) In-Reply-To: <489213280.8362791253220118603.JavaMail.root@mail02.pantherlink.uwm.edu> Message-ID: <882411839.8363241253220167154.JavaMail.root@mail02.pantherlink.uwm.edu> No, unfortunately not. The problem persists. ----- Original Message ----- From: "Peter Hinow" To: help-octave at octave.org Sent: Thursday, September 17, 2009 3:18:26 PM GMT -06:00 US/Canada Central Subject: Re: problem installing Octave 3.2.2 on my desktop (Ubuntu 9.04) This problem may have solved itself. It was discussed in a thread "Compiling 3.2.2 on Ubuntu 9.04" (August 2009) The recommendation is to run the following two commands sudo apt-get build-dep octave3.0 sudo apt-get install libftgl-dev From storrsjm at email.uc.edu Thu Sep 17 16:32:37 2009 From: storrsjm at email.uc.edu (Judd Storrs) Date: Thu, 17 Sep 2009 17:32:37 -0400 Subject: problem installing Octave 3.2.2 on my desktop (Ubuntu 9.04) In-Reply-To: <882411839.8363241253220167154.JavaMail.root@mail02.pantherlink.uwm.edu> References: <489213280.8362791253220118603.JavaMail.root@mail02.pantherlink.uwm.edu> <882411839.8363241253220167154.JavaMail.root@mail02.pantherlink.uwm.edu> Message-ID: Can you post more of the error? --judd On Thu, Sep 17, 2009 at 4:42 PM, Peter Hinow wrote: > No, unfortunately not. The problem persists. > > > ----- Original Message ----- > From: "Peter Hinow" > To: help-octave at octave.org > Sent: Thursday, September 17, 2009 3:18:26 PM GMT -06:00 US/Canada Central > Subject: Re: problem installing Octave 3.2.2 on my desktop (Ubuntu 9.04) > > This problem may have solved itself. It was discussed in a thread > "Compiling 3.2.2 on Ubuntu 9.04" (August 2009) > The recommendation is to run the following two commands > > sudo apt-get build-dep octave3.0 > sudo apt-get install libftgl-dev > > > _______________________________________________ > Help-octave mailing list > Help-octave at octave.org > https://www-old.cae.wisc.edu/mailman/listinfo/help-octave > -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090917/fcae63e0/attachment.html From jos at ccrma.stanford.edu Thu Sep 17 16:47:03 2009 From: jos at ccrma.stanford.edu (Julius Smith) Date: Thu, 17 Sep 2009 15:47:03 -0600 Subject: freqz question (clarified) In-Reply-To: <8A83011125D82746BD74D09F439F4E2016AEE15F@oc-exchange-3.kmo b.com> References: <8A83011125D82746BD74D09F439F4E2016AEE15F@oc-exchange-3.kmob.com> Message-ID: <200909172147.n8HLlHwm028391@mx3.cae.wisc.edu> I agree that freqz should simply plot the magnitude and phase response of the filter. Since the arguments to freqz are merely filter coefficients B and A, there is no guarantee that the concepts of "pass band" or "stop band" make any sense for the given filter. For example, what if B/A is an allpass filter? We ARE guaranteed, on the other hand, that every filter B/A (with A(1)==1) has a frequency response, and the most commonly desired frequency-response display, in my experience, is magnitude and phase versus frequency. I would be happy implement this change (magnitude in dB, phase in degrees), but freqz appears to be in the base Octave distribution, while I can only change things in octave-forge, as far as I know. - jos At 02:03 PM 9/12/2009, Scott.Raevsky wrote: >Content-class: urn:content-classes:message >Content-Type: multipart/alternative; > boundary="----_=_NextPart_001_01CA33E4.15CEB18C" > >Hello, > >Just to clarify my previous question, Matlab's output of freqz is as follows: > >freqz(b,a,...) plots the magnitude and unwrapped phase of the >frequency response of the filter. The plot is displayed in the >current figure window. > >Why does Octave's freqz not plot magnitude and phase? Instead it >plots 1) pass band, 2) stop band, and 3) phase. Plotting a separate >pass band and stop band doesn't make sense to me. > >Thanks > > >MAIL.KMOB.COM made the following >annotations---------------------------------------------------------------------PRIVILEGED >AND CONFIDENTIAL COMMUNICATION > >This electronic transmission, and any documents attached >hereto, may contain confidential and/or legally privileged >information. The information is intended only for use by >the recipient named above. If you have received this >electronic message in error, please notify the sender and >delete the electronic message. Any disclosure, copying, >distribution, or use of the contents of information >received in error is strictly prohibited. >--------------------------------------------------------------------- >_______________________________________________ >Help-octave mailing list >Help-octave at octave.org >https://www-old.cae.wisc.edu/mailman/listinfo/help-octave Julius O. Smith III Prof. of Music and Assoc. Prof. (by courtesy) of Electrical Engineering CCRMA, Stanford University http://ccrma.stanford.edu/~jos/ From sievers at cita.utoronto.ca Fri Sep 18 10:41:11 2009 From: sievers at cita.utoronto.ca (Jonathan Sievers) Date: Fri, 18 Sep 2009 11:41:11 -0400 (EDT) Subject: disabling opengl in octave 3.2.2 Message-ID: Hey folks - I'm trying to compile octave 3.2.2 from source using icc to run on a cluster. OpenGL is causing problems - there are headers/libraries there which show up during configure but break during compilation. Which is not a problem, I don't need graphics, but I can't compile. I've look through configure several times and can't find a flag to disable opengl - does such a thing exist, or is there some other simple way to turn it off? Everything works fine under 3.0.5. BTW, I thought you might enjoy knowing that I now routinely run an MPIed octave across three to four thousand cores. Thanks for the great work! Jonathan Sievers From udippel at uniten.edu.my Fri Sep 18 19:33:13 2009 From: udippel at uniten.edu.my (Uwe Dippel) Date: Sat, 19 Sep 2009 08:33:13 +0800 Subject: Octave 3.2.2 for Ubuntu9.04? Message-ID: <4AB426C9.4030601@uniten.edu.my> It seems that 3.2.2 is the current 'standard', and that compilation is not that easy. Is there any package available? Could someone who has it compiling properly simply make it into a .deb, please, and make it available? Uwe From jordigh at gmail.com Sat Sep 19 00:08:17 2009 From: jordigh at gmail.com (=?UTF-8?Q?Jordi_Guti=C3=A9rrez_Hermos?=) Date: Sat, 19 Sep 2009 00:08:17 -0500 Subject: Octave 3.2.2 for Ubuntu9.04? In-Reply-To: <4AB426C9.4030601@uniten.edu.my> References: <4AB426C9.4030601@uniten.edu.my> Message-ID: <9543b3a40909182208t777f251bn30050dc2a44d92a7@mail.gmail.com> 2009/9/18 Uwe Dippel : > It seems that 3.2.2 is the current 'standard', and that compilation is > not that easy. > Is there any package available? Could someone who has it compiling > properly simply make it into a .deb, please, and make it available? Rapha?l has been hard at work as usual on making Debian packages: http://packages.debian.org/sid/octave3.2 Unfortunately, I think these packages got made after the latest Ubuntu grabbed Debian's unstable snapshot. You could try mixing Debian and Ubuntu packages, although at least from the Debian side, this isn't recommended. You might run into instability this way. This might be excessive paranoia. From jpswensen at comcast.net Sat Sep 19 07:28:55 2009 From: jpswensen at comcast.net (John Swensen) Date: Sat, 19 Sep 2009 08:28:55 -0400 Subject: Octave 3.2.2 for Ubuntu9.04? In-Reply-To: <9543b3a40909182208t777f251bn30050dc2a44d92a7@mail.gmail.com> References: <4AB426C9.4030601@uniten.edu.my> <9543b3a40909182208t777f251bn30050dc2a44d92a7@mail.gmail.com> Message-ID: <03CAB1BE-0146-4EA5-AE89-AE46AEC0F187@comcast.net> Or upgrade to Ubuntu 9.10 (Karmik Koala). I have been doing my testing on 9.10 in a virtual machine and it works great. John Swensen On Sep 19, 2009, at 1:08 AM, Jordi Guti?rrez Hermos wrote: > 2009/9/18 Uwe Dippel : >> It seems that 3.2.2 is the current 'standard', and that compilation >> is >> not that easy. >> Is there any package available? Could someone who has it compiling >> properly simply make it into a .deb, please, and make it available? > > Rapha?l has been hard at work as usual on making Debian packages: > > http://packages.debian.org/sid/octave3.2 > > Unfortunately, I think these packages got made after the latest Ubuntu > grabbed Debian's unstable snapshot. > > You could try mixing Debian and Ubuntu packages, although at least > from the Debian side, this isn't recommended. You might run into > instability this way. This might be excessive paranoia. > > _______________________________________________ > Help-octave mailing list > Help-octave at octave.org > https://www-old.cae.wisc.edu/mailman/listinfo/help-octave From laura-damon at worldnet.att.net Sat Sep 19 07:00:41 2009 From: laura-damon at worldnet.att.net (damon christenbury) Date: Sat, 19 Sep 2009 08:00:41 -0400 Subject: New Octave User Message-ID: I appear to have installed it correctly, but the graphics will not display. I can issue figure and plot commands, and do not receive an error, but I do not see any figures. I can even issue get(gcf) command and get a complete list of the properties, but I cannot see it. Note also that icons in the applications folder have the 'NO' icon on top of the application icon, the one with the circle with the cross from 11am to 5 pm. any ideas? From udippel at uniten.edu.my Sat Sep 19 09:34:05 2009 From: udippel at uniten.edu.my (Uwe Dippel) Date: Sat, 19 Sep 2009 22:34:05 +0800 Subject: Octave 3.2.2 for Ubuntu9.04? In-Reply-To: <9543b3a40909182208t777f251bn30050dc2a44d92a7@mail.gmail.com> References: <4AB426C9.4030601@uniten.edu.my> <9543b3a40909182208t777f251bn30050dc2a44d92a7@mail.gmail.com> Message-ID: <4AB4EBDD.8010206@uniten.edu.my> Jordi Guti?rrez Hermos wrote: > Rapha?l has been hard at work as usual on making Debian packages: > > http://packages.debian.org/sid/octave3.2 > > Unfortunately, I think these packages got made after the latest Ubuntu > grabbed Debian's unstable snapshot. > Obvious: octave3.2 depends on libamd2.2.0 (>= 1:3.4.0); however: Package libamd2.2.0 is not installed. octave3.2 depends on libarpack2 (>= 2.1+parpack96.dfsg); however: Package libarpack2 is not installed. octave3.2 depends on libcamd2.2.0 (>= 1:3.4.0); however: Package libcamd2.2.0 is not installed. octave3.2 depends on libccolamd2.7.1 (>= 1:3.4.0); however: Package libccolamd2.7.1 is not installed. octave3.2 depends on libcholmod1.7.1 (>= 1:3.4.0); however: Package libcholmod1.7.1 is not installed. octave3.2 depends on libcolamd2.7.1 (>= 1:3.4.0); however: Package libcolamd2.7.1 is not installed. octave3.2 depends on libcxsparse2.2.3 (>= 1:3.4.0); however: Package libcxsparse2.2.3 is not installed. octave3.2 depends on libfltk1.1 (>= 1.1.6); however: Package libfltk1.1 is not installed. octave3.2 depends on libftgl2 (>= 2.1.3~rc5); however: Package libftgl2 is not installed. octave3.2 depends on libglpk0 (>= 4.30); however: Version of libglpk0 on system is 4.29-2. octave3.2 depends on libgraphicsmagick++3; however: Package libgraphicsmagick++3 is not installed. octave3.2 depends on libgraphicsmagick3 (>= 1.3.5); however: Package libgraphicsmagick3 is not installed. octave3.2 depends on libhdf5-serial-1.8.3 | libhdf5-1.8.3; however: Package libhdf5-serial-1.8.3 is not installed. Package libhdf5-1.8.3 is not installed. octave3.2 depends on libqrupdate1 (>= 1.0); however: Package libqrupdate1 is not installed. octave3.2 depends on libumfpack5.4.0 (>= 1:3.4.0); however: Package libumfpack5.4.0 is not installed. octave3.2 depends on octave3.2-common (= 3.2.2-2); however: Package octave3.2-common is not installed. dpkg: error processing octave3.2 (--install): dependency problems - leaving unconfigured but: $ dpkg -l | grep octave ii octave2.9 1:3.0.1-6ubuntu2 GNU Octave language for numerical computations (dummy p ii octave3.0 1:3.0.1-6ubuntu2 GNU Octave language for numerical computations (3.0 bra ii octave3.0-htmldoc 1:3.0.1-6ubuntu2 HTML documentation on the GNU Octave language (3.0 bran So there are huge changes, after all, I guess. Thanks anyway, Uwe From udippel at uniten.edu.my Sat Sep 19 09:36:39 2009 From: udippel at uniten.edu.my (Uwe Dippel) Date: Sat, 19 Sep 2009 22:36:39 +0800 Subject: Octave 3.2.2 for Ubuntu9.04? In-Reply-To: <03CAB1BE-0146-4EA5-AE89-AE46AEC0F187@comcast.net> References: <4AB426C9.4030601@uniten.edu.my> <9543b3a40909182208t777f251bn30050dc2a44d92a7@mail.gmail.com> <03CAB1BE-0146-4EA5-AE89-AE46AEC0F187@comcast.net> Message-ID: <4AB4EC77.7030602@uniten.edu.my> John Swensen wrote: > Or upgrade to Ubuntu 9.10 (Karmik Koala). I have been doing my > testing on 9.10 in a virtual machine and it works great. > Yes. But KK is a good month in the future, and I need it (octave) earlier. So, where do you get KK, and how do you get octave into it?? Uwe From jpswensen at comcast.net Sat Sep 19 09:41:48 2009 From: jpswensen at comcast.net (John Swensen) Date: Sat, 19 Sep 2009 10:41:48 -0400 Subject: Octave 3.2.2 for Ubuntu9.04? In-Reply-To: <4AB4EC77.7030602@uniten.edu.my> References: <4AB426C9.4030601@uniten.edu.my> <9543b3a40909182208t777f251bn30050dc2a44d92a7@mail.gmail.com> <03CAB1BE-0146-4EA5-AE89-AE46AEC0F187@comcast.net> <4AB4EC77.7030602@uniten.edu.my> Message-ID: <73C230EE-DD3D-4FDC-9CED-BFA8396250E0@comcast.net> On Sep 19, 2009, at 10:36 AM, Uwe Dippel wrote: > John Swensen wrote: >> Or upgrade to Ubuntu 9.10 (Karmik Koala). I have been doing my >> testing on 9.10 in a virtual machine and it works great. >> > > Yes. But KK is a good month in the future, and I need it (octave) > earlier. > So, where do you get KK, and how do you get octave into it?? > > Uwe > You can upgrade from 9.04 to 9.10 by either downloading the ISO and reinstalling completely, or upgrading using the update manager by doing the following (found on an Ubuntu mailing list http://ubuntuforums.org/showthread.php?t=1185036 and I have used 2 time with no problems): 1) Open a terminal 2) Run update-manager -d 3) Click the button that offers an upgrade. Hope this helps you get a recent version of Octave up and running more quickly. John Swensen From joseph.slater at wright.edu Sat Sep 19 10:22:52 2009 From: joseph.slater at wright.edu (Joseph C. Slater PE, PhD) Date: Sat, 19 Sep 2009 11:22:52 -0400 Subject: Print font size MacOS X (octave 3.2.2) Message-ID: <22B9626E-FA1C-4CB9-841D-68C43FFA656F@wright.edu> The print option -F:fontsize where I presume fontsize is a number isn't working on my machine. It seems to be adjusting the location of the numbers to account for the expected size, but the font size itself is not changing. Is this just my machine, this version, platform? Thanks, Joe From bpabbott at mac.com Sat Sep 19 10:35:28 2009 From: bpabbott at mac.com (Ben Abbott) Date: Sat, 19 Sep 2009 11:35:28 -0400 Subject: New Octave User In-Reply-To: References: Message-ID: On Sep 19, 2009, at 8:00 AM, damon christenbury wrote: > I appear to have installed it correctly, but the graphics will not > display. I can issue figure and plot commands, and do not receive an > error, but I do not see any figures. I can even issue get(gcf) > command and get a complete list of the properties, but I cannot see > it. > Note also that icons in the applications folder have the 'NO' icon on > top of the application icon, the one with the circle with the cross > from 11am to 5 pm. > > any ideas? Please tell use what version of octave you have installed and what operating system you running. Ben From bpabbott at mac.com Sat Sep 19 10:36:50 2009 From: bpabbott at mac.com (Ben Abbott) Date: Sat, 19 Sep 2009 11:36:50 -0400 Subject: Print font size MacOS X (octave 3.2.2) In-Reply-To: <22B9626E-FA1C-4CB9-841D-68C43FFA656F@wright.edu> References: <22B9626E-FA1C-4CB9-841D-68C43FFA656F@wright.edu> Message-ID: On Sep 19, 2009, at 11:22 AM, Joseph C. Slater PE, PhD wrote: > The print option > -F:fontsize > > where I presume fontsize is a number isn't working on my machine. It > seems to be adjusting the location of the numbers to account for the > expected size, but the font size itself is not changing. > > Is this just my machine, this version, platform? > Thanks, > Joe Joe, Please provide a simple example so that we may duplicate it. Ben From hdfrango at gmail.com Sat Sep 19 10:24:53 2009 From: hdfrango at gmail.com (hdfrango) Date: Sat, 19 Sep 2009 08:24:53 -0700 (PDT) Subject: Some Octave newbie questions regarding number format and matrices Message-ID: <25522543.post@talk.nabble.com> Hi, I started using Octave very recently and am still unsure about a few things: 1. is there any way to force octave to express numbers in fraction form, to avoid loss of precision? 2. when I want to computer the inverse of a matrix, I have to do inv(A'), computing the inverse of the transpose, in order to get the correct answer. Why is that? thank you -- View this message in context: http://www.nabble.com/Some-Octave-newbie-questions-regarding-number-format-and-matrices-tp25522543p25522543.html Sent from the Octave - General mailing list archive at Nabble.com. From storrsjm at email.uc.edu Sat Sep 19 12:47:12 2009 From: storrsjm at email.uc.edu (Judd Storrs) Date: Sat, 19 Sep 2009 13:47:12 -0400 Subject: Octave 3.2.2 for Ubuntu9.04? In-Reply-To: <4AB4EC77.7030602@uniten.edu.my> References: <4AB426C9.4030601@uniten.edu.my> <9543b3a40909182208t777f251bn30050dc2a44d92a7@mail.gmail.com> <03CAB1BE-0146-4EA5-AE89-AE46AEC0F187@comcast.net> <4AB4EC77.7030602@uniten.edu.my> Message-ID: I really don't think it's that hard to compile from sources on Ubuntu. I've just started a fresh install of 9.04 into a VM and I will write a howto and post it to the list later today. --judd On Sat, Sep 19, 2009 at 10:36 AM, Uwe Dippel wrote: > John Swensen wrote: > > Or upgrade to Ubuntu 9.10 (Karmik Koala). I have been doing my > > testing on 9.10 in a virtual machine and it works great. > > > > Yes. But KK is a good month in the future, and I need it (octave) earlier. > So, where do you get KK, and how do you get octave into it?? > > Uwe > > _______________________________________________ > Help-octave mailing list > Help-octave at octave.org > https://www-old.cae.wisc.edu/mailman/listinfo/help-octave > -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090919/f88b4ad3/attachment.html From dastew at sympatico.ca Sat Sep 19 13:43:04 2009 From: dastew at sympatico.ca (dastew at sympatico.ca) Date: Sat, 19 Sep 2009 18:43:04 +0000 Subject: Some Octave newbie questions regarding number format and matrices In-Reply-To: <25522543.post@talk.nabble.com> References: <25522543.post@talk.nabble.com> Message-ID: > Date: Sat, 19 Sep 2009 08:24:53 -0700 > From: hdfrango at gmail.com > To: help-octave at octave.org > Subject: Some Octave newbie questions regarding number format and matrices > > > Hi, > > I started using Octave very recently and am still unsure about a few things: > > 1. is there any way to force octave to express numbers in fraction form, to > avoid loss of precision? I am not sure but I don't think there is. > > 2. when I want to computer the inverse of a matrix, I have to do inv(A'), > computing the inverse of the transpose, in order to get the correct answer. > Why is that? > When I do what you say I don't have to do the transpose.: so : What version Of octave do you have and what operating system are you running it on? example: octave-3.0.1:1> a= [1 2; 7 3] a = 1 2 7 3 octave-3.0.1:3> b=inv(a) b = -0.272727 0.181818 0.636364 -0.090909 octave-3.0.1:4> a*b ans = 1.00000 0.00000 0.00000 1.00000 octave-3.0.1:5> Doug Stewart > thank you > -- > View this message in context: http://www.nabble.com/Some-Octave-newbie-questions-regarding-number-format-and-matrices-tp25522543p25522543.html > Sent from the Octave - General mailing list archive at Nabble.com. > > _______________________________________________ > Help-octave mailing list > Help-octave at octave.org > https://www-old.cae.wisc.edu/mailman/listinfo/help-octave -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090919/e64bd6f3/attachment.html From dieter.jurzitza at t-online.de Sat Sep 19 13:45:44 2009 From: dieter.jurzitza at t-online.de (Dr. Ing. Dieter Jurzitza) Date: Sat, 19 Sep 2009 20:45:44 +0200 Subject: New Octave User In-Reply-To: References: Message-ID: <200909192045.45044.dieter.jurzitza@t-online.de> Hi, what system are you running? linux, MS-Windows? Anyway, for graphics output you need to have gnuplot installed in either case. For windows, see www.gnuplot.info for downloading options, for linux you should be able to install it from the repositories of your distribution. Hope this helps, take care Dieter Jurzitza Am Samstag 19 September 2009 14:00:41 schrieb damon christenbury: > I appear to have installed it correctly, but the graphics will not ****** -- ----------------------------------------------------------- | \ /\_/\ | | ~x~ |/-----\ / \ /- \_/ ^^__ _ / _ ____ / The following describes how I successfully built octave-3.2.2 on a fresh install of Ubuntu 9.04. After I finished install from the CD, I used Synaptic to update all Ubuntu packages. I did not change any software sources from the defaults. Here's how I proceeded: 1) Install library dependencies ------------------------------- First try: $ sudo apt-get install libcurl4-dev libgraphicsmagick++1-dev libfltk-dev libarpack2-dev If it succeeds proceed to step 2. Otherwise if it complains that there is more than one package that satisfies libcurl4-dev use $ sudo apt-get install libcurl4-gnutls-dev and then repeat the first command again. libcurl4-dev is required for step 2, but it is a virtual package satisfied by two other packages--either libcurl4-gnutls-dev or libcurl4-openssl-dev. I used libcurl4-gnutls-dev but I assume you could use the openssl one. If the first command succeeds then you already have one of these. 2) Install packages needed to build octave ------------------------------------------ $ sudo apt-get build-dep octave3.0 3) Download libqrupdate packages from Karmic. (OPTIONAL) -------------------------------------------------------- Get and install packages for your platform from: http://packages.ubuntu.com/karmic/libqrupdate-dev http://packages.ubuntu.com/karmic/libqrupdate1 Install them using gdebi or $ dpkg -i libqrupdate1_1.0.1-1_i386.deb libqrupdate-dev_1.0.1-1_i386.deb 4) Download, extract, and build octave-3.2.2 ---------------------------------------------- $ wget ftp://ftp.octave.org/pub/octave/octave-3.2.2.tar.bz2 $ tar xf octave-3.2.2.tar.bz2 $ cd octave-3.2.2 $ ./configure --prefix=/usr/local $ make $ make check $ sudo make install Hope this helps. --judd -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090919/43e48ec1/attachment.html From tmacchant at yahoo.co.jp Sat Sep 19 17:06:33 2009 From: tmacchant at yahoo.co.jp (Tatsuro MATSUOKA) Date: Sun, 20 Sep 2009 07:06:33 +0900 (JST) Subject: New Octave User In-Reply-To: Message-ID: <20090919220633.68197.qmail@web3813.mail.bbt.yahoo.co.jp> Hello Please specify what version of octave you have installed and your OS (Linux(disribution name ), MacOSX, winodows (xp, vista, windows 7). Please specify show the script you have execute. Please specify which graphic graphic backend you used. gnuplot or fltk? Perhaps you are not familiar with ask the question at the ML. Please give the detailed information to explain your trouble. Regards Tatsuro --- damon christenbury wrote: > I appear to have installed it correctly, but the graphics will not > display. I can issue figure and plot commands, and do not receive an > error, but I do not see any figures. I can even issue get(gcf) > command and get a complete list of the properties, but I cannot see it. > Note also that icons in the applications folder have the 'NO' icon on > top of the application icon, the one with the circle with the cross > from 11am to 5 pm. > > any ideas? > _______________________________________________ > Help-octave mailing list > Help-octave at octave.org > https://www-old.cae.wisc.edu/mailman/listinfo/help-octave > -------------------------------------- Thanks 10 years! Yahoo! Shopping and Yahoo! Auctions http://pr.mail.yahoo.co.jp/ec10years/ From dastew at sympatico.ca Sat Sep 19 18:31:42 2009 From: dastew at sympatico.ca (dastew at sympatico.ca) Date: Sat, 19 Sep 2009 23:31:42 +0000 Subject: Octave 3.2.2 for Ubuntu9.04 -- How to compile from sources In-Reply-To: References: Message-ID: Date: Sat, 19 Sep 2009 16:27:03 -0400 Subject: Re: Octave 3.2.2 for Ubuntu9.04 -- How to compile from sources From: storrsjm at email.uc.edu To: udippel at uniten.edu.my CC: Help-octave at octave.org The following describes how I successfully built octave-3.2.2 on a fresh install of Ubuntu 9.04. After I finished install from the CD, I used Synaptic to update all Ubuntu packages. I did not change any software sources from the defaults. Here's how I proceeded: 1) Install library dependencies ------------------------------- First try: $ sudo apt-get install libcurl4-dev libgraphicsmagick++1-dev libfltk-dev libarpack2-dev If it succeeds proceed to step 2. Otherwise if it complains that there is more than one package that satisfies libcurl4-dev use $ sudo apt-get install libcurl4-gnutls-dev and then repeat the first command again. libcurl4-dev is required for step 2, but it is a virtual package satisfied by two other packages--either libcurl4-gnutls-dev or libcurl4-openssl-dev. I used libcurl4-gnutls-dev but I assume you could use the openssl one. If the first command succeeds then you already have one of these. 2) Install packages needed to build octave ------------------------------------------ $ sudo apt-get build-dep octave3.0 3) Download libqrupdate packages from Karmic. (OPTIONAL) -------------------------------------------------------- Get and install packages for your platform from: http://packages.ubuntu.com/karmic/libqrupdate-dev http://packages.ubuntu.com/karmic/libqrupdate1 Install them using gdebi or $ dpkg -i libqrupdate1_1.0.1-1_i386.deb libqrupdate-dev_1.0.1-1_i386.deb 4) Download, extract, and build octave-3.2.2 ---------------------------------------------- $ wget ftp://ftp.octave.org/pub/octave/octave-3.2.2.tar.bz2 $ tar xf octave-3.2.2.tar.bz2 $ cd octave-3.2.2 $ ./configure --prefix=/usr/local $ make $ make check $ sudo make install Hope this helps. --judd I tried this and it worked!! Now How do you add all the packages from source forge? Doug -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090919/c772eab0/attachment.html From udippel at uniten.edu.my Sat Sep 19 21:17:19 2009 From: udippel at uniten.edu.my (Uwe Dippel) Date: Sun, 20 Sep 2009 10:17:19 +0800 Subject: Octave 3.2.2 for Ubuntu9.04 -- How to compile from sources In-Reply-To: References: Message-ID: <4AB590AF.6080403@uniten.edu.my> Judd Storrs wrote: > I really don't think it's that hard to compile from sources on Ubuntu. > The following describes how I successfully built octave-3.2.2 on a > fresh install of Ubuntu 9.04. After I finished install from the CD, I > used Synaptic to update all Ubuntu packages. I did not change any > software sources from the defaults. Here's how I proceeded: > > [...] > > Hope this helps. I hope so, too! Actually, I'm a FOSS-person myself; a Linux user for 10 years. No, difficult to do it is not. The thing that's absolutely difficult is the How To! How should, how could, anyone guess which packages are necessary; which commands are necessary?? I at least couldn't. And still, it doesn't go through here: $ sudo apt-get install libcurl4-dev libgraphicsmagick++1-dev libfltk-dev libarpack2-dev Package libcurl4-dev is a virtual package provided by: libcurl4-gnutls-dev 7.18.2-8ubuntu4.1 You should explicitly select one to install. E: Package libcurl4-dev has no installation candidate $ sudo apt-get install libcurl4-gnutls-dev Reading package lists... Done Building dependency tree Reading state information... Done The following extra packages will be installed: comerr-dev libgcrypt11-dev libgnutls-dev libgpg-error-dev libidn11-dev libkadm55 libkrb5-dev libldap2-dev libtasn1-3-dev Suggested packages: libcurl3-dbg libgcrypt11-doc gnutls-doc gnutls-bin guile-gnutls krb5-doc The following NEW packages will be installed: comerr-dev libcurl4-gnutls-dev libgcrypt11-dev libgnutls-dev libgpg-error-dev libidn11-dev libkadm55 libkrb5-dev libldap2-dev libtasn1-3-dev 0 upgraded, 10 newly installed, 0 to remove and 0 not upgraded. Need to get 3928kB of archives. After this operation, 12.2MB of additional disk space will be used. Do you want to continue [Y/n]? y $ sudo apt-get install libcurl4-dev libgraphicsmagick++1-dev libfltk-dev libarpack2-dev Reading package lists... Done Building dependency tree Reading state information... Done Package libcurl4-dev is a virtual package provided by: libcurl4-gnutls-dev 7.18.2-8ubuntu4.1 You should explicitly select one to install. E: Package libcurl4-dev has no installation candidate $ And that's the end already. No libcurl4-dev. So I tried the other way: $ sudo apt-get install libcurl4-openssl-dev Reading package lists... Done Building dependency tree Reading state information... Done The following packages were automatically installed and are no longer required: libgpg-error-dev libtasn1-3-dev libgcrypt11-dev libgnutls-dev Use 'apt-get autoremove' to remove them. The following extra packages will be installed: libssl-dev Suggested packages: libcurl3-dbg The following packages will be REMOVED: libcurl4-gnutls-dev The following NEW packages will be installed: libcurl4-openssl-dev libssl-dev 0 upgraded, 2 newly installed, 1 to remove and 0 not upgraded. Need to get 3035kB of archives. After this operation, 7029kB of additional disk space will be used. Do you want to continue [Y/n]? y $ sudo apt-get build-dep octave3.0 Reading package lists... Done Building dependency tree Reading state information... Done Package libcurl4-dev is a virtual package provided by: libcurl4-gnutls-dev 7.18.2-8ubuntu4.1 You should explicitly select one to install. E: Package libcurl4-dev has no installation candidate E: Failed to satisfy Build-Depends dependency for octave3.0: libcurl4-dev Out of luck again, and the end of the line for me. Thanks anyway, Uwe From storrsjm at email.uc.edu Sat Sep 19 21:51:12 2009 From: storrsjm at email.uc.edu (Judd Storrs) Date: Sat, 19 Sep 2009 22:51:12 -0400 Subject: Octave 3.2.2 for Ubuntu9.04 -- How to compile from sources In-Reply-To: References: Message-ID: I've been pretty piecemeal in my use of octave-forge and I don't remember running into any problems by just following the instructions in the orange box on http://octave.sourceforge.net Basically, I've always just downloaded the desired package.tar.gz from sourceforge and then I run octave inside the download directory and type: pkg install package.tar.gz And everything has magically worked for me. I think that if you've already built octave you should have everything that is needed (unless the package has additional requirements--none of the ones I use do). I don't know if there's a way to build and install them all or to automatically download dependencies but I think I remember seeing something about the mentioned in the octave-forge website. --judd On Sat, Sep 19, 2009 at 7:31 PM, wrote: > > > ------------------------------ > Date: Sat, 19 Sep 2009 16:27:03 -0400 > Subject: Re: Octave 3.2.2 for Ubuntu9.04 -- How to compile from sources > From: storrsjm at email.uc.edu > To: udippel at uniten.edu.my > CC: Help-octave at octave.org > > > The following describes how I successfully built octave-3.2.2 on a fresh > install of Ubuntu 9.04. After I finished install from the CD, I used > Synaptic to update all Ubuntu packages. I did not change any software > sources from the defaults. Here's how I proceeded: > > 1) Install library dependencies > ------------------------------- > > First try: > > $ sudo apt-get install libcurl4-dev libgraphicsmagick++1-dev libfltk-dev > libarpack2-dev > > If it succeeds proceed to step 2. Otherwise if it complains that there is > more than one package that satisfies libcurl4-dev use > > $ sudo apt-get install libcurl4-gnutls-dev > > and then repeat the first command again. > > libcurl4-dev is required for step 2, but it is a virtual package satisfied > by two other packages--either libcurl4-gnutls-dev or libcurl4-openssl-dev. I > used libcurl4-gnutls-dev but I assume you could use the openssl one. If the > first command succeeds then you already have one of these. > > > 2) Install packages needed to build octave > ------------------------------------------ > > $ sudo apt-get build-dep octave3.0 > > > 3) Download libqrupdate packages from Karmic. (OPTIONAL) > -------------------------------------------------------- > > Get and install packages for your platform from: > > http://packages.ubuntu.com/karmic/libqrupdate-dev > http://packages.ubuntu.com/karmic/libqrupdate1 > > Install them using gdebi or > > $ dpkg -i libqrupdate1_1.0.1-1_i386.deb libqrupdate-dev_1.0.1-1_i386.deb > > > 4) Download, extract, and build octave-3.2.2 > ---------------------------------------------- > > $ wget ftp://ftp.octave.org/pub/octave/octave-3.2.2.tar.bz2 > $ tar xf octave-3.2.2.tar.bz2 > $ cd octave-3.2.2 > $ ./configure --prefix=/usr/local > $ make > $ make check > $ sudo make install > > > Hope this helps. > > --judd > > I tried this and it worked!! > > Now How do you add all the packages from source forge? > > Doug > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090919/a40f5e3e/attachment.html From storrsjm at email.uc.edu Sat Sep 19 21:55:17 2009 From: storrsjm at email.uc.edu (Judd Storrs) Date: Sat, 19 Sep 2009 22:55:17 -0400 Subject: Octave 3.2.2 for Ubuntu9.04 -- How to compile from sources In-Reply-To: <4AB590AF.6080403@uniten.edu.my> References: <4AB590AF.6080403@uniten.edu.my> Message-ID: That's pretty weird. Are your packages up-to-date? sudo apt-get update sudo apt-get upgrade --judd On Sat, Sep 19, 2009 at 10:17 PM, Uwe Dippel wrote: > Judd Storrs wrote: > >> I really don't think it's that hard to compile from sources on Ubuntu. >> > > The following describes how I successfully built octave-3.2.2 on a >> fresh install of Ubuntu 9.04. After I finished install from the CD, I >> used Synaptic to update all Ubuntu packages. I did not change any >> software sources from the defaults. Here's how I proceeded: >> >> [...] >> >> Hope this helps. >> > > I hope so, too! > > Actually, I'm a FOSS-person myself; a Linux user for 10 years. No, > difficult to do it is not. The thing that's absolutely difficult is the > How To! How should, how could, anyone guess which packages are > necessary; which commands are necessary?? I at least couldn't. > > And still, it doesn't go through here: > > $ sudo apt-get install libcurl4-dev libgraphicsmagick++1-dev libfltk-dev > libarpack2-dev > Package libcurl4-dev is a virtual package provided by: > libcurl4-gnutls-dev 7.18.2-8ubuntu4.1 > You should explicitly select one to install. > E: Package libcurl4-dev has no installation candidate > $ sudo apt-get install libcurl4-gnutls-dev > Reading package lists... Done > Building dependency tree > Reading state information... Done > The following extra packages will be installed: > comerr-dev libgcrypt11-dev libgnutls-dev libgpg-error-dev libidn11-dev > libkadm55 libkrb5-dev libldap2-dev libtasn1-3-dev > Suggested packages: > libcurl3-dbg libgcrypt11-doc gnutls-doc gnutls-bin guile-gnutls krb5-doc > The following NEW packages will be installed: > comerr-dev libcurl4-gnutls-dev libgcrypt11-dev libgnutls-dev > libgpg-error-dev libidn11-dev libkadm55 libkrb5-dev libldap2-dev > libtasn1-3-dev > 0 upgraded, 10 newly installed, 0 to remove and 0 not upgraded. > Need to get 3928kB of archives. > After this operation, 12.2MB of additional disk space will be used. > Do you want to continue [Y/n]? y > $ sudo apt-get install libcurl4-dev libgraphicsmagick++1-dev libfltk-dev > libarpack2-dev > Reading package lists... Done > Building dependency tree > Reading state information... Done > Package libcurl4-dev is a virtual package provided by: > libcurl4-gnutls-dev 7.18.2-8ubuntu4.1 > You should explicitly select one to install. > E: Package libcurl4-dev has no installation candidate > $ > > And that's the end already. No libcurl4-dev. > > So I tried the other way: > $ sudo apt-get install libcurl4-openssl-dev > Reading package lists... Done > Building dependency tree > Reading state information... Done > The following packages were automatically installed and are no longer > required: > libgpg-error-dev libtasn1-3-dev libgcrypt11-dev libgnutls-dev > Use 'apt-get autoremove' to remove them. > The following extra packages will be installed: > libssl-dev > Suggested packages: > libcurl3-dbg > The following packages will be REMOVED: > libcurl4-gnutls-dev > The following NEW packages will be installed: > libcurl4-openssl-dev libssl-dev > 0 upgraded, 2 newly installed, 1 to remove and 0 not upgraded. > Need to get 3035kB of archives. > After this operation, 7029kB of additional disk space will be used. > Do you want to continue [Y/n]? y > > $ sudo apt-get build-dep octave3.0 > Reading package lists... Done > Building dependency tree > Reading state information... Done > Package libcurl4-dev is a virtual package provided by: > libcurl4-gnutls-dev 7.18.2-8ubuntu4.1 > You should explicitly select one to install. > E: Package libcurl4-dev has no installation candidate > E: Failed to satisfy Build-Depends dependency for octave3.0: libcurl4-dev > > Out of luck again, and the end of the line for me. > > Thanks anyway, > > Uwe > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090919/a6a110a4/attachment.html From udippel at uniten.edu.my Sat Sep 19 22:09:28 2009 From: udippel at uniten.edu.my (Uwe Dippel) Date: Sun, 20 Sep 2009 11:09:28 +0800 Subject: Octave 3.2.2 for Ubuntu9.04 -- How to compile from sources In-Reply-To: References: <4AB590AF.6080403@uniten.edu.my> Message-ID: <4AB59CE8.20101@uniten.edu.my> Judd Storrs wrote: > That's pretty weird. Are your packages up-to-date? > > sudo apt-get update > sudo apt-get upgrade Of course! Daily! And without any errors! Uwe From udippel at uniten.edu.my Sat Sep 19 22:15:22 2009 From: udippel at uniten.edu.my (Uwe Dippel) Date: Sun, 20 Sep 2009 11:15:22 +0800 Subject: Octave 3.2.2 for Ubuntu9.04 -- How to compile from sources In-Reply-To: <4AB59CE8.20101@uniten.edu.my> References: <4AB590AF.6080403@uniten.edu.my> <4AB59CE8.20101@uniten.edu.my> Message-ID: <4AB59E4A.7020204@uniten.edu.my> Uwe Dippel wrote: > Judd Storrs wrote: >> That's pretty weird. Are your packages up-to-date? >> >> sudo apt-get update >> sudo apt-get upgrade > > Of course! Daily! And without any errors! Oh, do we eventually run into an amd64-versus-i386 problem here? $ uname -a Linux mybox 2.6.28-15-generic #49-Ubuntu SMP Tue Aug 18 19:25:34 UTC 2009 x86_64 GNU/Linux Uwe From storrsjm at email.uc.edu Sat Sep 19 22:33:24 2009 From: storrsjm at email.uc.edu (Judd Storrs) Date: Sat, 19 Sep 2009 23:33:24 -0400 Subject: Octave 3.2.2 for Ubuntu9.04 -- How to compile from sources In-Reply-To: <4AB59CE8.20101@uniten.edu.my> References: <4AB590AF.6080403@uniten.edu.my> <4AB59CE8.20101@uniten.edu.my> Message-ID: What's your output for: apt-cache showpkg libcurl4-gnutls-dev and apt-cache showpkg libcurl4-dev --judd -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090919/a9dfca09/attachment.html From jordigh at gmail.com Sat Sep 19 22:44:28 2009 From: jordigh at gmail.com (=?UTF-8?Q?Jordi_Guti=C3=A9rrez_Hermos?=) Date: Sat, 19 Sep 2009 22:44:28 -0500 Subject: Octave 3.2.2 for Ubuntu9.04? In-Reply-To: <4AB4EBDD.8010206@uniten.edu.my> References: <4AB426C9.4030601@uniten.edu.my> <9543b3a40909182208t777f251bn30050dc2a44d92a7@mail.gmail.com> <4AB4EBDD.8010206@uniten.edu.my> Message-ID: <9543b3a40909192044m6c0b7a8etaffc2b8a573ce4eb@mail.gmail.com> 2009/9/19 Uwe Dippel : > Jordi Guti?rrez Hermos wrote: >> >> Rapha?l has been hard at work as usual on making Debian packages: >> >> ? ? http://packages.debian.org/sid/octave3.2 >> >> Unfortunately, I think these packages got made after the latest Ubuntu >> grabbed Debian's unstable snapshot. >> > > Obvious: > octave3.2 depends on libamd2.2.0 (>= 1:3.4.0); however: > ?Package libamd2.2.0 is not installed. If you want to mix Debian and Ubuntu packages, despite warnings of possible instability, use apt. That is, add a source line for Debian repositories in /etc/apt/sources.list and use apt to install them. The instability is much less likely if the Ubuntu packages are in Universe, as those are the Debian packages that Ubuntu modifies the least. I think for the case of Octave, most of the packages are identical in Debian and Ubuntu. From storrsjm at email.uc.edu Sat Sep 19 22:45:38 2009 From: storrsjm at email.uc.edu (Judd Storrs) Date: Sat, 19 Sep 2009 23:45:38 -0400 Subject: Octave 3.2.2 for Ubuntu9.04 -- How to compile from sources In-Reply-To: <4AB59E4A.7020204@uniten.edu.my> References: <4AB590AF.6080403@uniten.edu.my> <4AB59CE8.20101@uniten.edu.my> <4AB59E4A.7020204@uniten.edu.my> Message-ID: On Sat, Sep 19, 2009 at 11:15 PM, Uwe Dippel wrote: > Uwe Dippel wrote: > >> Judd Storrs wrote: >> >>> That's pretty weird. Are your packages up-to-date? >>> >>> sudo apt-get update >>> sudo apt-get upgrade >>> >> >> Of course! Daily! And without any errors! >> > > Oh, do we eventually run into an amd64-versus-i386 problem here? > $ uname -a > Linux mybox 2.6.28-15-generic #49-Ubuntu SMP Tue Aug 18 19:25:34 UTC > 2009 x86_64 GNU/Linux > It's possible, but I doubt it. I use two different x86_64 machines running 9.04 and on both of them have libcurl4-dev provided by libcurl4-gnutls-dev (but they were installed in March). The virtual machine I created today was i386, though. --judd -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090919/1bb0f686/attachment-0001.html From udippel at uniten.edu.my Sat Sep 19 23:13:40 2009 From: udippel at uniten.edu.my (Uwe Dippel) Date: Sun, 20 Sep 2009 12:13:40 +0800 Subject: Octave 3.2.2 for Ubuntu9.04 -- How to compile from sources In-Reply-To: References: <4AB590AF.6080403@uniten.edu.my> <4AB59CE8.20101@uniten.edu.my> Message-ID: <4AB5ABF4.4010201@uniten.edu.my> Judd Storrs wrote: > What's your output for: > > apt-cache showpkg libcurl4-gnutls-dev $ apt-cache showpkg libcurl4-gnutls-dev Package: libcurl4-gnutls-dev Versions: 7.18.2-8ubuntu4.1 (/var/lib/apt/lists/ubuntu-ashisuto.ubuntulinux.jp_ubuntu_dists_jaunty-updates_main_binary-amd64_Packages) (/var/lib/apt/lists/security.ubuntu.com_ubuntu_dists_jaunty-security_main_binary-amd64_Packages) (/var/lib/dpkg/status) Description Language: File: /var/lib/apt/lists/ubuntu-ashisuto.ubuntulinux.jp_ubuntu_dists_jaunty-updates_main_binary-amd64_Packages MD5: 542a849fd833dd4aff3c38a8504ae2b7 7.18.2-8ubuntu4 (/var/lib/apt/lists/ubuntu-ashisuto.ubuntulinux.jp_ubuntu_dists_jaunty_main_binary-amd64_Packages) Description Language: File: /var/lib/apt/lists/ubuntu-ashisuto.ubuntulinux.jp_ubuntu_dists_jaunty_main_binary-amd64_Packages MD5: 542a849fd833dd4aff3c38a8504ae2b7 Reverse Depends: tclcurl,libcurl4-gnutls-dev paintlib-dev,libcurl4-gnutls-dev libwfut-0.2-dev,libcurl4-gnutls-dev libopkele-dev,libcurl4-gnutls-dev libgmyth-dev,libcurl4-gnutls-dev libetpan-dev,libcurl4-gnutls-dev 7.16.4-5 libcurl-ocaml-dev,libcurl4-gnutls-dev 7.15.0-2 audacious-plugins-dev,libcurl4-gnutls-dev python-pycurl,libcurl4-gnutls-dev libtunepimp-dev,libcurl4-gnutls-dev libraptor1-dev,libcurl4-gnutls-dev Dependencies: 7.18.2-8ubuntu4.1 - libcurl3-gnutls (5 7.18.2-8ubuntu4.1) libc6-dev (16 (null)) libc-dev (0 (null)) libgnutls-dev (0 (null)) zlib1g-dev (0 (null)) libidn11-dev (0 (null)) libkrb5-dev (16 (null)) hurd (0 (null)) libldap2-dev (0 (null)) libcurl3-dbg (0 (null)) libcurl-dev (0 (null)) libcurl-dev (0 (null)) libcurl-ssl-dev (0 (null)) libcurl3-gnutls-dev (0 (null)) libcurl4-dev (0 (null)) 7.18.2-8ubuntu4 - libcurl3-gnutls (5 7.18.2-8ubuntu4) libc6-dev (16 (null)) libc-dev (0 (null)) libgnutls-dev (0 (null)) zlib1g-dev (0 (null)) libidn11-dev (0 (null)) libkrb5-dev (16 (null)) hurd (0 (null)) libldap2-dev (0 (null)) libcurl3-dbg (0 (null)) libcurl-dev (0 (null)) libcurl-dev (0 (null)) libcurl-ssl-dev (0 (null)) libcurl3-gnutls-dev (0 (null)) libcurl4-dev (0 (null)) Provides: 7.18.2-8ubuntu4.1 - libcurl4-dev libcurl3-gnutls-dev libcurl-ssl-dev libcurl-dev 7.18.2-8ubuntu4 - libcurl4-dev libcurl3-gnutls-dev libcurl-ssl-dev libcurl-dev Reverse Provides: $ > > and > > apt-cache showpkg libcurl4-dev $ apt-cache showpkg libcurl4-dev Package: libcurl4-dev Versions: Reverse Depends: libcurl4-gnutls-dev,libcurl4-dev libnxml0-dev,libcurl4-dev libgdal1-dev,libcurl4-dev libcurl4-gnutls-dev,libcurl4-dev Dependencies: Provides: Reverse Provides: libcurl4-gnutls-dev 7.18.2-8ubuntu4.1 libcurl4-gnutls-dev 7.18.2-8ubuntu4 $ Uwe From udippel at uniten.edu.my Sat Sep 19 23:26:16 2009 From: udippel at uniten.edu.my (Uwe Dippel) Date: Sun, 20 Sep 2009 12:26:16 +0800 Subject: Octave 3.2.2 for Ubuntu9.04? In-Reply-To: <9543b3a40909192044m6c0b7a8etaffc2b8a573ce4eb@mail.gmail.com> References: <4AB426C9.4030601@uniten.edu.my> <9543b3a40909182208t777f251bn30050dc2a44d92a7@mail.gmail.com> <4AB4EBDD.8010206@uniten.edu.my> <9543b3a40909192044m6c0b7a8etaffc2b8a573ce4eb@mail.gmail.com> Message-ID: <4AB5AEE8.4050505@uniten.edu.my> Jordi Guti?rrez Hermos wrote: > If you want to mix Debian and Ubuntu packages, despite warnings of > possible instability, use apt. That is, add a source line for Debian > repositories in /etc/apt/sources.list and use apt to install them. > No, I don't 'want to mix' any packages!! I want and need to get Eidors working, which did the trick as it seems until Octave 2.9 (or so). A friend of mine, on Windows, downloaded 3.2.2, and it failed miserably. Then he suggested I try on Linux, and I did, on Ubuntu 9.04, and it also failed, not quite as miserable. Then I headed here with the error messages, and was told that 'probably' 3.2.2. would not fail. So I have been trying since then to check this out, hoping it would not fail, but until now can't find a binary package nor install from source. OMG, I'd say. Most projects with the size of Octave have regular updates and repositories of binaries available, the current version has been out - if I am not mistaken - for 3 months or more. Why does Octave not offer recent packages for widely used distributions? I am sure, it could attract quite a number of followers, if one didn't have to dig through sourcecode stuff, and compilation? And then some people wonder, when the year of 'Linux on the desktop' will finally be there; respectively, why it isn't yet. :( And if it compiles, it would be rather simple, to make it into a .deb; as far as I remember. Did the same years ago for some software. Uwe From tomdean at speakeasy.org Sat Sep 19 23:59:53 2009 From: tomdean at speakeasy.org (Thomas D. Dean) Date: Sat, 19 Sep 2009 21:59:53 -0700 Subject: Octave 3.2.2 for Ubuntu9.04? In-Reply-To: <4AB5AEE8.4050505@uniten.edu.my> References: <4AB426C9.4030601@uniten.edu.my> <9543b3a40909182208t777f251bn30050dc2a44d92a7@mail.gmail.com> <4AB4EBDD.8010206@uniten.edu.my> <9543b3a40909192044m6c0b7a8etaffc2b8a573ce4eb@mail.gmail.com> <4AB5AEE8.4050505@uniten.edu.my> Message-ID: <1253422793.4629.74.camel@asus> On Sun, 2009-09-20 at 12:26 +0800, Uwe Dippel wrote: I have GNU Octave, version 3.2.2 on Ubuntu 9.04. I installed a previous version of octave, I believe 3.0, with apt-get. Then, installed build depends. I built octave 3.2.2. I may have added some -dev packages in response to error messages, I don't remember. From storrsjm at email.uc.edu Sun Sep 20 00:24:17 2009 From: storrsjm at email.uc.edu (Judd Storrs) Date: Sun, 20 Sep 2009 01:24:17 -0400 Subject: Octave 3.2.2 for Ubuntu9.04 -- How to compile from sources In-Reply-To: <4AB5ABF4.4010201@uniten.edu.my> References: <4AB590AF.6080403@uniten.edu.my> <4AB59CE8.20101@uniten.edu.my> <4AB5ABF4.4010201@uniten.edu.my> Message-ID: Ok, new approach since the libcurl4-dev virtual packge isn't working for you maybe if you manually install the build dependencies you can skip the build-dep step. I got the octave3.0_3.0.1-6ubuntu2.dsc from ubuntu ("apt-get source octave3.0"). These are the packages listed as build dependencies: g++-4.1 gcc-4.1 gfortran debhelper autoconf texinfo texlive-latex-base texlive-generic-recommended libreadline5-dev libncurses5-dev gperf libhdf5-serial-dev libhdf5-lam-dev libhdf5-mpich-dev libblas-dev liblapack-dev gnuplot-nox libfftw3-dev texi2html less dpatch slice libpcre3-dev flex libglpk-dev libsuitesparse-dev gawk ghostscript libqhull-dev desktop-file-utils Also install: libcurl4-gnutls-dev libgraphicsmagick++1-dev libfltk-dev libarpack2-dev Then try continuing from step 3 --judd -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090920/0db2054f/attachment.html From jordigh at gmail.com Sun Sep 20 00:46:45 2009 From: jordigh at gmail.com (=?UTF-8?Q?Jordi_Guti=C3=A9rrez_Hermos?=) Date: Sun, 20 Sep 2009 00:46:45 -0500 Subject: Octave 3.2.2 for Ubuntu9.04? In-Reply-To: <4AB5AEE8.4050505@uniten.edu.my> References: <4AB426C9.4030601@uniten.edu.my> <9543b3a40909182208t777f251bn30050dc2a44d92a7@mail.gmail.com> <4AB4EBDD.8010206@uniten.edu.my> <9543b3a40909192044m6c0b7a8etaffc2b8a573ce4eb@mail.gmail.com> <4AB5AEE8.4050505@uniten.edu.my> Message-ID: <9543b3a40909192246h33f49d87v83ba3bd324ca912a@mail.gmail.com> 2009/9/19 Uwe Dippel : > Why does Octave not offer recent packages for widely used distributions? Because it is largely a mistake when a software project makes its own packages for distributions instead of helping or working closely with the distribution to directly incorporate a package for, well, distribution. Packaging for a distribution is a considerable task. Each distribution has slighlty differing rules and policies on how compliation should be made, which packages should be offered, where files should go, how documentation should be presented, how should dependencies be resolved, how source should be offered, etc. etc. Too often software projects will offer their own .debs that are buggy in minute ways because they do not adhere to a distribution's packaging policy. Sure, they're often "good enough" and work, but we should demand certain minimum > And then some people wonder, when the year of 'Linux on the desktop' will > finally be there; respectively, why it isn't yet. :( I understand your frustration, and it is ours all at least part of the time, but you know what they say about candles and cursing the darkness. We are all volunteers. > And if it compiles, it would be rather simple, to make it into a .deb; as > far as I remember. Did the same years ago for some software. It's possible to make a quick-and-dirty .deb that probably works for you, but it's really nothing more than a convenience of tracking the default Octave installation through apt. It is highly unlikely that the default installation of any software package will adhere to Ubuntu or Debian policies, so Octave itself cannot offer such .debs directly and must instead rely on specific packagers like Rafael Laboissiere, Thomas Weber, and infrequently myself. Given your evident frustration, I think the easiest route would be to either follow up on what I suggested and install Debian Octave's with apt and do so carefully, paying close attention to which libraries will get installed from each source, and use apt pinning (don't download .deb's manually and expect them to satisfy dependencies) OR follow up on John Swenson and upgrade your Ubuntu prematurely to the next release of Ubuntu which has the latest Octave packages OR build Octave from source. After you've downloaded the source, your biggest problem with compiling it will no doubt be satisfying dependencies. You can use a little Debian (or Ubuntu) help to satisfy build dependencies by running "apt-get build-dep octave3.2" to get everything you should need to build Octave before you run ./configure && make && sudo checkinstall make install (apt-get build checkinstall to download checkinstall which will make your own aforementioned quick-and-dirty .deb). HTH, - Jordi G. H. From jordigh at gmail.com Sun Sep 20 01:06:58 2009 From: jordigh at gmail.com (=?UTF-8?Q?Jordi_Guti=C3=A9rrez_Hermos?=) Date: Sun, 20 Sep 2009 01:06:58 -0500 Subject: Some Octave newbie questions regarding number format and matrices In-Reply-To: <25522543.post@talk.nabble.com> References: <25522543.post@talk.nabble.com> Message-ID: <9543b3a40909192306v237f6f8bu7768e6a3930cc9f@mail.gmail.com> 2009/9/19 hdfrango : > 1. is there any way to force octave to express numbers in fraction form, to > avoid loss of precision? If you don't want to lose precision, you need a symbolic CAS, like Sage or Maxima, not Octave. Octave is optimised for speed with hardware floats, and although it does have a symbolic addon in the Octave-Forge packages, this is more of an afterthought than core functionality. In particular, it only allows you to change the precision. I don't believe a bignum interface exists for Octave. > 2. when I want to computer the inverse of a matrix, I have to do inv(A'), > computing the inverse of the transpose, in order to get the correct answer. > Why is that? My guess is that you've either found a bizarre bug in Octave, or you are confused about what the inverse of a matrix should be. Can you show us a specific matrix for which inv(A) produces the transpose of the correct inverse? - Jordi G. H. From jordigh at gmail.com Sun Sep 20 01:30:30 2009 From: jordigh at gmail.com (=?UTF-8?Q?Jordi_Guti=C3=A9rrez_Hermos?=) Date: Sun, 20 Sep 2009 01:30:30 -0500 Subject: help me In-Reply-To: References: Message-ID: <9543b3a40909192330n78db236cm8d1e2976bcb8028f@mail.gmail.com> 2009/9/14 diego vega : > quisiera saber si existen o hay que crearlas; las funciones son: > funcion escalon, funcion signo, pulso triangular , inpulso unitario. (in Spanish, Diego is asking if Octave has a step function, a sign function, unit impulse, and triangular pulse. English answer follows below Spanish answer.) Hola Diego. El idioma de la lista es ingl?s, pero varios de nosotros podemos responder en castellano. A?n as?, por favor escribe en ingl?s, pues es el idioma que la mayor?a de suscriptores de la lista hablan. Las funciones que solicitas son muy f?ciles de generar. Por ejemplo, una funci?n escal?n se puede generar f?cilmente a partir las funciones piso y techo (en Octave llamadas floor y ceil). La funci?n signo ya est? implantada y se llama sign en Octave. Creo que con pulso triangular te refieres a una funci?n parecida a ?sta: x.*(heaviside(x) - 2*heaviside(x-1)) + 2*heaviside(x-1) La funci?n Heaviside se encuentra en el paquete de funciones especiales (specfun) de Octave-Forge. No s? qu? es un impulso unitario, pero me imagino que podr?s generarlo tambi?n con la funci?n de Heaviside. Espero esto te ayude, - Jordi G. H. ================== English translation ===================== Hello, Diego. The mailing list language is English, but several of us can answer in Spanish. Even so, please write in English, as it's the language that most of the mailing list subscribers can speak. The functions you request are very easy to generate. For example, a step function can easily be generated by floor and ceiling functions (in Octave, they're called floor and ceil). The sign function is already implemented and it's called sign in Octave. I think by triangular pulse you mean something like this: x.*(heaviside(x) - 2*heaviside(x-1)) + 2*heaviside(x-1) The Heaviside function is in the special functions package (specfun) in Octave-Forge. I don't konw what a unit impulse is, but I can imagine that you can also generate it with the Heaviside function. HTH, - Jordi G. H. From Potorti at isti.cnr.it Sun Sep 20 04:04:12 2009 From: Potorti at isti.cnr.it (Francesco Potorti`) Date: Sun, 20 Sep 2009 11:04:12 +0200 Subject: Octave 3.2.2 for Ubuntu9.04? In-Reply-To: <4AB5AEE8.4050505@uniten.edu.my> References: <4AB426C9.4030601@uniten.edu.my> <9543b3a40909182208t777f251bn30050dc2a44d92a7@mail.gmail.com> <4AB4EBDD.8010206@uniten.edu.my> <9543b3a40909192044m6c0b7a8etaffc2b8a573ce4eb@mail.gmail.com> <4AB5AEE8.4050505@uniten.edu.my> Message-ID: >And if it compiles, it would be rather simple, to make it into a .deb; >as far as I remember. Did the same years ago for some software. Well, it is into a .deb, but since it is new you have to have a very new intallation. What I do, on Debian testing, is to download the experimental .deb packages by hand and install them. I suppose that apt pinning would make my life easier, but this is what I do now and it works. Using the nice debtree package at I built this graphical tree with debtree --max-depth=2 -I octave3.2|dot -Tsvg > octave3.2-deps.svg which produces a graph, in png and svg, that may be useful for those who must choose which packages to download: -- Francesco Potort? (ricercatore) Voice: +39 050 315 3058 (op.2111) ISTI - Area della ricerca CNR Fax: +39 050 315 2040 via G. Moruzzi 1, I-56124 Pisa Email: Potorti at isti.cnr.it (entrance 20, 1st floor, room C71) Web: http://fly.isti.cnr.it/ From thomas.weber.mail at gmail.com Sun Sep 20 04:18:31 2009 From: thomas.weber.mail at gmail.com (Thomas Weber) Date: Sun, 20 Sep 2009 11:18:31 +0200 Subject: Octave 3.2.2 for Ubuntu9.04 -- How to compile from sources In-Reply-To: <4AB590AF.6080403@uniten.edu.my> References: <4AB590AF.6080403@uniten.edu.my> Message-ID: <20090920091831.GB12282@atlan> On Sun, Sep 20, 2009 at 10:17:19AM +0800, Uwe Dippel wrote: > Judd Storrs wrote: > > I really don't think it's that hard to compile from sources on Ubuntu. > > > The following describes how I successfully built octave-3.2.2 on a > > fresh install of Ubuntu 9.04. After I finished install from the CD, I > > used Synaptic to update all Ubuntu packages. I did not change any > > software sources from the defaults. Here's how I proceeded: > > > > [...] > > > > Hope this helps. > > I hope so, too! > > Actually, I'm a FOSS-person myself; a Linux user for 10 years. No, > difficult to do it is not. The thing that's absolutely difficult is the > How To! How should, how could, anyone guess which packages are > necessary; which commands are necessary?? I at least couldn't. > > And still, it doesn't go through here: > > $ sudo apt-get install libcurl4-dev libgraphicsmagick++1-dev libfltk-dev > libarpack2-dev > Package libcurl4-dev is a virtual package provided by: > libcurl4-gnutls-dev 7.18.2-8ubuntu4.1 ^^^^^^ > So I tried the other way: > $ sudo apt-get install libcurl4-openssl-dev If apt tells you it has the gnutls package, why do you try the openssl one? Thomas From hdfrango at gmail.com Sun Sep 20 06:32:35 2009 From: hdfrango at gmail.com (hdfrango) Date: Sun, 20 Sep 2009 04:32:35 -0700 (PDT) Subject: Some Octave newbie questions regarding number format and matrices In-Reply-To: <9543b3a40909192306v237f6f8bu7768e6a3930cc9f@mail.gmail.com> References: <25522543.post@talk.nabble.com> <9543b3a40909192306v237f6f8bu7768e6a3930cc9f@mail.gmail.com> Message-ID: <25529605.post@talk.nabble.com> Jordi Guti?rrez Hermos wrote: > > 2009/9/19 hdfrango : >> 1. is there any way to force octave to express numbers in fraction form, >> to >> avoid loss of precision? > > If you don't want to lose precision, you need a symbolic CAS, like > Sage or Maxima, not Octave. Octave is optimised for speed with > hardware floats, and although it does have a symbolic addon in the > Octave-Forge packages, this is more of an afterthought than core > functionality. In particular, it only allows you to change the > precision. I don't believe a bignum interface exists for Octave. > >> 2. when I want to computer the inverse of a matrix, I have to do inv(A'), >> computing the inverse of the transpose, in order to get the correct >> answer. >> Why is that? > > My guess is that you've either found a bizarre bug in Octave, or you > are confused about what the inverse of a matrix should be. Can you > show us a specific matrix for which inv(A) produces the transpose of > the correct inverse? > > - Jordi G. H > > First of all thank you both for the replies. 1. I will give the tools mentioned a try. 2. As for the matrix issue, I feel really stupid, it turns out even though I knew how to correctly input a matrix in octave, I was somehow entering the transpose, which is why I needed to compute the inverse of the transpose in order to get the expected result :). thanks again -- View this message in context: http://www.nabble.com/Some-Octave-newbie-questions-regarding-number-format-and-matrices-tp25522543p25529605.html Sent from the Octave - General mailing list archive at Nabble.com. From dastew at sympatico.ca Sun Sep 20 08:54:42 2009 From: dastew at sympatico.ca (dastew at sympatico.ca) Date: Sun, 20 Sep 2009 13:54:42 +0000 Subject: Some Octave newbie questions regarding number format and matrices In-Reply-To: <25529605.post@talk.nabble.com> References: <25522543.post@talk.nabble.com> <9543b3a40909192306v237f6f8bu7768e6a3930cc9f@mail.gmail.com> Message-ID: > Date: Sun, 20 Sep 2009 04:32:35 -0700 > From: hdfrango at gmail.com > To: help-octave at octave.org > Subject: Re: Some Octave newbie questions regarding number format and matrices > > > > Jordi Guti?rrez Hermos wrote: > > > > 2009/9/19 hdfrango : > >> 1. is there any way to force octave to express numbers in fraction form, > >> to > >> avoid loss of precision? > > > > If you don't want to lose precision, you need a symbolic CAS, like > > Sage or Maxima, not Octave. Octave is optimised for speed with > > hardware floats, and although it does have a symbolic addon in the > > Octave-Forge packages, this is more of an afterthought than core > > functionality. In particular, it only allows you to change the > > precision. I don't believe a bignum interface exists for Octave. > > > >> 2. when I want to computer the inverse of a matrix, I have to do inv(A'), > >> computing the inverse of the transpose, in order to get the correct > >> answer. > >> Why is that? > > > > My guess is that you've either found a bizarre bug in Octave, or you > > are confused about what the inverse of a matrix should be. Can you > > show us a specific matrix for which inv(A) produces the transpose of > > the correct inverse? > > > > - Jordi G. H > > > > > > First of all thank you both for the replies. > > 1. I will give the tools mentioned a try. > > 2. As for the matrix issue, I feel really stupid, it turns out even though I > knew how to correctly input a matrix in octave, I was somehow entering the > transpose, which is why I needed to compute the inverse of the transpose in > order to get the expected result :). > > thanks again > > -- Hey. we all have done something like that in the past so smile. If you have any more questions , just ask :-) Doug -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090920/7d83d877/attachment.html From m-wright at eskimo.com Sun Sep 20 17:46:56 2009 From: m-wright at eskimo.com (Maynard Wright) Date: Sun, 20 Sep 2009 15:46:56 -0700 Subject: help me In-Reply-To: <9543b3a40909192330n78db236cm8d1e2976bcb8028f@mail.gmail.com> References: <9543b3a40909192330n78db236cm8d1e2976bcb8028f@mail.gmail.com> Message-ID: <200909201546.56749.m-wright@eskimo.com> On Saturday 19 September 2009 23:30, Jordi Guti?rrez Hermos wrote: > 2009/9/14 diego vega : > > quisiera saber si existen o hay que crearlas; las funciones son: > > funcion escalon, funcion signo, pulso triangular , inpulso unitario. > > (in Spanish, Diego is asking if Octave has a step function, a sign > function, unit impulse, and triangular pulse. English answer follows > below Spanish answer.) > > Hola Diego. El idioma de la lista es ingl?s, pero varios de nosotros > podemos responder en castellano. A?n as?, por favor escribe en ingl?s, > pues es el idioma que la mayor?a de suscriptores de la lista hablan. > > Las funciones que solicitas son muy f?ciles de generar. Por ejemplo, > una funci?n escal?n se puede generar f?cilmente a partir las funciones > piso y techo (en Octave llamadas floor y ceil). La funci?n signo ya > est? implantada y se llama sign en Octave. Creo que con pulso triangular > te refieres a una funci?n parecida a ?sta: > > x.*(heaviside(x) - 2*heaviside(x-1)) + 2*heaviside(x-1) > > La funci?n Heaviside se encuentra en el paquete de funciones > especiales (specfun) de Octave-Forge. > > No s? qu? es un impulso unitario, pero me imagino que podr?s generarlo > tambi?n con la funci?n de Heaviside. > > Espero esto te ayude, > - Jordi G. H. > > ================== English translation ===================== > > Hello, Diego. The mailing list language is English, but several of us > can answer in Spanish. Even so, please write in English, as it's the > language that most of the mailing list subscribers can speak. > > The functions you request are very easy to generate. For example, a > step function can easily be generated by floor and ceiling functions > (in Octave, they're called floor and ceil). The sign function is > already implemented and it's called sign in Octave. I think by > triangular pulse you mean something like this: > > x.*(heaviside(x) - 2*heaviside(x-1)) + 2*heaviside(x-1) > > The Heaviside function is in the special functions package (specfun) > in Octave-Forge. > > I don't konw what a unit impulse is, but I can imagine that you can > also generate it with the Heaviside function. > > HTH, > - Jordi G. H. > The unit impulse is also sometimes called the impulse function or the delta function. A non-rigorous definition would be the limit of a rectangular pulse (amplitude as a function of time) as the duration in time goes to zero and the area is held constant at 1. Note that the amplitude approaches infinity as the duration (width) approaches zero. The frequency spectrum of the unit impulse has a constant amplitude of 1 at all frequencies. Maynard Wright From udippel at uniten.edu.my Sun Sep 20 22:54:34 2009 From: udippel at uniten.edu.my (Uwe Dippel) Date: Mon, 21 Sep 2009 11:54:34 +0800 Subject: Octave 3.2.2 for Ubuntu9.04 -- How to compile from sources In-Reply-To: References: <4AB590AF.6080403@uniten.edu.my> <4AB59CE8.20101@uniten.edu.my> <4AB5ABF4.4010201@uniten.edu.my> Message-ID: <4AB6F8FA.1090108@uniten.edu.my> Judd Storrs wrote: > Ok, new approach since the libcurl4-dev virtual packge isn't working > for you maybe if you manually install the build dependencies you can > skip the build-dep step. > > I got the octave3.0_3.0.1-6ubuntu2.dsc from ubuntu ("apt-get source > octave3.0"). These are the packages listed as build dependencies: > > g++-4.1 > gcc-4.1 > gfortran > debhelper > autoconf > texinfo > texlive-latex-base > texlive-generic-recommended > libreadline5-dev > libncurses5-dev > gperf > libhdf5-serial-dev > libhdf5-lam-dev > libhdf5-mpich-dev > libblas-dev > liblapack-dev > gnuplot-nox > libfftw3-dev > texi2html > less > dpatch > slice > libpcre3-dev > flex > libglpk-dev > libsuitesparse-dev > gawk > ghostscript > libqhull-dev > desktop-file-utils > > Also install: > > libcurl4-gnutls-dev > libgraphicsmagick++1-dev > libfltk-dev > libarpack2-dev > > Then try continuing from step 3 Thanks so much, Judd! I can confirm that Octave 3.2.2 compiles and installs with these dependencies, with some minor modifications, also suggested by you: leave out: libhdf5-lam-dev libhdf5-mpich-dev add: libftgl-dev libfltk-dev and it goes through. Next, time to try Eidors. octave:1> run /home/udippel/Sources/eidors-v3.3/startup.m warning: you do not have a compiled mex file eidors_var_id. Please compile it using: mex /home/udippel/Sources/eidors-v3.3/arch/eidors_var_id.cpp [exit] This is pdfTeXk, Version 3.141592-1.40.3 (Web2C 7.5.6) %&-line parsing enabled. entering extended mode (/home/udippel/Sources/eidors-v3.3/arch/eidors_var_id.cpp This is MeX Version 1.05 18 XII 1993 (B. Jackowski & M. Ry\'cko) ! Missing $ inserted. $ _ l.1 /* eidors_ var.id: calculate the sha1 hash of variable in memory ? What now? At least, demo_real.m works. Thanks a bunch! Uwe From udippel at uniten.edu.my Sun Sep 20 23:09:41 2009 From: udippel at uniten.edu.my (Uwe Dippel) Date: Mon, 21 Sep 2009 12:09:41 +0800 Subject: Eidors and Octave Message-ID: <4AB6FC85.5080404@uniten.edu.my> [continuation of earlier thread, in which 3.2.2. was suggested] Finally, I got 3.2.2 installed. Alas, out of the Eidors examples: cheating_2d.m demo_3d_simdata.m manchester_tomography.m compare_2d_algs.m demo_complex.m moving_tank_objs.m compare_3d_algs.m demo_real.m resistor_model.m demo_2d_simdata.m image_2d_algs.m only demo_2d_simdata.m and demo_real.m work. The others fail one way or another. About half with structure has no member `cache_priority' Though Google has no result for this. What could I do, please? Uwe From storrsjm at email.uc.edu Sun Sep 20 23:41:01 2009 From: storrsjm at email.uc.edu (Judd Storrs) Date: Mon, 21 Sep 2009 00:41:01 -0400 Subject: Octave 3.2.2 for Ubuntu9.04 -- How to compile from sources In-Reply-To: <4AB6F8FA.1090108@uniten.edu.my> References: <4AB590AF.6080403@uniten.edu.my> <4AB59CE8.20101@uniten.edu.my> <4AB5ABF4.4010201@uniten.edu.my> <4AB6F8FA.1090108@uniten.edu.my> Message-ID: Ok, I don't know eidors at all, but that error about a missing mex file looked simple enough. I downloaded eidors and extracted it to look around. It looks like startup.m expects to be running on octave in windows and doesn't set the path correctly to the mex file otherwise. Also they don't provied a linux version of the mex file so I needs to be compiled. I only found one mex file in there. This gets the startup working: $ cd eidors-v3.3 $ cd arch $ mkoctfile --mex eidors_var_id.cpp $ cp eidors_var_id.mex .. $ cd .. $ octave octave:1> startup warning: isstr is obsolete and will be removed from a future version of Octave, please use ischar instead EIDORS:[Completed setting up of EIDORS Version 3.3 ($Date: 2008/07/19 16:14:18 $)] EIDORS:[Parameter: cache_size=100 MB] EIDORS:[Parameter: mapped_colour=127] EIDORS:[Default background colour: write] EIDORS:[EIDORS mex folder: /home/judd/Desktop/eidors/eidors-v3.3] --judd -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090921/f4226d90/attachment.html From ct529 at york.ac.uk Mon Sep 21 04:01:50 2009 From: ct529 at york.ac.uk (Corrado) Date: Mon, 21 Sep 2009 10:01:50 +0100 Subject: Compiling with and without -march=native: benchmarks Message-ID: <200909211001.50518.ct529@york.ac.uk> Dear Octave friends, here is the benchmark comparison between Octave 322 on Kubuntu 904 64 bit compiled from source with and without the --march=native flag set. It seem that with the new gcc the flag -march-native yields higher performances. What do you think? PS: I believe recompiling lapack and blas with -march=native may lead to even higher performances, but I have found lapack / blas recompilation rather troublesome. Regards COMPILED WITH -O2 -MARCH=NATIVE octave:1> benchmark Octave benchmark version bm 2.3 Speed of octave 3.2.2 on x86_64-unknown-linux-gnu Pentium II 350 MHz has score 1.0, higher numbers are better Matrix inversion (LAPACK) 14.98 +/- 0.1% (252 runs) Schur decomposition (LAPACK) 54.52 +/- 0.4% (322 runs) Differential equation (LSODE) 40.81 +/- 0.2% (980 runs) Fourier transforms (FFTPACK) 23.09 +/- 0.4% (609 runs) for loop 75.20 +/- 3.6% (1365 runs) -- Performance index (bm 2.3): 36 COMPILED WITH -O2 octave:4> benchmark Octave benchmark version bm 2.3 Speed of octave 3.2.2 on x86_64-unknown-linux-gnu Pentium II 350 MHz has score 1.0, higher numbers are better Matrix inversion (LAPACK) 15.11 +/- 0.3% (259 runs) Schur decomposition (LAPACK) 54.36 +/- 0.2% (322 runs) Differential equation (LSODE) 38.54 +/- 0.2% (910 runs) Fourier transforms (FFTPACK) 21.55 +/- 2.8% (567 runs) for loop 63.70 +/- 1.0% (1183 runs) -- Performance index (bm 2.3): 34 -- Corrado Topi Global Climate Change & Biodiversity Indicators Area 18,Department of Biology University of York, York, YO10 5YW, UK Phone: + 44 (0) 1904 328645, E-mail: ct529 at york.ac.uk From udippel at uniten.edu.my Mon Sep 21 04:11:27 2009 From: udippel at uniten.edu.my (Uwe Dippel) Date: Mon, 21 Sep 2009 17:11:27 +0800 Subject: Octave 3.2.2 for Ubuntu9.04? In-Reply-To: <73C230EE-DD3D-4FDC-9CED-BFA8396250E0@comcast.net> References: <4AB426C9.4030601@uniten.edu.my> <9543b3a40909182208t777f251bn30050dc2a44d92a7@mail.gmail.com> <03CAB1BE-0146-4EA5-AE89-AE46AEC0F187@comcast.net> <4AB4EC77.7030602@uniten.edu.my> <73C230EE-DD3D-4FDC-9CED-BFA8396250E0@comcast.net> Message-ID: <4AB7433F.7030001@uniten.edu.my> John Swensen wrote: > > You can upgrade from 9.04 to 9.10 by either downloading the ISO and > reinstalling completely, or upgrading using the update manager by > doing the following (found on an Ubuntu mailing list http://ubuntuforums.org/showthread.php?t=1185036 > and I have used 2 time with no problems): > > 1) Open a terminal > 2) Run update-manager -d > 3) Click the button that offers an upgrade. > > Hope this helps you get a recent version of Octave up and running more > quickly. > Don't. Ever. I'm lucky I didn't do that in the first place, now I *tried* on a machine on the side, not my 'production' desktop. > I upgraded from a working and freshly updated 9.04 (apt-get update && > apt-get upgrade) to Alpha 6, with > update-manager -d > after it had worked well on my netbook. > Despite of the upgrade going through without a hitch, after reboot > everything is damaged, it seems. I get UNEXPECTED INCONSISTENCIES just > flashing by, in circles. And this with the old as well as the new > kernel, including recovery mode. I can stop the going round in circles > with Ctrl-Alt-Del, which will gracefully shut down the machine. There are lots of people with a similar problem, usually it wouldn't go in circles, but still, not boot at all. https://bugs.launchpad.net/ubuntu/+bug/433829 https://bugs.launchpad.net/ubuntu/+source/e2fsprogs/+bug/427822 https://bugs.launchpad.net/ubuntu/+source/clock-setup/+bug/423247 Uwe From highegg at gmail.com Mon Sep 21 04:21:46 2009 From: highegg at gmail.com (Jaroslav Hajek) Date: Mon, 21 Sep 2009 11:21:46 +0200 Subject: Compiling with and without -march=native: benchmarks In-Reply-To: <200909211001.50518.ct529@york.ac.uk> References: <200909211001.50518.ct529@york.ac.uk> Message-ID: <69d8d540909210221k6146b027rf404b22dfca1d468@mail.gmail.com> On Mon, Sep 21, 2009 at 11:01 AM, Corrado wrote: > Dear Octave friends, > > here is the benchmark comparison between Octave 322 on Kubuntu 904 64 bit > compiled from source with and without the --march=native flag set. > > It seem that with the new gcc the flag -march-native yields higher > performances. > > What do you think? > The most relevant is the for loop benchmark. In the others, the bulk of the work is done in libraries and -march=native brings you little benefits. Did you include -march=native in FFLAGS? > PS: I believe recompiling lapack and blas with -march=native may lead to even > higher performances, but I have found lapack / blas recompilation rather > troublesome. > It's not that hard, but regarding the BLAS, it makes little sense to do so with the reference BLAS implementation. A tuned implementation such as ATLAS or some of the non-free ones will bring you much better speed. -- RNDr. Jaroslav Hajek computing expert & GNU Octave developer Aeronautical Research and Test Institute (VZLU) Prague, Czech Republic url: www.highegg.matfyz.cz From ct529 at york.ac.uk Mon Sep 21 04:29:37 2009 From: ct529 at york.ac.uk (Corrado) Date: Mon, 21 Sep 2009 10:29:37 +0100 Subject: Compiling with and without -march=native: benchmarks In-Reply-To: <69d8d540909210221k6146b027rf404b22dfca1d468@mail.gmail.com> References: <200909211001.50518.ct529@york.ac.uk> <69d8d540909210221k6146b027rf404b22dfca1d468@mail.gmail.com> Message-ID: <200909211029.37403.ct529@york.ac.uk> On Monday 21 September 2009 10:21:46 Jaroslav Hajek wrote: > benefits. Did you include -march=native in FFLAGS? yes > It's not that hard, but regarding the BLAS, it makes little sense to > do so with the reference BLAS implementation. A tuned implementation > such as ATLAS or some of the non-free ones will bring you much better > speed. yes, I have atlas. I try not to use non free (as in speech) software. So these are benchmarks carried out with purely free software / open source software. Best, -- Corrado Topi Global Climate Change & Biodiversity Indicators Area 18,Department of Biology University of York, York, YO10 5YW, UK Phone: + 44 (0) 1904 328645, E-mail: ct529 at york.ac.uk From highegg at gmail.com Mon Sep 21 04:44:18 2009 From: highegg at gmail.com (Jaroslav Hajek) Date: Mon, 21 Sep 2009 11:44:18 +0200 Subject: Compiling with and without -march=native: benchmarks In-Reply-To: <200909211029.37403.ct529@york.ac.uk> References: <200909211001.50518.ct529@york.ac.uk> <69d8d540909210221k6146b027rf404b22dfca1d468@mail.gmail.com> <200909211029.37403.ct529@york.ac.uk> Message-ID: <69d8d540909210244q13c26a86m3ce0663129e0ad46@mail.gmail.com> On Mon, Sep 21, 2009 at 11:29 AM, Corrado wrote: > On Monday 21 September 2009 10:21:46 Jaroslav Hajek wrote: >> benefits. Did you include -march=native in FFLAGS? > > yes > >> It's not that hard, but regarding the BLAS, it makes little sense to >> do so with the reference BLAS implementation. A tuned implementation >> such as ATLAS or some of the non-free ones will bring you much better >> speed. > > yes, I have atlas. I try not to use non free (as in speech) software. So these > are benchmarks carried out with purely free software / open source software. > A self-compiled ATLAS? That is typically faster, because it will adapt to your machine better. In general, ATLAS will be able to discover your machine's capabilities itself, so there's little need to specify performance flags. -- RNDr. Jaroslav Hajek computing expert & GNU Octave developer Aeronautical Research and Test Institute (VZLU) Prague, Czech Republic url: www.highegg.matfyz.cz From przemek at nist.gov Mon Sep 21 07:21:37 2009 From: przemek at nist.gov (Przemek Klosowski) Date: Mon, 21 Sep 2009 08:21:37 -0400 Subject: Some Octave newbie questions regarding number format and matrices In-Reply-To: <9543b3a40909192306v237f6f8bu7768e6a3930cc9f@mail.gmail.com> References: <25522543.post@talk.nabble.com> <9543b3a40909192306v237f6f8bu7768e6a3930cc9f@mail.gmail.com> Message-ID: <4AB76FD1.7050306@nist.gov> On 09/20/2009 02:06 AM, Jordi Guti?rrez Hermos wrote: > 2009/9/19 hdfrango: >> 1. is there any way to force octave to express numbers in fraction form, to >> avoid loss of precision? > > If you don't want to lose precision, you need a symbolic CAS, like > Sage or Maxima, not Octave. True in general, but you can use the command 'format rat' to at least output the numbers as fractions: octave:7> 1/3 ans = 1/3 octave:8> pi ans = 355/113 There's also the rat() function that calculates rational approximations to numbers to a given tolerance. From WGHM.Janssen at science.ru.nl Mon Sep 21 03:56:38 2009 From: WGHM.Janssen at science.ru.nl (Wim Janssen) Date: Mon, 21 Sep 2009 10:56:38 +0200 Subject: Octave and Scientific Linux Message-ID: <4AB73FC6.9010905@science.ru.nl> Hello Folks, As a system-administrator I got several questions and requests to have the Octave-package installed on our workstation-computers. I think that's a very good suggestion and I-am very positive about this. But unfortunately I was not able to install this package on our workstations. As you know Scientific Linux is very close to the RedHat Distribution, but it is made more mature to face the high demands on Cern where this Linux-distribution originates. Here is my try-to-have-it installed session: - Installation from the source-rpm [root at schiedam octave-modules]# rpmbuild --rebuild --target i686 --define \ > "kernel_topdir /lib/modules/2.6.18-128.1.6.el5/build" \ > /root/octave-modules/octave-3.0.1-2.el5.src.rpm Installing /root/octave-modules/octave-3.0.1-2.el5.src.rpm warning: InstallSourcePackage: Header V3 DSA signature: NOKEY, key ID 217521 warning: user mockbuild does not exist - using root warning: group mockbuild does not exist - using root warning: user mockbuild does not exist - using root warning: group mockbuild does not exist - using root Building target platforms: i686 Building for target i686 error: Failed build dependencies: hdf5-devel is needed by octave-3.0.1-2.i686 [root at schiedam octave-modules]# - I don't know where to find the proper hdf5-devel module for my SL-distribution. - Building Octave completely from source. The ./configure runs okay. The 'make' runs very long without errors but than stumbles and stops a few inches before reaching the finish-line. :-( Help is very Welcome Kind regards, Wim Janssen -- Radboud Universiteit Nijmegen Phone: +31(0)24-3652097 [ Wim Janssen ] Hoge Energie Fysica HG03.822 Fax: +31(0)24-3652191 Systeembeheer Toernooiveld 1 E-mail: WGHM.Janssen at science.ru.nl 6525 ED Nijmegen URL: http://www.hef.ru.nl From Bart.Vandewoestyne at telenet.be Mon Sep 21 12:20:00 2009 From: Bart.Vandewoestyne at telenet.be (Bart Vandewoestyne) Date: Mon, 21 Sep 2009 19:20:00 +0200 Subject: startup with .octaverc on Windows Vista Message-ID: <20090921172000.GA8578@simba> Hello, One of our sysadmins installed Octave 3.2.2 on Windows Vista so that we can use it as a Matlab replacement for our student's laboratory sessions. I went to test the setup today, and i figured out that the .octaverc file did not get read from the student's H:-drive, which is the network drive containing their home directory. I noticed that the HOME environment variable is not set, but the HOMEDRIVE points to C: and HOMEPATH to \Users\myusername So if i place the .octaverc file in C:\Users\myusername then it gets read. So i can ask students each time they login, to copy the .octaverc file to C:\Users\myusername but that seems annoying. It would be better if they only created .octaverc once in their H:-drive homedirectory. So therefore, we will have to make sure that Octave searches for the .octaverc file in the H:\ path. While googling, i found http://www.nabble.com/Home-directory-in-octave-on-windows--td23772097.html and it seems like there exist several environment variables that are candidates, namely: 1) HOME 2) HOMEDRIVE + HOMEPATH 3) USERPROFILE My questions are: 1) What environment variables does Octave read and use to search for an .octaverc file? 2) Considering that I am looking for a clean and long-term solution, what would be the best environment variable to use on Windows Vista? Thanks for any advice, Bart -- "Share what you know. Learn what you don't." From ar63 at evansville.edu Mon Sep 21 13:43:26 2009 From: ar63 at evansville.edu (Richardson, Anthony) Date: Mon, 21 Sep 2009 13:43:26 -0500 Subject: startup with .octaverc on Windows Vista In-Reply-To: <20090921172000.GA8578@simba> References: <20090921172000.GA8578@simba> Message-ID: <2318D9796D5B9D41B85612B5C87F224002350E5A@UEEXCHANGE.evansville.edu> We have a similar setup. We set HOME in the C:/octave/3.22.2_gcc-4.3.0/share/octave/site/m/startup/octaverc file, with the following lines: setenv('HOME','h:\'); cd ~; This allows the octave HOME env variable to be set differently than a Vista global HOME environment variable. An .octaverc file in h:\ is still executed. Setting HOME from Windows should work too, but we have other software that uses the HOME environment variable and requires that it be set to something else. Tony Richardson > -----Original Message----- > From: Bart Vandewoestyne [mailto:Bart.Vandewoestyne at telenet.be] > Sent: Monday, September 21, 2009 12:20 PM > To: help-octave at octave.org > Subject: startup with .octaverc on Windows Vista > > Hello, > > One of our sysadmins installed Octave 3.2.2 on Windows Vista so > that we can use it as a Matlab replacement for our student's > laboratory sessions. > > I went to test the setup today, and i figured out that the > .octaverc file did not get read from the student's H:-drive, > which is the network drive containing their home directory. > > I noticed that the HOME environment variable is not set, but the > HOMEDRIVE points to C: and HOMEPATH to \Users\myusername > > So if i place the .octaverc file in C:\Users\myusername then it > gets read. So i can ask students each time they login, to copy > the .octaverc file to C:\Users\myusername but that seems > annoying. It would be better if they only created .octaverc > once in their H:-drive homedirectory. So therefore, we will have > to make sure that Octave searches for the .octaverc file in the > H:\ path. While googling, i found > > http://www.nabble.com/Home-directory-in-octave-on-windows-- > td23772097.html > > and it seems like there exist several environment variables that > are candidates, namely: > > 1) HOME > > 2) HOMEDRIVE + HOMEPATH > > 3) USERPROFILE > > My questions are: > > 1) What environment variables does Octave read and use to search > for an .octaverc file? > > 2) Considering that I am looking for a clean and long-term solution, > what would be the best environment variable to use on Windows > Vista? > > Thanks for any advice, > Bart > > -- > "Share what you know. Learn what you don't." > _______________________________________________ > Help-octave mailing list > Help-octave at octave.org > https://www-old.cae.wisc.edu/mailman/listinfo/help-octave From ottar-s at hotmail.com Tue Sep 22 11:29:28 2009 From: ottar-s at hotmail.com (=?Windows-1252?B?T3R0YXIgU+Z0cmU=?=) Date: Tue, 22 Sep 2009 18:29:28 +0200 Subject: Plotting problems Message-ID: Hi, So far I have worked with matrices, but now I want to make plots. That?s not easy. When I try the command: plot(x, y); I get a series of answers. In the first lines I read: ?sh: gnuplot: not found?. When there are a lot of errors, mostly with if-statements, but also a for-loop. Errors are one time located to: ?/octave/3.0.0/m/miscellanous/compare_versions.m And three times located to ?/octave/3.0.0/m/plot/drawnow.m I have heard that I need to download a plot packet called V3.0. I also tried to upgrade octave. When I try to upgrade octave with the command ?sudo apt-get build-dep octave? I get the message: ?Can?t find a source code packet for octave? Thanks for any advice, Ottar S?tre _________________________________________________________________ Drag n? drop?Get easy photo sharing with Windows Live? Photos. http://www.microsoft.com/windows/windowslive/products/photos.aspx -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090922/71768bc3/attachment.html From soren at hauberg.org Tue Sep 22 11:41:48 2009 From: soren at hauberg.org (=?ISO-8859-1?Q?S=F8ren?= Hauberg) Date: Tue, 22 Sep 2009 18:41:48 +0200 Subject: Plotting problems In-Reply-To: References: Message-ID: <1253637708.4423.2.camel@sh-t400> tir, 22 09 2009 kl. 18:29 +0200, skrev Ottar S?tre: > I get a series of answers. In the first lines I read: ?sh: gnuplot: > not found?. Sounds like you need to install 'gnuplot'. If it is already installed, perhaps you should look at the 'gnuplot_binary' function in Octave. S?ren From gbarrick at walsh.edu Tue Sep 22 11:44:59 2009 From: gbarrick at walsh.edu (George Barrick) Date: Tue, 22 Sep 2009 12:44:59 -0400 Subject: Feature request. Message-ID: <4B30AD0BED19E842AAE88DC39736493123CC00BD99@mail3.walsh.edu> Subject: feature request. 2009.09.22.12:15:56 EDT Hello GNU Octave folks, I'd like to request that the 'position' property of figure() windows be implemented in Octave. I typically like to have fine control over the diagrams that I exhibit for my students. I _can_ get control over the proportions of the graphing window with print statements like: print -djpeg "-S384,384" f44posn.jpg ; in my octave scripts. However, it would be nice if the X11-display of the graph precisely mimicked the print output whenever I demand of the octave-interpreter a window having particular proportions. With my current set-up: WinXP Pro. SP3 ver. 5.1 build 2600 CygWin 1.7.0-61 Xorg-x11 1.6.3-1 Octave 3.2.3-1 Gnuplot 4.2.4-1 the octave-interpreter ignores me when I set the 'postion' property of my figure(). It always creates an x11-window that is 640x480. If this is already done in the octave-3.3 development, forgive my ignorance. I haven't had time to keep up with the development code in the mercurial repository. Anyone who is interested in such a feature can see whether this behavior is reproduced on their local set-up. At the end of this post is my script for a parabola where I ask octave to create a square window. Note that the statement in my script: set( kdle,'NextPlot','add') ; is important. If I run the script without that line, octave seems to re-spawn the axes upon further graphics calls, and does whatever it pleases with the figure and axis properties. Thanks, George gbarrick at walsh.edu http://www.gbarrick.net % %********D%********D%********D%********D%********D%********D%********D%* %% Set up graphing parameters. Set vectors that state %% window position and size. winXst = 256 ; winYst = 256 ; winWdt = 256 ; winHgt = 256 ; winPos = [ winXst winYst winWdt winHgt ] ; %********D%********D%********D%********D%********D%********D%********D%* %% Set the vector that gives area inside the window where %% axes will be drawn. All locations are stated relative %% to the window position. Use window width and height %% as denominators. win = [ winWdt winHgt winWdt winHgt ] ; plotWdt = 210 ; plotHgt = 210 ; plotXst = 38 ; plotYst = 38 ; plotPos = [ plotXst plotYst plotWdt plotHgt ] ./ win ; %% Set limits for the axes. xlims = [ 0.00, 2.10 ] ; ylims = [ 0.00, 2.10 ] ; %********D%********D%********D%********D%********D%********D%********D%***f** %% The graphics functions figure() and axes() are called using %% the settings previously written up. Use "hdle" as the graphics %% handle for the figure window. hdle = figure() ; set( hdle,'Position',winPos ) ; %% Spawn axes first, then re-configure them. kdle = axes() ; set( kdle,'Position',plotPos ) ; set( kdle,'XLim',xlims,'YLim',ylims ) ; set( kdle,'NextPlot','add') ; %% Create the axis labels. kt3 = xlabel( 'x(t)' ) ; ku3 = ylabel( 'y(t)' ) ; %% Create the graph. xrow = [ 0.00 : 0.02 : 0.62 ] ; xvals = [ xrow , 2*sqrt(5)/7 ] ; wunz = ones( size( xvals ) ) ; gee = 9.80 ; yvals = ( -0.5 * gee * ( xvals.^2 )) + ( 2.0 * wunz ) ; l1 = plot( xvals, yvals, 'k-' ); set(l1,'LineWidth',2) ; hndle = [ hdle; kdle; kt3; ku3; l1 ]; %% print -djpeg "-S384,384" f44posn.jpg; % From shermanj at umd.edu Tue Sep 22 16:44:49 2009 From: shermanj at umd.edu (James Sherman Jr.) Date: Tue, 22 Sep 2009 17:44:49 -0400 Subject: Feature request. In-Reply-To: <4B30AD0BED19E842AAE88DC39736493123CC00BD99@mail3.walsh.edu> References: <4B30AD0BED19E842AAE88DC39736493123CC00BD99@mail3.walsh.edu> Message-ID: <6800c3890909221444i73d5114dtbbd4ba9bb7bb004@mail.gmail.com> I believe that this is/was a problem with gnuplot rather than with octave, but I believe that this has been fixed in the most recent version. http://www.nabble.com/gnuplot--%3E-octave-communication-of-figure-position-to21736426.html#a21736426 http://www.nabble.com/-changeset--figure-position-property-support-for-gnuplot---x11-to21260890.html#a21260890 http://www.nabble.com/gnuplot%2C-figure.position%2C---the-moving-window-to22069067.html#a22069067 http://www.nabble.com/Figure-Position-to24790735.html#a24790735 I can't test it currently, but this is what I found from a quick search of the archives. On Tue, Sep 22, 2009 at 12:44 PM, George Barrick wrote: > Subject: feature request. > > 2009.09.22.12:15:56 EDT > > Hello GNU Octave folks, > > I'd like to request that the 'position' property > of figure() windows be implemented in Octave. > > I typically like to have fine control over the > diagrams that I exhibit for my students. I _can_ get > control over the proportions of the graphing window > with print statements like: > > print -djpeg "-S384,384" f44posn.jpg ; > > in my octave scripts. However, it would be nice if > the X11-display of the graph precisely mimicked the > print output whenever I demand of the octave-interpreter > a window having particular proportions. > > With my current set-up: > > WinXP Pro. SP3 ver. 5.1 build 2600 > CygWin 1.7.0-61 > Xorg-x11 1.6.3-1 > Octave 3.2.3-1 > Gnuplot 4.2.4-1 > > the octave-interpreter ignores me when I set the > 'postion' property of my figure(). It always creates > an x11-window that is 640x480. > > If this is already done in the octave-3.3 development, > forgive my ignorance. I haven't had time to keep up > with the development code in the mercurial repository. > > Anyone who is interested in such a feature can > see whether this behavior is reproduced on their local > set-up. At the end of this post is my script for > a parabola where I ask octave to create a square window. > Note that the statement in my script: > > set( kdle,'NextPlot','add') ; > > is important. If I run the script without that line, > octave seems to re-spawn the axes upon further graphics > calls, and does whatever it pleases with the figure and > axis properties. > > Thanks, > > George gbarrick at walsh.edu > http://www.gbarrick.net > > > % > %********D%********D%********D%********D%********D%********D%********D%* > %% Set up graphing parameters. Set vectors that state > %% window position and size. > > winXst = 256 ; > winYst = 256 ; > winWdt = 256 ; > winHgt = 256 ; > > winPos = [ winXst winYst winWdt winHgt ] ; > > %********D%********D%********D%********D%********D%********D%********D%* > %% Set the vector that gives area inside the window where > %% axes will be drawn. All locations are stated relative > %% to the window position. Use window width and height > %% as denominators. > > win = [ winWdt winHgt winWdt winHgt ] ; > > plotWdt = 210 ; > plotHgt = 210 ; > plotXst = 38 ; > plotYst = 38 ; > > plotPos = [ plotXst plotYst plotWdt plotHgt ] ./ win ; > > %% Set limits for the axes. > > xlims = [ 0.00, 2.10 ] ; > ylims = [ 0.00, 2.10 ] ; > > > %********D%********D%********D%********D%********D%********D%********D%***f** > %% The graphics functions figure() and axes() are called using > %% the settings previously written up. Use "hdle" as the graphics > %% handle for the figure window. > > hdle = figure() ; > set( hdle,'Position',winPos ) ; > > %% Spawn axes first, then re-configure them. > kdle = axes() ; > set( kdle,'Position',plotPos ) ; > set( kdle,'XLim',xlims,'YLim',ylims ) ; > set( kdle,'NextPlot','add') ; > > %% Create the axis labels. > > kt3 = xlabel( 'x(t)' ) ; > ku3 = ylabel( 'y(t)' ) ; > > %% Create the graph. > > xrow = [ 0.00 : 0.02 : 0.62 ] ; > xvals = [ xrow , 2*sqrt(5)/7 ] ; > > wunz = ones( size( xvals ) ) ; > > gee = 9.80 ; > > yvals = ( -0.5 * gee * ( xvals.^2 )) + ( 2.0 * wunz ) ; > > l1 = plot( xvals, yvals, 'k-' ); > set(l1,'LineWidth',2) ; > > > hndle = [ hdle; kdle; kt3; ku3; l1 ]; > > %% print -djpeg "-S384,384" f44posn.jpg; > % > > > _______________________________________________ > Help-octave mailing list > Help-octave at octave.org > https://www-old.cae.wisc.edu/mailman/listinfo/help-octave > -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090922/b889abac/attachment.html From Bart.Vandewoestyne at telenet.be Thu Sep 24 01:19:26 2009 From: Bart.Vandewoestyne at telenet.be (Bart Vandewoestyne) Date: Thu, 24 Sep 2009 08:19:26 +0200 Subject: startup with .octaverc on Windows Vista In-Reply-To: <2318D9796D5B9D41B85612B5C87F224002350E5A@UEEXCHANGE.evansville.edu> References: <20090921172000.GA8578@simba> <2318D9796D5B9D41B85612B5C87F224002350E5A@UEEXCHANGE.evansville.edu> Message-ID: <20090924061926.GA16446@simba> On Mon, Sep 21, 2009 at 01:43:26PM -0500, Richardson, Anthony wrote: > We have a similar setup. We set HOME in the > C:/octave/3.22.2_gcc-4.3.0/share/octave/site/m/startup/octaverc > file, with the following lines: > > setenv('HOME','h:\'); > cd ~; > > This allows the octave HOME env variable to be set differently > than a Vista global HOME environment variable. An .octaverc > file in h:\ is still executed. Setting HOME from Windows > should work too, but we have other software that uses the HOME > environment variable and requires that it be set to something > else. > > Tony Richardson Thanks for your reply, Tony. In our computer-rooms, we are doing it now the way you describe, and everything works nicely. The Octave desktop-icon is now shining on all our student-computers :-) I do have another question related to the installer though... For our sysadmins, it would be comfortable if they can do a silent (unattended) install. For as far as I can see, Octave uses the NSIS installer system (http://nsis.sourceforge.net) and it has an option /S with which one can do a silent install (see for example http://unattended.sourceforge.net/installers.php) However, if one performs a silent install, then apparently the installation is done with the *default* options, that is, no Octave-Forge packages are installed and one cannot select another Atlas library. Is it somehow possible to do a silent (unattended) install *with* specifying that Octave-Forge should also be installed? Does the NSIS installer system allow a user to specify certain installation options somehow? Thanks, Bart -- "Share what you know. Learn what you don't." From dryeyedman at gmail.com Thu Sep 24 12:55:05 2009 From: dryeyedman at gmail.com (Enrique Sahagun) Date: Thu, 24 Sep 2009 19:55:05 +0200 Subject: Octave GUI tools for Windows XP Message-ID: <4ABBB279.4050108@gmail.com> Hi all: I'm new in Octave and I have learnt how to make some interesting calculations with it. Now I'm working in an image tracking software (to follow an object on a video sequence). I would like this program to have an interface and I know that with MatLab it is possible to make friendly interfaces. And I was wondering, IT IS POSSIBLE TO CREATE AN INTERFACE FOR YOUR SCRIPT IN OCTAVE?. PD: I'm using octave over windows XP. Thanks in advance. From primozz.peterlin at gmail.com Fri Sep 25 02:38:43 2009 From: primozz.peterlin at gmail.com (Primoz PETERLIN) Date: Fri, 25 Sep 2009 09:38:43 +0200 Subject: Regional maxima of an image Message-ID: Hello everybody, Does Octave already has a function which returns a map of regional maxima (I am looking for something like imregionalmax() from Matlab Image Processing Toolbox), or would it be worthwhile to write one? All the best, Primoz -- Primo? Peterlin, In?titut za biofiziko, Med. fakulteta, Univerza v Ljubljani Lipi?eva 2, SI-1000 Ljubljana, Slovenija. primoz.peterlin at mf.uni-lj.si Tel +386-1-5437612, fax +386-1-4315127, http://biofiz.mf.uni-lj.si/~peterlin/ F8021D69 OpenPGP fingerprint: CB 6F F1 EE D9 67 E0 2F 0B 59 AF 0D 79 56 19 0F From soren at hauberg.org Fri Sep 25 02:45:52 2009 From: soren at hauberg.org (=?ISO-8859-1?Q?S=F8ren?= Hauberg) Date: Fri, 25 Sep 2009 09:45:52 +0200 Subject: Regional maxima of an image In-Reply-To: References: Message-ID: <1253864752.4625.1.camel@sh-t400> fre, 25 09 2009 kl. 09:38 +0200, skrev Primoz PETERLIN: > Does Octave already has a function which returns a map of regional > maxima (I am looking for something like imregionalmax() from Matlab > Image Processing Toolbox), or would it be worthwhile to write one? Does the 'immaximas' from the 'image' package do what you want? If not, could you then describe what 'imregionalmax' does? In either case, I guess it would be nice to have 'imregionalmax' for compatibility. S?ren From drvine at gmail.com Fri Sep 25 03:37:38 2009 From: drvine at gmail.com (Troy Vine) Date: Fri, 25 Sep 2009 10:37:38 +0200 Subject: Unable to get transparent region using patch(...) Message-ID: <1E9E8320-8AEF-4A40-A217-55F373609188@gmail.com> Hi, I am using octave 3.2.2 on OS X 10.5.8 installed using the standard installer. Using the code below, I attempted to create a shaded region transparent to the plotted line. With both X11 and AquaTerm (version 1.0.1) the shaded region is opaque to the plot underneath. If I execute the command > get(p, 'facealpha') afterwards then I get 0.2 as expected. What am I doing wrong? Many thanks, Troy > x = [0:pi/12:2*pi]; > plot(x, sin(x)) > xp = [2 2 3 3]; > yp = [ylim fliplr(ylim)]; > p = patch(xp,yp, 'r'); > set(p,'facealpha',0.2); From jon_goitia at hotmail.com Thu Sep 24 15:24:54 2009 From: jon_goitia at hotmail.com (Jon Goitia) Date: Thu, 24 Sep 2009 20:24:54 +0000 Subject: Installing problems Message-ID: Hi, I wanted to install octave, but I'm not sure on how to do it. I opened the FTP page and downloaded the octave-3.2.2.tar.gz compressed file. I extracted all the files, but I don't know how to install the program. I am using Windows XP. What do I need to do? Thanks _________________________________________________________________ Nuevo Windows Live, un mundo lleno de posibilidades. Desc?brelo. http://www.microsoft.com/windows/windowslive/default.aspx -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090924/846888e1/attachment.html From dryeyedman at gmail.com Fri Sep 25 06:15:24 2009 From: dryeyedman at gmail.com (Enrique Sahagun) Date: Fri, 25 Sep 2009 13:15:24 +0200 Subject: Octave GUI tools for Windows XP In-Reply-To: <4ABCA3B7.4050704@acc.umu.se> References: <4ABBB279.4050108@gmail.com> <4ABCA3B7.4050704@acc.umu.se> Message-ID: <4ABCA64C.1060409@gmail.com> David Grundberg escribi?: > Enrique Sahagun wrote: >> Hi all: >> >> I'm new in Octave and I have learnt how to make some interesting >> calculations with it. Now I'm working in an image tracking software >> (to follow an object on a video sequence). I would like this program >> to have an interface and I know that with MatLab it is possible to >> make friendly interfaces. And I was wondering, IT IS POSSIBLE TO >> CREATE AN INTERFACE FOR YOUR SCRIPT IN OCTAVE?. >> >> PD: I'm using octave over windows XP. >> >> Thanks in advance. >> _______________________________________________ >> Help-octave mailing list >> Help-octave at octave.org >> https://www-old.cae.wisc.edu/mailman/listinfo/help-octave >> > I made a GUI app using Python and GTK+. In that application, I used > Pytave (Octave module for Python) to execute Octave code. I'm the > Pytave maintainer, and I haven't heard anyone building Pytave for > Windows though. Any help with regards to that is welcome. > > I suggest you don't use all caps (LIKE THIS), in my opinion it looks > obnoxious. > > hth, > David > Yeah, my approach at this moment is to learn some Python to try to develope an app to call octave from it. At the moment I'm just trying to taste how difficult would be. And sorry for the caps, I was only trying to underlying the question but you are right. Thanks Enrique From jordigh at gmail.com Fri Sep 25 06:19:00 2009 From: jordigh at gmail.com (=?UTF-8?Q?Jordi_Guti=C3=A9rrez_Hermoso?=) Date: Fri, 25 Sep 2009 06:19:00 -0500 Subject: Installing problems In-Reply-To: References: Message-ID: <9543b3a40909250419r64fe30b2wae52173db00f9434@mail.gmail.com> 2009/9/24 Jon Goitia : > I wanted to install octave, [...] > I am using Windows XP. What do I need to do? You downloaded the source code. Unless you want to compile it yourself, you probably want to download the windows installer from here instead: http://octave.sourceforge.net/ Hope this helps, - Jordi G. H. From individ at acc.umu.se Fri Sep 25 06:04:23 2009 From: individ at acc.umu.se (David Grundberg) Date: Fri, 25 Sep 2009 13:04:23 +0200 Subject: Octave GUI tools for Windows XP In-Reply-To: <4ABBB279.4050108@gmail.com> References: <4ABBB279.4050108@gmail.com> Message-ID: <4ABCA3B7.4050704@acc.umu.se> Enrique Sahagun wrote: > Hi all: > > I'm new in Octave and I have learnt how to make some interesting > calculations with it. Now I'm working in an image tracking software (to > follow an object on a video sequence). I would like this program to have > an interface and I know that with MatLab it is possible to make friendly > interfaces. And I was wondering, IT IS POSSIBLE TO CREATE AN INTERFACE > FOR YOUR SCRIPT IN OCTAVE?. > > PD: I'm using octave over windows XP. > > Thanks in advance. > _______________________________________________ > Help-octave mailing list > Help-octave at octave.org > https://www-old.cae.wisc.edu/mailman/listinfo/help-octave > I made a GUI app using Python and GTK+. In that application, I used Pytave (Octave module for Python) to execute Octave code. I'm the Pytave maintainer, and I haven't heard anyone building Pytave for Windows though. Any help with regards to that is welcome. I suggest you don't use all caps (LIKE THIS), in my opinion it looks obnoxious. hth, David From highegg at gmail.com Fri Sep 25 06:34:56 2009 From: highegg at gmail.com (Jaroslav Hajek) Date: Fri, 25 Sep 2009 13:34:56 +0200 Subject: Octave GUI tools for Windows XP In-Reply-To: <4ABCA64C.1060409@gmail.com> References: <4ABBB279.4050108@gmail.com> <4ABCA3B7.4050704@acc.umu.se> <4ABCA64C.1060409@gmail.com> Message-ID: <69d8d540909250434m423dc3ectaeb5db6505ec5cc4@mail.gmail.com> On Fri, Sep 25, 2009 at 1:15 PM, Enrique Sahagun wrote: > David Grundberg escribi?: >> Enrique Sahagun wrote: >>> Hi all: >>> >>> I'm new in Octave and I have learnt how to make some interesting >>> calculations with it. Now I'm working in an image tracking software >>> (to follow an object on a video sequence). I would like this program >>> to have an interface and I know that with MatLab it is possible to >>> make friendly interfaces. And I was wondering, IT IS POSSIBLE TO >>> CREATE AN INTERFACE FOR YOUR SCRIPT IN OCTAVE?. >>> >>> PD: I'm using octave over windows XP. >>> >>> Thanks in advance. >>> _______________________________________________ >>> Help-octave mailing list >>> Help-octave at octave.org >>> https://www-old.cae.wisc.edu/mailman/listinfo/help-octave >>> >> I made a GUI app using Python and GTK+. In that application, I used >> Pytave (Octave module for Python) to execute Octave code. I'm the >> Pytave maintainer, and I haven't heard anyone building Pytave for >> Windows though. Any help with regards to that is welcome. >> >> I suggest you don't use all caps (LIKE THIS), in my opinion it looks >> obnoxious. >> >> hth, >> David >> > Yeah, my approach at this moment is to learn some Python to try to > develope an app to call octave from it. At the moment I'm just trying to > taste how difficult would be. > With Pytave, it should be easier than, for instance, communicating through the subprocess module. More efficient as well. Pretty good for embedding Octave computations in a larger Python framework (for instance, a web app). > And sorry for the caps, I was only trying to underlying the question but > you are right. > > Thanks > Enrique > _______________________________________________ > Help-octave mailing list > Help-octave at octave.org > https://www-old.cae.wisc.edu/mailman/listinfo/help-octave > -- RNDr. Jaroslav Hajek computing expert & GNU Octave developer Aeronautical Research and Test Institute (VZLU) Prague, Czech Republic url: www.highegg.matfyz.cz From dryeyedman at gmail.com Fri Sep 25 06:39:47 2009 From: dryeyedman at gmail.com (Enrique Sahagun) Date: Fri, 25 Sep 2009 13:39:47 +0200 Subject: Octave GUI tools for Windows XP In-Reply-To: <69d8d540909250434m423dc3ectaeb5db6505ec5cc4@mail.gmail.com> References: <4ABBB279.4050108@gmail.com> <4ABCA3B7.4050704@acc.umu.se> <4ABCA64C.1060409@gmail.com> <69d8d540909250434m423dc3ectaeb5db6505ec5cc4@mail.gmail.com> Message-ID: <4ABCAC03.2010902@gmail.com> Jaroslav Hajek escribi?: > On Fri, Sep 25, 2009 at 1:15 PM, Enrique Sahagun wrote: > >> David Grundberg escribi?: >> >>> Enrique Sahagun wrote: >>> >>>> Hi all: >>>> >>>> I'm new in Octave and I have learnt how to make some interesting >>>> calculations with it. Now I'm working in an image tracking software >>>> (to follow an object on a video sequence). I would like this program >>>> to have an interface and I know that with MatLab it is possible to >>>> make friendly interfaces. And I was wondering, IT IS POSSIBLE TO >>>> CREATE AN INTERFACE FOR YOUR SCRIPT IN OCTAVE?. >>>> >>>> PD: I'm using octave over windows XP. >>>> >>>> Thanks in advance. >>>> _______________________________________________ >>>> Help-octave mailing list >>>> Help-octave at octave.org >>>> https://www-old.cae.wisc.edu/mailman/listinfo/help-octave >>>> >>>> >>> I made a GUI app using Python and GTK+. In that application, I used >>> Pytave (Octave module for Python) to execute Octave code. I'm the >>> Pytave maintainer, and I haven't heard anyone building Pytave for >>> Windows though. Any help with regards to that is welcome. >>> >>> I suggest you don't use all caps (LIKE THIS), in my opinion it looks >>> obnoxious. >>> >>> hth, >>> David >>> >>> >> Yeah, my approach at this moment is to learn some Python to try to >> develope an app to call octave from it. At the moment I'm just trying to >> taste how difficult would be. >> >> > > With Pytave, it should be easier than, for instance, communicating > through the subprocess module. More efficient as well. > Pretty good for embedding Octave computations in a larger Python > framework (for instance, a web app). > > >> And sorry for the caps, I was only trying to underlying the question but >> you are right. >> >> Thanks >> Enrique >> _______________________________________________ >> Help-octave mailing list >> Help-octave at octave.org >> https://www-old.cae.wisc.edu/mailman/listinfo/help-octave >> >> > > > Ok, but does Pytave work in Windows XP? I work on both Unix systems and Windows but for this particular project I need to create a friendly interface on Windows, able to run (and write) Octave. From mbmiller+l at gmail.com Fri Sep 25 16:02:46 2009 From: mbmiller+l at gmail.com (Mike Miller) Date: Fri, 25 Sep 2009 16:02:46 -0500 (CDT) Subject: noncentral F cdf Message-ID: Do we have a function that can compute the noncentral F cdf? I'm using the Octave package on Ubuntu and it doesn't look like I have it but it might be out there somewhere else. Thanks in advance! Mike From hellyj at ucsd.edu Fri Sep 25 19:49:38 2009 From: hellyj at ucsd.edu (Helly John) Date: Fri, 25 Sep 2009 17:49:38 -0700 Subject: Problem with octave/gnuplot/aquaterm on Snow Leopard In-Reply-To: References: Message-ID: Hi. I'm new to Octave and gnuplot and Aquaterm but have just installed all of these on my system. Here's the configuration: - Mac OS X 10.6.1 - AquaTerm v1.0.1 (1.0.1) - Octave-3.2.2 - GNUPLOT 4.2 patchlevel 6 When I try to plot in octave this is what happens: ***************************************************************** octave-3.2.2:1> Y=[1:10] Y = 1 2 3 4 5 6 7 8 9 10 octave-3.2.2:2> plot(Y) Unknown or ambiguous terminal name 'aqua' gnuplot> set terminal aqua enhanced title "Figure 1" size 560 420 ^ line 0: unknown or ambiguous terminal type; type just 'set terminal' for a list line 0: No terminal defined gnuplot> plot "-" binary format='%float64' record=10 using ($1):($2) axes x1y1 title "" with lines linestyle 1 ; ^ line 0: use 'set term' to set terminal type first octave-3.2.2:3> system ("echo $GNUTERM") aqua ans = 0 octave-3.2.2:4> ***************************************************************** Do you have any suggestions as to what might be wrong? Thanks. ----------------------------------------------- John Helly / San Diego Supercomputer Center & Climate, Atmospheric Science, and Physical Oceanography/Scripps Institution of Oceanography / UCSD / +01 760 840 8660 mobile / stonesteps (Skype) / stonesteps7 (iChat) / http://www.sdsc.edu/~hellyj ----------------------------------------------- John Helly / San Diego Supercomputer Center & Climate, Atmospheric Science, and Physical Oceanography/Scripps Institution of Oceanography / UCSD / +01 760 840 8660 mobile / stonesteps (Skype) / stonesteps7 (iChat) / http://www.sdsc.edu/~hellyj From tmacchant at yahoo.co.jp Fri Sep 25 22:41:08 2009 From: tmacchant at yahoo.co.jp (Tatsuro MATSUOKA) Date: Sat, 26 Sep 2009 12:41:08 +0900 (JST) Subject: Problem with octave/gnuplot/aquaterm on Snow Leopard In-Reply-To: Message-ID: <20090926034108.50091.qmail@web3813.mail.bbt.yahoo.co.jp> Hello My suggestion may not be useful because I'm not a mac user. Please execute gnuplot itself. And type gnuplot> set terminal aqua enhanced title "Figure 1" size 560 420 from the gnuplot prompt. Does the above works well? If it does not work, your installing gnuplot was not be successful. If it works, please wait until mac users' reply. Regards Tatsuro --- Helly John> wrote: > Hi. > > I'm new to Octave and gnuplot and Aquaterm but have just installed all > of these on my system. Here's the configuration: > > - Mac OS X 10.6.1 > - AquaTerm v1.0.1 (1.0.1) > - Octave-3.2.2 > - GNUPLOT 4.2 patchlevel 6 > > When I try to plot in octave this is what happens: > ***************************************************************** > octave-3.2.2:1> Y=[1:10] > Y = > > 1 2 3 4 5 6 7 8 9 10 > > octave-3.2.2:2> plot(Y) > Unknown or ambiguous terminal name 'aqua' > > gnuplot> set terminal aqua enhanced title "Figure 1" size 560 420 > ^ > line 0: unknown or ambiguous terminal type; type just 'set > terminal' for a list > > line 0: No terminal defined > > > gnuplot> plot "-" binary format='%float64' record=10 using ($1):($2) > axes x1y1 title "" with lines linestyle 1 ; > ^ > line 0: use 'set term' to set terminal type first > > octave-3.2.2:3> system ("echo $GNUTERM") > aqua > ans = 0 > octave-3.2.2:4> > ***************************************************************** > > Do you have any suggestions as to what might be wrong? > Thanks. > ----------------------------------------------- > John Helly / San Diego Supercomputer Center & Climate, Atmospheric > Science, and Physical Oceanography/Scripps Institution of > Oceanography / UCSD / +01 760 840 8660 mobile / stonesteps (Skype) / > stonesteps7 (iChat) / http://www.sdsc.edu/~hellyj > > > > > ----------------------------------------------- > John Helly / San Diego Supercomputer Center & Climate, Atmospheric > Science, and Physical Oceanography/Scripps Institution of > Oceanography / UCSD / +01 760 840 8660 mobile / stonesteps (Skype) / > stonesteps7 (iChat) / http://www.sdsc.edu/~hellyj > > > > _______________________________________________ > Help-octave mailing list > Help-octave at octave.org > https://www-old.cae.wisc.edu/mailman/listinfo/help-octave > -------------------------------------- Thanks 10 years! Yahoo! Shopping and Yahoo! Auctions http://pr.mail.yahoo.co.jp/ec10years/ From Thomas.Treichl at gmx.net Sun Sep 27 05:49:27 2009 From: Thomas.Treichl at gmx.net (Thomas Treichl) Date: Sun, 27 Sep 2009 12:49:27 +0200 Subject: Problem with octave/gnuplot/aquaterm on Snow Leopard In-Reply-To: References: Message-ID: <4ABF4337.8030405@gmx.net> Helly John schrieb: > Hi. > > I'm new to Octave and gnuplot and Aquaterm but have just installed all > of these on my system. Here's the configuration: > > - Mac OS X 10.6.1 > - AquaTerm v1.0.1 (1.0.1) > - Octave-3.2.2 > - GNUPLOT 4.2 patchlevel 6 > > When I try to plot in octave this is what happens: > ***************************************************************** > octave-3.2.2:1> Y=[1:10] > Y = > > 1 2 3 4 5 6 7 8 9 10 > > octave-3.2.2:2> plot(Y) > Unknown or ambiguous terminal name 'aqua' > > gnuplot> set terminal aqua enhanced title "Figure 1" size 560 420 > ^ > line 0: unknown or ambiguous terminal type; type just 'set > terminal' for a list > > line 0: No terminal defined > > > gnuplot> plot "-" binary format='%float64' record=10 using ($1):($2) > axes x1y1 title "" with lines linestyle 1 ; > ^ > line 0: use 'set term' to set terminal type first > > octave-3.2.2:3> system ("echo $GNUTERM") > aqua > ans = 0 > octave-3.2.2:4> > ***************************************************************** > > Do you have any suggestions as to what might be wrong? > Thanks. Hi, it looks like that your Gnuplot 4.2.6 has not been compiled against libaquaterm.dylib. It's not just that you need to install AquaTerm on your Mac, the one who compiles the sources that you have got needs to compile against libaquaterm.dylib. At least I hope that this is your problem. You can check this if you type "set terminal" after starting Gnuplot and then check the second line for the "aqua" terminal. On my system with Gnuplot 4.2.5 this looks like gnuplot> set terminal Available terminal types: aqua Interface to graphics terminal server for Mac OS X cgm Computer Graphics Metafile corel EPS format for CorelDRAW If the aqua terminal is not listed then you might have no chance to plot in an AquaTerm without recompilation of the Gnuplot sources. Best regards Thomas From jwe at octave.org Sun Sep 27 11:10:30 2009 From: jwe at octave.org (John W. Eaton) Date: Sun, 27 Sep 2009 12:10:30 -0400 Subject: Octave Version 3.2.3 Released Message-ID: <19135.36470.884426.946310@segfault.lan> GNU Octave version 3.2.3 is now available from ftp.gnu.org/gnu/octave and ftp.octave.org/pub/octave. The MD5 check sums are eecaa1a3b2da3b94fa7bcebbc4f1a1f2 octave-3.2.3.tar.bz2 a3805ed3838c76f4973d1ef7615d5f3c octave-3.2.3.tar.gz 4297b33b7d5bded56c0b522729e2bb19 octave-3.2.2-3.2.3.patch.bz2 53253104aa8201a8c64be712a5208948 octave-3.2.2-3.2.3.patch.gz For a summary of important user-visible changes for version 3.2, see the NEWS file (ftp://ftp.octave.org/pub/octave/NEWS-3.2), or type "news" at the Octave prompt. Report bugs to (but first, please read http://www.octave.org/bugs.html to learn how to write a helpful report). If you find Octave useful, please support its development by contributing to the project. See http://www.octave.org/help-wanted.html for more information about how you can help. From hellyj at ucsd.edu Sun Sep 27 14:49:17 2009 From: hellyj at ucsd.edu (Helly John) Date: Sun, 27 Sep 2009 12:49:17 -0700 Subject: Problem with octave/gnuplot/aquaterm on Snow Leopard In-Reply-To: <4ABF4337.8030405@gmx.net> References: <4ABF4337.8030405@gmx.net> Message-ID: <864AA63F-44E0-48D1-90D6-15A90DFD1D29@ucsd.edu> Thanks. Acutally, it's related but also different. It wasn't resolving against the library as you pointed out but for a obscure reason. I found a discussion of the problem here: http://macresearch.org/gnuplot-aquaterm-snow-leopard-1061 On Sep 27, 2009, at 3:49 AM, Thomas Treichl wrote: Helly John schrieb: > Hi. > > I'm new to Octave and gnuplot and Aquaterm but have just installed all > of these on my system. Here's the configuration: > > - Mac OS X 10.6.1 > - AquaTerm v1.0.1 (1.0.1) > - Octave-3.2.2 > - GNUPLOT 4.2 patchlevel 6 > > When I try to plot in octave this is what happens: > ***************************************************************** > octave-3.2.2:1> Y=[1:10] > Y = > > 1 2 3 4 5 6 7 8 9 10 > > octave-3.2.2:2> plot(Y) > Unknown or ambiguous terminal name 'aqua' > > gnuplot> set terminal aqua enhanced title "Figure 1" size 560 420 > ^ > line 0: unknown or ambiguous terminal type; type just 'set > terminal' for a list > > line 0: No terminal defined > > > gnuplot> plot "-" binary format='%float64' record=10 using ($1):($2) > axes x1y1 title "" with lines linestyle 1 ; > ^ > line 0: use 'set term' to set terminal type first > > octave-3.2.2:3> system ("echo $GNUTERM") > aqua > ans = 0 > octave-3.2.2:4> > ***************************************************************** > > Do you have any suggestions as to what might be wrong? > Thanks. Hi, it looks like that your Gnuplot 4.2.6 has not been compiled against libaquaterm.dylib. It's not just that you need to install AquaTerm on your Mac, the one who compiles the sources that you have got needs to compile against libaquaterm.dylib. At least I hope that this is your problem. You can check this if you type "set terminal" after starting Gnuplot and then check the second line for the "aqua" terminal. On my system with Gnuplot 4.2.5 this looks like gnuplot> set terminal Available terminal types: aqua Interface to graphics terminal server for Mac OS X cgm Computer Graphics Metafile corel EPS format for CorelDRAW If the aqua terminal is not listed then you might have no chance to plot in an AquaTerm without recompilation of the Gnuplot sources. Best regards Thomas ----------------------------------------------- John Helly / San Diego Supercomputer Center & Climate, Atmospheric Science, and Physical Oceanography/Scripps Institution of Oceanography / UCSD / +01 760 840 8660 mobile / stonesteps (Skype) / stonesteps7 (iChat) / http://www.sdsc.edu/~hellyj From nasreddinhodja1208 at gmail.com Tue Sep 29 01:04:18 2009 From: nasreddinhodja1208 at gmail.com (Nasreddin Hodja) Date: Mon, 28 Sep 2009 23:04:18 -0700 Subject: Fwd: can not get octave to plot - posting again In-Reply-To: References: Message-ID: Thomas, Below are the error messages I get when I type in the commands you suggested. I had not seen your response before, I wish I had... I have been trying to plot my graphs outside of octave in the past month but it started getting tedious. I hope to figure this plotting problem out soon. Thank you for offering help, --tolga octave-3.2.2:96> ostream = __gnuplot_open_stream__ (2, gcf ()) ostream = 11 12 error: __gnuplot_get_var__: Can not make fifo (No such file or directory) error: called from: error: /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/__gnuplot_get_var__.m at line 69, column 7 error: /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/__go_draw_axes__.m at line 39, column 18 error: /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/__go_draw_figure__.m at line 93, column 3 error: /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/gnuplot_drawnow.m at line 88, column 5 octave-3.2.2:97> octave-3.2.2:97> gpin_name = tmpnam () gpin_name = /local/tmp/oct-0C8olE octave-3.2.2:98> octave-3.2.2:98> [err, msg] = mkfifo (gpin_name, 6*8*8) err = -1 msg = No such file or directory --------------------- Hi, I put some Octave commands here - can you please copy and paste them into a running Octave session and then please send back all the output of these commands: ostream = __gnuplot_open_stream__ (2, gcf ()) gpin_name = tmpnam () [err, msg] = mkfifo (gpin_name, 6*8*8) Best regards, Thomas On Sun, Aug 23, 2009 at 8:46 PM, Nasreddin Hodja < nasreddinhodja1208 at gmail.com> wrote: > > Thank you for your responses. Ben's suggestion actually makes an empty plot > box pop - I did not have that before... But the plot window is blank and the > error I get is still the same. > > *octave-3.2.2:1> setenv ("GNUTERM", "x11") > octave-3.2.2:2> plot(1:10) > > error: __gnuplot_get_var__: Can not make fifo (No such file or directory) > error: called from: > error: > /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/__gnuplot_get_var__.m > at line 69, column 7 > error: > /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/__go_draw_axes__.m > at line 39, column 18 > error: > /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/__go_draw_figure__.m > at line 93, column 3 > error: > /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/gnuplot_drawnow.m > at line 88, column 5 > * > > > I tried Leo's suggestion as well...Created a .octaverc and pasted the line: > *gnuplot_binary("/Applications/Gnuplot.app/Contents/Resources/bin/gnuplot") > > *in it. The behavior is the same. So I assume location of gnuplot is known > by octave, but not really sure... When I do not type * setenv ("GNUTERM", > "x11") *I do get a pop up blank plot window but when I do, again the error > is: > > *octave-3.2.2:1> setenv ("GNUTERM", "x11") > octave-3.2.2:2> plot(1:10) > error: __gnuplot_get_var__: Can not make fifo (No such file or directory) > error: called from: > error: > /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/__gnuplot_get_var__.m > at line 69, column 7 > error: > /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/__go_draw_axes__.m > at line 39, column 18 > error: > /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/__go_draw_figure__.m > at line 93, column 3 > error: > /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/gnuplot_drawnow.m > at line 88, column 5 > * > just to check at the end:* > octave-3.2.2:3> gnuplot_binary > ans = /Applications/Gnuplot.app/Contents/Resources/bin/gnuplot > * > > Any other thoughts? > > Thanks, > --tolga > > > > > > > > On Sun, Aug 23, 2009 at 7:13 PM, Leo Butler wrote: > >> >> >> On Sun, 23 Aug 2009, Nasreddin Hodja wrote: >> >> < I hope this one goes through... >> < >> < Thanks in advance, >> < --tolga >> < >> < >> < ---------- Forwarded message ---------- >> < From: Nasreddin Hodja >> < Date: Sat, Aug 22, 2009 at 10:16 PM >> < Subject: can not get octave to plot >> < To: help-octave at octave.org >> < >> < >> < Hello all, >> < >> < My OS: Mac OSX 10.5.6 >> < My Octave version: 3.2.2 >> < My GnuPlot version: 4.2.5 >> < >> < I installed both GnuPlot and Octave. Also installed control toolbox for >> < octave, which works fine... >> < >> < But *when I try to use the ?plot? function in Octave I get the following >> < error pasted below:** >> < * >> < FYI: I run X11 beforehand and I already set the DISPLAY to 0.0 in my >> .zshrc. >> < The gnuterm is set to aqua (no idea what that is but it should be ok, as >> I >> < followed many threads on this - though i don't think it changes anything >> < when I set it to x11) >> < >> < ERROR is: >> < >> < octave-3.2.2:1> plot(1:10) >> < error: __gnuplot_get_var__: Can not make fifo (No such file or >> directory) >> >> I think this error indicates octave cannot find gnuplot. You can tell >> octave the location of gnuplot by putting >> >> gnuplot_binary("path to gnuplot"); >> >> in your .octaverc file in your home directory. >> >> Leo >> >> -- >> The University of Edinburgh is a charitable body, registered in >> Scotland, with registration number SC005336. >> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090928/420a1cd6/attachment.html From snowboardshome at gmx.de Tue Sep 29 04:33:29 2009 From: snowboardshome at gmx.de (s4y) Date: Tue, 29 Sep 2009 02:33:29 -0700 (PDT) Subject: Importing data problems Message-ID: <25659793.post@talk.nabble.com> Hello, i can't load my file into octave. It lokks like this: time temperature1 temperature2 16:15:07 15,3 32,4 16:15:17 15,6 45,4 16:15:27 17,5 56,6 First of all there is a problem with the commata. Is it possible to load it without changing the original file. Further the time value including " : " creates an error. And i dont know how to erase the text line in the imported file. Thanks in advance. Sebastian -- View this message in context: http://www.nabble.com/Importing-data-problems-tp25659793p25659793.html Sent from the Octave - General mailing list archive at Nabble.com. From jwe at octave.org Tue Sep 29 11:22:11 2009 From: jwe at octave.org (John W. Eaton) Date: Tue, 29 Sep 2009 12:22:11 -0400 Subject: Importing data problems In-Reply-To: <25659793.post@talk.nabble.com> References: <25659793.post@talk.nabble.com> Message-ID: <19138.13363.393013.244615@segfault.lan> On 29-Sep-2009, s4y wrote: | Hello, i can't load my file into octave. | It lokks like this: | | time temperature1 temperature2 | 16:15:07 15,3 32,4 | 16:15:17 15,6 45,4 | 16:15:27 17,5 56,6 | | First of all there is a problem with the commata. Is it possible to load it | without changing the original file. Further the time value including " : " | creates an error. And i dont know how to erase the text line in the imported | file. Read it with fopen and some combination of fscanf or fgetl+conversion to whatever data types you need. Or, take a look at the textread function from the Octave Forge io package. jwe From ar63 at evansville.edu Tue Sep 29 11:19:44 2009 From: ar63 at evansville.edu (Richardson, Anthony) Date: Tue, 29 Sep 2009 11:19:44 -0500 Subject: Importing data problems In-Reply-To: <25659793.post@talk.nabble.com> References: <25659793.post@talk.nabble.com> Message-ID: <2318D9796D5B9D41B85612B5C87F2240025034E0@UEEXCHANGE.evansville.edu> Here's my attempt: fid = fopen("temp.dat","r"); %Read header h = fgetl(fid); index = 1; t1 = []; t2 = []; time = [" "]; while(1) [t n1 n2 n3 n4 count] = fscanf(fid,"%s %d,%d %d,%d" ,"C"); time(index,:) = t; t1(index) = [n1+n2/10]; t2(index) = [n3+n4/10]; index++; if (feof(fid)) break; endif endwhile fclose(fid); > -----Original Message----- > From: s4y [mailto:snowboardshome at gmx.de] > Sent: Tuesday, September 29, 2009 4:33 AM > To: help-octave at octave.org > Subject: Importing data problems > > > Hello, i can't load my file into octave. > It lokks like this: > > time temperature1 temperature2 > 16:15:07 15,3 32,4 > 16:15:17 15,6 45,4 > 16:15:27 17,5 56,6 > > First of all there is a problem with the commata. Is it possible to > load it > without changing the original file. Further the time value including " > : " > creates an error. And i dont know how to erase the text line in the > imported > file. > Thanks in advance. > Sebastian > > -- > View this message in context: http://www.nabble.com/Importing-data- > problems-tp25659793p25659793.html > Sent from the Octave - General mailing list archive at Nabble.com. > > _______________________________________________ > Help-octave mailing list > Help-octave at octave.org > https://www-old.cae.wisc.edu/mailman/listinfo/help-octave From dcottingham00 at comcast.net Tue Sep 29 12:28:05 2009 From: dcottingham00 at comcast.net (dcottingham00 at comcast.net) Date: Tue, 29 Sep 2009 17:28:05 +0000 (UTC) Subject: another "gset term" replacement question Message-ID: <899453044.176741254245285627.JavaMail.root@sz0019a.westchester.pa.mail.comcast.net> I often have a need to run octave scripts in the background, sometimes scripts that make plots. With octave 2.x, I would preceed any such plotting with "gset term postscript". Now that gset is gone, I do the plotting and the use "print -dpsc" to put it into a postscript file. But if I try to run such a script in background, it hangs when it gets to the plotting. How can I direct the script to make the plot postscript in the first place? Or is there any other way to stop it from hanging? Is there any way to control where octave's invocation of gnuplot tries to put the plot? Thanks, Dave Cottingham -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090929/2540560b/attachment.html From lindnerben at gmx.net Tue Sep 29 13:31:43 2009 From: lindnerben at gmx.net (Benjamin Lindner) Date: Tue, 29 Sep 2009 20:31:43 +0200 Subject: startup with .octaverc on Windows Vista In-Reply-To: <20090924061926.GA16446@simba> References: <20090921172000.GA8578@simba> <2318D9796D5B9D41B85612B5C87F224002350E5A@UEEXCHANGE.evansville.edu> <20090924061926.GA16446@simba> Message-ID: <4AC2528F.3000604@gmx.net> Bart Vandewoestyne wrote: > On Mon, Sep 21, 2009 at 01:43:26PM -0500, Richardson, Anthony wrote: >> We have a similar setup. We set HOME in the >> C:/octave/3.22.2_gcc-4.3.0/share/octave/site/m/startup/octaverc >> file, with the following lines: >> >> setenv('HOME','h:\'); >> cd ~; >> >> This allows the octave HOME env variable to be set differently >> than a Vista global HOME environment variable. An .octaverc >> file in h:\ is still executed. Setting HOME from Windows >> should work too, but we have other software that uses the HOME >> environment variable and requires that it be set to something >> else. >> >> Tony Richardson > > Thanks for your reply, Tony. In our computer-rooms, we are doing > it now the way you describe, and everything works nicely. The > Octave desktop-icon is now shining on all our student-computers > :-) > > I do have another question related to the installer though... > > For our sysadmins, it would be comfortable if they can do a > silent (unattended) install. For as far as I can see, Octave > uses the NSIS installer system (http://nsis.sourceforge.net) and > it has an option /S with which one can do a silent install (see > for example http://unattended.sourceforge.net/installers.php) > > However, if one performs a silent install, then apparently the > installation is done with the *default* options, that is, no > Octave-Forge packages are installed and one cannot select another > Atlas library. > > Is it somehow possible to do a silent (unattended) install *with* > specifying that Octave-Forge should also be installed? Does the > NSIS installer system allow a user to specify certain > installation options somehow? This is indeed a good question. I did consult the NSIS manual, and it seems that there is no supoprt for an answer file for unattended installs, which means it would need to be programmed by hand. I am not an expert on nsis, and frankly I am not overly eager to start coding this by hand. One possibility that you can try is to install octave once in the configuration desired, and then simply copy the entire directory tree as-is to a different computer. Octave itself is relocatable, and it is portable, so there is no need to install it to get a running version. What's not fully relocatable at the moment is the octave-forge packages (the package manager keeps track of absolute installation paths). So in order to get a copied directory tree working you need to start octave and execute "pkg rebuild". You can omit this step if you copy octave into the same path on a remote computer (since then no paths actually have changed, it's just a different machine). What you cannot do this way however is to get different ATLAS architectures. benjamin From Thomas.Treichl at gmx.net Tue Sep 29 13:40:47 2009 From: Thomas.Treichl at gmx.net (Thomas Treichl) Date: Tue, 29 Sep 2009 20:40:47 +0200 Subject: Fwd: can not get octave to plot - posting again In-Reply-To: References: Message-ID: <4AC254AF.2070604@gmx.net> Nasreddin Hodja schrieb: > > Thomas, > > Below are the error messages I get when I type in the commands you > suggested. > > I had not seen your response before, I wish I had... I have been trying > to plot my graphs outside of octave in the past month but it started > getting tedious. I hope to figure this plotting problem out soon. > > Thank you for offering help, > --tolga > > > octave-3.2.2:96> ostream = __gnuplot_open_stream__ (2, gcf ()) > ostream = > > 11 12 > > error: __gnuplot_get_var__: Can not make fifo (No such file or directory) > error: called from: > error: > /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/__gnuplot_get_var__.m > at line 69, column 7 > error: > /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/__go_draw_axes__.m > at line 39, column 18 > error: > /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/__go_draw_figure__.m > at line 93, column 3 > error: > /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/gnuplot_drawnow.m > at line 88, column 5 > octave-3.2.2:97> > octave-3.2.2:97> gpin_name = tmpnam () > gpin_name = /local/tmp/oct-0C8olE > octave-3.2.2:98> > octave-3.2.2:98> [err, msg] = mkfifo (gpin_name, 6*8*8) > err = -1 > msg = No such file or directory > > > > --------------------- > Hi, > > I put some Octave commands here - can you please copy and paste them > into a running Octave session and then please send back all the output > of these commands: > > ostream = __gnuplot_open_stream__ (2, gcf ()) > > gpin_name = tmpnam () > > [err, msg] = mkfifo (gpin_name, 6*8*8) > > Best regards, > > Thomas > > > > On Sun, Aug 23, 2009 at 8:46 PM, Nasreddin Hodja > > wrote: > > > Thank you for your responses. Ben's suggestion actually makes an > empty plot box pop - I did not have that before... But the plot > window is blank and the error I get is still the same. > > */octave-3.2.2:1> setenv ("GNUTERM", "x11") > octave-3.2.2:2> plot(1:10) > > > error: __gnuplot_get_var__: Can not make fifo (No such file or > directory) > error: called from: > error: > /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/__gnuplot_get_var__.m > at line 69, column 7 > error: > /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/__go_draw_axes__.m > at line 39, column 18 > error: > /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/__go_draw_figure__.m > at line 93, column 3 > error: > /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/gnuplot_drawnow.m > at line 88, column 5 > /* > > > I tried Leo's suggestion as well...Created a .octaverc and pasted > the line: > */gnuplot_binary("/Applications/Gnuplot.app/Contents/Resources/bin/gnuplot") > > /*in it. The behavior is the same. So I assume location of gnuplot > is known by octave, but not really sure... When I do not type */ > setenv ("GNUTERM", "x11") /*I do get a pop up blank plot window but > when I do, again the error is: > > /*octave-3.2.2:1> setenv ("GNUTERM", "x11") > octave-3.2.2:2> plot(1:10) > > error: __gnuplot_get_var__: Can not make fifo (No such file or > directory) > error: called from: > error: > /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/__gnuplot_get_var__.m > at line 69, column 7 > error: > /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/__go_draw_axes__.m > at line 39, column 18 > error: > /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/__go_draw_figure__.m > at line 93, column 3 > error: > /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/gnuplot_drawnow.m > at line 88, column 5 > */ > just to check at the end:/* > octave-3.2.2:3> gnuplot_binary > ans = /Applications/Gnuplot.app/Contents/Resources/bin/gnuplot > */ > > Any other thoughts? > > Thanks, > --tolga > > > > > > > > On Sun, Aug 23, 2009 at 7:13 PM, Leo Butler > wrote: > > > > On Sun, 23 Aug 2009, Nasreddin Hodja wrote: > > < I hope this one goes through... > < > < Thanks in advance, > < --tolga > < > < > < ---------- Forwarded message ---------- > < From: Nasreddin Hodja > > < Date: Sat, Aug 22, 2009 at 10:16 PM > < Subject: can not get octave to plot > < To: help-octave at octave.org > < > < > < Hello all, > < > < My OS: Mac OSX 10.5.6 > < My Octave version: 3.2.2 > < My GnuPlot version: 4.2.5 > < > < I installed both GnuPlot and Octave. Also installed control > toolbox for > < octave, which works fine... > < > < But *when I try to use the ?plot? function in Octave I get the > following > < error pasted below:** > < * > < FYI: I run X11 beforehand and I already set the DISPLAY to 0.0 > in my .zshrc. > < The gnuterm is set to aqua (no idea what that is but it should > be ok, as I > < followed many threads on this - though i don't think it > changes anything > < when I set it to x11) > < > < ERROR is: > < > < octave-3.2.2:1> plot(1:10) > < error: __gnuplot_get_var__: Can not make fifo (No such file or > directory) > > I think this error indicates octave cannot find gnuplot. You can > tell > octave the location of gnuplot by putting > > gnuplot_binary("path to gnuplot"); > > in your .octaverc file in your home directory. > > Leo > > -- > The University of Edinburgh is a charitable body, registered in > Scotland, with registration number SC005336. Sorry, I must have overlooked your answer. Ok, let's see what we can do now. The problem you have has nothing to do with where the binary of gnuplot is located. Your problem is that you cannot create a fifo special file on your Mac. I think the problem is somewhere with your tmpnam() function because it returns a result to /local/tmp. On my system a call to tmpnam() within Octave gives the result octave-3.2.0:1> tmpnam () ans = /var/tmp/oct-KmvZyU First question now is, is there a path on your system which is called /local/tmp? Open a Terminal.app and check this ls -l /local/tmp I expect this path does not exist on your Mac or it has been created manually?! The next question is, is there a global /tmp directory on your Mac, check ls -l /tmp and also please type this line in your Terminal.app echo $TMPDIR I also expect that your Octave mkfifo() command works correctly, can you please check in Octave.app [verr, vmsg] = mkfifo ("test.txt", 666) delete ("test.txt") Meanwhile best regards Thomas From benjamin.abbott at tqs.com Tue Sep 29 14:58:52 2009 From: benjamin.abbott at tqs.com (Ben Abbott) Date: Tue, 29 Sep 2009 15:58:52 -0400 Subject: another "gset term" replacement question In-Reply-To: <109821932292442390389609557899284330578-Webmail@me.com> References: <899453044.176741254245285627.JavaMail.root@sz0019a.westchester.pa.mail.comcast.net> <109821932292442390389609557899284330578-Webmail@me.com> Message-ID: <1408EA1E-C2B6-4CC6-B87C-B5A73CC2E71C@tqs.com> > On Tuesday, September 29, 2009, at 01:28PM, > wrote: > > I often have a need to run octave scripts in the background, > sometimes scripts that make plots. With octave 2.x, I would preceed > any such plotting with "gset term postscript". > > Now that gset is gone, I do the plotting and the use "print -dpsc" > to put it into a postscript file. But if I try to run such a script > in background, it hangs when it gets to the plotting. > > How can I direct the script to make the plot postscript in the first > place? Or is there any other way to stop it from hanging? Is there > any way to control where octave's invocation of gnuplot tries to put > the plot? > > Thanks, > Dave Cottingham To produce a postscript output ... print -dpsc file.ps To suspend generation of figures on screen, you can try ... close all set (0, "defaultfigurevisible", "off") To continue with plots to the screen ... close all set (0, "defaultfigurevisible", "on") Ben From dcottingham00 at comcast.net Tue Sep 29 20:39:59 2009 From: dcottingham00 at comcast.net (dcottingham00 at comcast.net) Date: Wed, 30 Sep 2009 01:39:59 +0000 (UTC) Subject: another "gset term" replacement question In-Reply-To: <1408EA1E-C2B6-4CC6-B87C-B5A73CC2E71C@tqs.com> Message-ID: <731821141.377071254274799478.JavaMail.root@sz0019a.westchester.pa.mail.comcast.net> Thanks. Your suggestion does indeed stop the plot from appearing on the screen -- but when run in the background, the process still stops. BTW, I shouldn't have said it hangs if run in the background -- it goes into the "stopped" state. And further experiments have revealed that a script that does plotting, but does not do "print", does not go into "stopped". Even if I omit the part that sets visible off. It only stops if I include a "print." Maybe I should write a bug report -- I can't think of any good reason why "print" should have to run in the foreground. - Dave Cottingham ----- Original Message ----- From: "Ben Abbott" To: dcottingham00 at comcast.net Cc: help-octave at octave.org Sent: Tuesday, September 29, 2009 3:58:52 PM GMT -05:00 US/Canada Eastern Subject: Re: another "gset term" replacement question > On Tuesday, September 29, 2009, at 01:28PM, > wrote: > > I often have a need to run octave scripts in the background, > sometimes scripts that make plots. With octave 2.x, I would preceed > any such plotting with "gset term postscript". > > Now that gset is gone, I do the plotting and the use "print -dpsc" > to put it into a postscript file. But if I try to run such a script > in background, it hangs when it gets to the plotting. > > How can I direct the script to make the plot postscript in the first > place? Or is there any other way to stop it from hanging? Is there > any way to control where octave's invocation of gnuplot tries to put > the plot? > > Thanks, > Dave Cottingham To produce a postscript output ... print -dpsc file.ps To suspend generation of figures on screen, you can try ... close all set (0, "defaultfigurevisible", "off") To continue with plots to the screen ... close all set (0, "defaultfigurevisible", "on") Ben -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090930/25448040/attachment.html From nasreddinhodja1208 at gmail.com Wed Sep 30 01:43:00 2009 From: nasreddinhodja1208 at gmail.com (Nasreddin Hodja) Date: Tue, 29 Sep 2009 23:43:00 -0700 Subject: Fwd: can not get octave to plot - posting again In-Reply-To: <4AC254AF.2070604@gmx.net> References: <4AC254AF.2070604@gmx.net> Message-ID: On Tue, Sep 29, 2009 at 11:40 AM, Thomas Treichl wrote: > Nasreddin Hodja schrieb: > >> >> Thomas, >> >> Below are the error messages I get when I type in the commands you >> suggested. >> >> I had not seen your response before, I wish I had... I have been trying to >> plot my graphs outside of octave in the past month but it started getting >> tedious. I hope to figure this plotting problem out soon. >> >> Thank you for offering help, >> --tolga >> >> >> octave-3.2.2:96> ostream = __gnuplot_open_stream__ (2, gcf ()) >> ostream = >> >> 11 12 >> >> error: __gnuplot_get_var__: Can not make fifo (No such file or directory) >> error: called from: >> error: >> /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/__gnuplot_get_var__.m >> at line 69, column 7 >> error: >> /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/__go_draw_axes__.m >> at line 39, column 18 >> error: >> /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/__go_draw_figure__.m >> at line 93, column 3 >> error: >> /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/gnuplot_drawnow.m >> at line 88, column 5 >> octave-3.2.2:97> >> octave-3.2.2:97> gpin_name = tmpnam () >> gpin_name = /local/tmp/oct-0C8olE >> octave-3.2.2:98> >> octave-3.2.2:98> [err, msg] = mkfifo (gpin_name, 6*8*8) >> err = -1 >> msg = No such file or directory >> >> >> >> --------------------- >> Hi, >> >> I put some Octave commands here - can you please copy and paste them into >> a running Octave session and then please send back all the output of these >> commands: >> >> ostream = __gnuplot_open_stream__ (2, gcf ()) >> >> gpin_name = tmpnam () >> >> [err, msg] = mkfifo (gpin_name, 6*8*8) >> >> Best regards, >> >> Thomas >> >> >> >> On Sun, Aug 23, 2009 at 8:46 PM, Nasreddin Hodja < >> nasreddinhodja1208 at gmail.com > >> wrote: >> >> >> Thank you for your responses. Ben's suggestion actually makes an >> empty plot box pop - I did not have that before... But the plot >> window is blank and the error I get is still the same. >> >> */octave-3.2.2:1> setenv ("GNUTERM", "x11") >> octave-3.2.2:2> plot(1:10) >> >> >> error: __gnuplot_get_var__: Can not make fifo (No such file or >> directory) >> error: called from: >> error: >> /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/__gnuplot_get_var__.m >> at line 69, column 7 >> error: >> /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/__go_draw_axes__.m >> at line 39, column 18 >> error: >> /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/__go_draw_figure__.m >> at line 93, column 3 >> error: >> /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/gnuplot_drawnow.m >> at line 88, column 5 >> /* >> >> >> I tried Leo's suggestion as well...Created a .octaverc and pasted >> the line: >> >> */gnuplot_binary("/Applications/Gnuplot.app/Contents/Resources/bin/gnuplot") >> >> /*in it. The behavior is the same. So I assume location of gnuplot >> is known by octave, but not really sure... When I do not type */ >> setenv ("GNUTERM", "x11") /*I do get a pop up blank plot window but >> when I do, again the error is: >> >> /*octave-3.2.2:1> setenv ("GNUTERM", "x11") >> octave-3.2.2:2> plot(1:10) >> >> error: __gnuplot_get_var__: Can not make fifo (No such file or >> directory) >> error: called from: >> error: >> /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/__gnuplot_get_var__.m >> at line 69, column 7 >> error: >> /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/__go_draw_axes__.m >> at line 39, column 18 >> error: >> /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/__go_draw_figure__.m >> at line 93, column 3 >> error: >> /Applications/Octave.app/Contents/Resources/share/octave/3.2.2/m/plot/gnuplot_drawnow.m >> at line 88, column 5 >> */ >> just to check at the end:/* >> octave-3.2.2:3> gnuplot_binary >> ans = /Applications/Gnuplot.app/Contents/Resources/bin/gnuplot >> */ >> >> Any other thoughts? >> >> Thanks, >> --tolga >> >> >> >> >> >> >> >> On Sun, Aug 23, 2009 at 7:13 PM, Leo Butler > > wrote: >> >> >> >> On Sun, 23 Aug 2009, Nasreddin Hodja wrote: >> >> < I hope this one goes through... >> < >> < Thanks in advance, >> < --tolga >> < >> < >> < ---------- Forwarded message ---------- >> < From: Nasreddin Hodja > > >> < Date: Sat, Aug 22, 2009 at 10:16 PM >> < Subject: can not get octave to plot >> < To: help-octave at octave.org >> < >> < >> < Hello all, >> < >> < My OS: Mac OSX 10.5.6 >> < My Octave version: 3.2.2 >> < My GnuPlot version: 4.2.5 >> < >> < I installed both GnuPlot and Octave. Also installed control >> toolbox for >> < octave, which works fine... >> < >> < But *when I try to use the ?plot? function in Octave I get the >> following >> < error pasted below:** >> < * >> < FYI: I run X11 beforehand and I already set the DISPLAY to 0.0 >> in my .zshrc. >> < The gnuterm is set to aqua (no idea what that is but it should >> be ok, as I >> < followed many threads on this - though i don't think it >> changes anything >> < when I set it to x11) >> < >> < ERROR is: >> < >> < octave-3.2.2:1> plot(1:10) >> < error: __gnuplot_get_var__: Can not make fifo (No such file or >> directory) >> >> I think this error indicates octave cannot find gnuplot. You can >> tell >> octave the location of gnuplot by putting >> >> gnuplot_binary("path to gnuplot"); >> >> in your .octaverc file in your home directory. >> >> Leo >> >> -- >> The University of Edinburgh is a charitable body, registered in >> Scotland, with registration number SC005336. >> > > Sorry, I must have overlooked your answer. Ok, let's see what we can do > now. The problem you have has nothing to do with where the binary of gnuplot > is located. Your problem is that you cannot create a fifo special file on > your Mac. > > I think the problem is somewhere with your tmpnam() function because it > returns a result to /local/tmp. On my system a call to tmpnam() within > Octave gives the result > > octave-3.2.0:1> tmpnam () > ans = /var/tmp/oct-KmvZyU > > First question now is, is there a path on your system which is called > /local/tmp? Open a Terminal.app and check this > > ls -l /local/tmp > > I expect this path does not exist on your Mac or it has been created > manually?! The next question is, is there a global /tmp directory on your > Mac, check > > ls -l /tmp > > and also please type this line in your Terminal.app > > echo $TMPDIR > > I also expect that your Octave mkfifo() command works correctly, can you > please check in Octave.app > > [verr, vmsg] = mkfifo ("test.txt", 666) > delete ("test.txt") > > Meanwhile best regards > > Thomas > Thomas, The results are interesting. Do I need to reset TMPDIR variable to something else. It seems to point to something non-existent...or just create a /local/tmp? *ls -l /local/tmp ls: /local/tmp: No such file or directory ls -l /tmp lrwxr-xr-x@ 1 root admin 12 Jun 4 10:15 /tmp@ -> /private/tmp echo $TMPDIR * */local/tmp octave-3.2.2:368> tmpnam () ans = /local/tmp/oct-a1D8LQ octave-3.2.2:366> [verr, vmsg] = mkfifo ("test.txt", 666) verr = 0 vmsg = octave-3.2.2:367> delete ("test.txt") * Thanks and best regards... --tolga -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090929/d8d7eb74/attachment-0001.html From eric.salemi at septentrio.com Wed Sep 30 04:49:51 2009 From: eric.salemi at septentrio.com (Eric Salemi) Date: Wed, 30 Sep 2009 11:49:51 +0200 Subject: Error on a simple struct assignment Message-ID: <4AC329BF.9070204@septentrio.com> Hi, I'm working with Octave 3.2.2 on a windows XP machine. I type the following 3 commands and get a error after the 3rd (you'll notice the 2nd and 3rd commands are exactly the same): > s = struct; > s(1,1,1).field1 = 0 s = { field1 = 0 } > s(1,1,1).field1 = 0 error: invalid assignment to cs-list outside multiple assignment. error: assignment failed, or no method for `struct = scalar' Maybe there is something I don't understand, but I don't see why Octave consider s(1,1,1).field1 as a cs-list in the 3rd command. As a side note, doing the same with (2,2,2) as index works flawlessly. Can I consider this issue a bug? Is there a workaround? Eric. Septentrio has moved offices. As of Monday 31 August 2009, Septentrio headquarters are located at: Greenhill Campus Interleuvenlaan 15G 3001 Leuven Belgium. Phone and fax numbers remain unchanged This e-mail communication contains information that is confidential and may also be privileged. It is intended for the exclusive use of the addressees. If you are not the person or organization to whom it is addressed, you must not copy, distribute or take any action in reliance upon it. If you received this communication in error, please notify Septentrio nv immediately [ telephone +32 [0] 16 300800 ]. Septentrio nv will not accept liability for contractual commitments made by individuals employed by this company outside the scope of our business. From snowboardshome at gmx.de Wed Sep 30 04:32:12 2009 From: snowboardshome at gmx.de (s4y) Date: Wed, 30 Sep 2009 02:32:12 -0700 (PDT) Subject: Importing data problems In-Reply-To: <2318D9796D5B9D41B85612B5C87F2240025034E0@UEEXCHANGE.evansville.edu> References: <25659793.post@talk.nabble.com> <2318D9796D5B9D41B85612B5C87F2240025034E0@UEEXCHANGE.evansville.edu> Message-ID: <25677802.post@talk.nabble.com> Hey, thanks for your attempt. It helped alot. I got my programme almost workin so far. But i have one problem. My programme: [fid] = fopen("test2.txt", "r", "native"); kopfzeile = fgetl(fid); [m, count] = fscanf(fid, "%f:%f:%f %f %f %f %f %f %f",[2,9]); fclose(fid); m the file test2.txt: Text 16:09:06 32.41 32.63 36.43 36.63 36.65 34.56 16:09:13 32.39 35.63 46.43 66.83 26.65 34.56 Unfortunately he saves the matrix m this way: 16 06 32.63 36.63 34.56 09 32.39 09 32.41 36.43 36.65 16 13 35.63 he starts to write it in the first column and then he is moving on to next column but i need it this way: 16 09 06 32.41 32.63 36.43 36.63 36.65 34.56 16 09 13 32.39 35.63 46.43 66.83 26.65 34.56 like in the file, line by line But i dont know how to change this. Hopefully someone knows a way. Thanks in advance. -- View this message in context: http://www.nabble.com/Importing-data-problems-tp25659793p25677802.html Sent from the Octave - General mailing list archive at Nabble.com. From Bart.Vandewoestyne at telenet.be Wed Sep 30 08:30:11 2009 From: Bart.Vandewoestyne at telenet.be (Bart Vandewoestyne) Date: Wed, 30 Sep 2009 15:30:11 +0200 Subject: Help-octave Digest, Vol 42, Issue 55 In-Reply-To: References: Message-ID: <20090930133011.GA14304@simba> On Wed, Sep 30, 2009 at 01:43:12AM -0500, help-octave-request at octave.org wrote: > > This is indeed a good question. > I did consult the NSIS manual, and it seems that there is no supoprt for > an answer file for unattended installs, which means it would need to be > programmed by hand. > I am not an expert on nsis, and frankly I am not overly eager to start > coding this by hand. I have never used NSIS in my life, but at the bottom of http://nsis.sourceforge.net/Docs/Chapter4.html#4.12 it is mentioned: "If your installer/uninstaller requires some more information that can not be gathered when silent, you can allow the user to specify that information on the command line and process it in .onInit." and completely at the bottom is written: "If your installer/uninstaller requires a lot of information and you want it to be able to be silent, you should allow the user to pass on a path to an answers file. This would be much more comfortable than writing all of the information on the command line." So i guess this means that there *are* ways to do it, no? If there are few options: -> use the .onInit. processing technique If there are a lot of options: -> let the user pass a path to an answer file But again... I don't know anything about NSIS and absolutely do not have the time to dig into this... so I'm afraid this is all I can help. Maybe other installer systems could also be considered? The free and Open Source ones that I know of, are listed on my webpage http://osswin.sourceforge.net/ (search for 'Installer systems'). I think Inno Setup is the most known, but I don't know if it is better/worse than NSIS. Regards, Bart -- "Share what you know. Learn what you don't." From martin at mhelm.de Wed Sep 30 11:13:33 2009 From: martin at mhelm.de (martin_helm) Date: Wed, 30 Sep 2009 09:13:33 -0700 (PDT) Subject: Importing data problems In-Reply-To: <25677802.post@talk.nabble.com> References: <25659793.post@talk.nabble.com> <2318D9796D5B9D41B85612B5C87F2240025034E0@UEEXCHANGE.evansville.edu> <25677802.post@talk.nabble.com> Message-ID: <25684266.post@talk.nabble.com> s4y wrote: > > Hey, thanks for your attempt. It helped alot. > I got my programme almost workin so far. But i have one problem. > My programme: > [fid] = fopen("test2.txt", "r", "native"); > kopfzeile = fgetl(fid); > [m, count] = fscanf(fid, "%f:%f:%f %f %f %f %f %f %f",[2,9]); > fclose(fid); > m > > the file test2.txt: > Text > 16:09:06 32.41 32.63 36.43 36.63 36.65 34.56 > 16:09:13 32.39 35.63 46.43 66.83 26.65 34.56 > > Unfortunately he saves the matrix m this way: > 16 06 32.63 36.63 34.56 09 32.39 > 09 32.41 36.43 36.65 16 13 35.63 > > he starts to write it in the first column and then he is moving on to next > column > but i need it this way: > 16 09 06 32.41 32.63 36.43 36.63 36.65 34.56 > 16 09 13 32.39 35.63 46.43 66.83 26.65 34.56 > like in the file, line by line > But i dont know how to change this. > Hopefully someone knows a way. > Thanks in advance. > > You can use [fid] = fopen("test2.txt", "r", "native"); kopfzeile = fgetl(fid); [m, count] = fscanf(fid, "%f:%f:%f %f %f %f %f %f %f",[9,2]); m=m'; fclose(fid); But it has still the drawback that you have to know the number of lines in advance. Instead you can do something like [fid] = fopen("test2.txt", "r", "native"); kopfzeile = fgetl(fid); [m, count] = fscanf(fid, "%f:%f:%f %f %f %f %f %f %f"); fclose(fid); m = reshape(m, 9, count/9)'; Regards Martin -- View this message in context: http://www.nabble.com/Importing-data-problems-tp25659793p25684266.html Sent from the Octave - General mailing list archive at Nabble.com. From przemek at nist.gov Wed Sep 30 13:11:01 2009 From: przemek at nist.gov (Przemek Klosowski) Date: Wed, 30 Sep 2009 14:11:01 -0400 Subject: Importing data problems In-Reply-To: <25677802.post@talk.nabble.com> References: <25659793.post@talk.nabble.com> <2318D9796D5B9D41B85612B5C87F2240025034E0@UEEXCHANGE.evansville.edu> <25677802.post@talk.nabble.com> Message-ID: <4AC39F35.8010504@nist.gov> On 09/30/2009 05:32 AM, s4y asked why the code: > [fid] = fopen("test2.txt", "r", "native"); > [m, count] = fscanf(fid, "%f:%f:%f %f %f %f %f %f %f",[2,9]); > fclose(fid); incorrectly chops up the following data file 16:09:06 32.41 32.63 36.43 36.63 36.65 34.56 16:09:13 32.39 35.63 46.43 66.83 26.65 34.56 The best way to think about it is that fscanf() reads a stream of data into a single column, which can then be reshaped. You ask for a [2,9] form, which chops 2-row-long columnar pieces and assembles them into 9 columns. If you do [m, count] = fscanf(fid, "%f:%f:%f %f %f %f %f %f %f",[9,2]); and transpose ( m' ) you will get your desired result. From mikelmckinney at gmail.com Wed Sep 30 13:42:40 2009 From: mikelmckinney at gmail.com (michael mckinney) Date: Wed, 30 Sep 2009 13:42:40 -0500 Subject: data set Message-ID: I have some data, taken in two different formats, which corresponds to a trail- I'd like to convert the xls data I have to ascII data, or something that would be suitable for an elevation and graphing format. Do you have any suggestions? thank you, Mike McKinney. From Thomas.Treichl at gmx.net Wed Sep 30 13:50:34 2009 From: Thomas.Treichl at gmx.net (Thomas Treichl) Date: Wed, 30 Sep 2009 20:50:34 +0200 Subject: Fwd: can not get octave to plot - posting again In-Reply-To: References: <4AC254AF.2070604@gmx.net> Message-ID: <4AC3A87A.5060607@gmx.net> Nasreddin Hodja schrieb: > Thomas, > > The results are interesting. Do I need to reset TMPDIR variable to > something else. It seems to point to something non-existent...or just > create a /local/tmp? > *ls -l /local/tmp > ls: /local/tmp: No such file or directory > > ls -l /tmp > lrwxr-xr-x@ 1 root admin 12 Jun 4 10:15 /tmp@ -> /private/tmp > > echo $TMPDIR > * > */local/tmp > > octave-3.2.2:368> tmpnam () > ans = /local/tmp/oct-a1D8LQ > > octave-3.2.2:366> [verr, vmsg] = mkfifo ("test.txt", 666) > verr = 0 > vmsg = > octave-3.2.2:367> delete ("test.txt") > * > Thanks and best regards... > > --tolga Hi again, don't create the /local/tmp directory because there is no need for such a directory on a Mac. The interesting part for me is, where on your Mac is TMPDIR defined? Is it a local definition somewhere in your ~/.profile or ~/.bashrc file or is it even worst defined globally? You can quickly check in Terminal.app cat ~/.profile cat ~/.bashrc If you have configured another user on your machine then you can check if TMPDIR is there globally. Maybe it's defined like this http://developer.apple.com/mac/library/qa/qa2001/qa1067.html My suggestion simply is to find the TMPDIR variable definition on your system and remove it. There really is no need to redirect the tmp directory to such a stupid path. If you cannot find the definition or you want to keep it because of a special reason then this is a workaround for your Octave to plot in an aqua window that should work setenv ("TMPDIR", "") plot (1:10) Best regards Thomas From ct529 at york.ac.uk Wed Sep 30 15:11:50 2009 From: ct529 at york.ac.uk (Corrado) Date: Wed, 30 Sep 2009 21:11:50 +0100 Subject: A point in a vector? Message-ID: <200909302111.50345.ct529@york.ac.uk> Dear list, I have a strange requirement .... I have a vector, for example v=[0,0,0,0,1,2,4,6,8,8,8,8]. I have a value,for example x=4.8. I would like to understand in which sub interval of v is x. In this case, v would be in the sub interval [4,6] that is in the subinterval starting from element j=7 to the element j+1=8. Can we do that with an octave command? Regards -- Corrado Topi Global Climate Change & Biodiversity Indicators Area 18,Department of Biology University of York, York, YO10 5YW, UK Phone: + 44 (0) 1904 328645, E-mail: ct529 at york.ac.uk From shermanj at umd.edu Wed Sep 30 15:32:45 2009 From: shermanj at umd.edu (James Sherman Jr.) Date: Wed, 30 Sep 2009 16:32:45 -0400 Subject: A point in a vector? In-Reply-To: <200909302111.50345.ct529@york.ac.uk> References: <200909302111.50345.ct529@york.ac.uk> Message-ID: <6800c3890909301332j47355e0x6c713f70415f2c0b@mail.gmail.com> Assuming, that your vector is sorted (I would guess it has to be), you could do index = find(v>x,1) then index would be the index into the vector v. So, if you wanted the min and max of the interval, you could just do j = v(index-1) j+1 = v(index) Hope this helps. On Wed, Sep 30, 2009 at 4:11 PM, Corrado wrote: > Dear list, > > I have a strange requirement .... I have a vector, for example > > v=[0,0,0,0,1,2,4,6,8,8,8,8]. I have a value,for example x=4.8. > > I would like to understand in which sub interval of v is x. > > In this case, v would be in the sub interval [4,6] that is in the > subinterval > starting from element j=7 to the element j+1=8. > > Can we do that with an octave command? > > Regards > -- > Corrado Topi > > Global Climate Change & Biodiversity Indicators > Area 18,Department of Biology > University of York, York, YO10 5YW, UK > Phone: + 44 (0) 1904 328645, E-mail: ct529 at york.ac.uk > > > _______________________________________________ > Help-octave mailing list > Help-octave at octave.org > https://www-old.cae.wisc.edu/mailman/listinfo/help-octave > -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090930/101c56af/attachment.html From storrsjm at email.uc.edu Wed Sep 30 15:34:31 2009 From: storrsjm at email.uc.edu (Judd Storrs) Date: Wed, 30 Sep 2009 16:34:31 -0400 Subject: A point in a vector? In-Reply-To: <200909302111.50345.ct529@york.ac.uk> References: <200909302111.50345.ct529@york.ac.uk> Message-ID: v=[0,0,0,0,1,2,4,6,8,8,8,8] j1 = find(v<4.5,1,'last') j2 = find(v>4.5,1,'first') [v(j1), v(j2)] Hope this helps --judd On Wed, Sep 30, 2009 at 4:11 PM, Corrado wrote: > Dear list, > > I have a strange requirement .... I have a vector, for example > > v=[0,0,0,0,1,2,4,6,8,8,8,8]. I have a value,for example x=4.8. > > I would like to understand in which sub interval of v is x. > > In this case, v would be in the sub interval [4,6] that is in the > subinterval > starting from element j=7 to the element j+1=8. > > Can we do that with an octave command? > > Regards > -- > Corrado Topi > > Global Climate Change & Biodiversity Indicators > Area 18,Department of Biology > University of York, York, YO10 5YW, UK > Phone: + 44 (0) 1904 328645, E-mail: ct529 at york.ac.uk > > > _______________________________________________ > Help-octave mailing list > Help-octave at octave.org > https://www-old.cae.wisc.edu/mailman/listinfo/help-octave > -------------- next part -------------- An HTML attachment was scrubbed... URL: https://www-old.cae.wisc.edu/pipermail/help-octave/attachments/20090930/d47eec73/attachment.html From martin at mhelm.de Wed Sep 30 16:22:59 2009 From: martin at mhelm.de (martin_helm) Date: Wed, 30 Sep 2009 14:22:59 -0700 (PDT) Subject: A point in a vector? In-Reply-To: <200909302111.50345.ct529@york.ac.uk> References: <200909302111.50345.ct529@york.ac.uk> Message-ID: <25689277.post@talk.nabble.com> Corrado wrote: > > Dear list, > > I have a strange requirement .... I have a vector, for example > > v=[0,0,0,0,1,2,4,6,8,8,8,8]. I have a value,for example x=4.8. > > I would like to understand in which sub interval of v is x. > > In this case, v would be in the sub interval [4,6] that is in the > subinterval > starting from element j=7 to the element j+1=8. > > Can we do that with an octave command? > > Regards > -- > Corrado Topi > > Global Climate Change & Biodiversity Indicators > Area 18,Department of Biology > University of York, York, YO10 5YW, UK > Phone: + 44 (0) 1904 328645, E-mail: ct529 at york.ac.uk > > > _______________________________________________ > Help-octave mailing list > Help-octave at octave.org > https://www-old.cae.wisc.edu/mailman/listinfo/help-octave > > You can use the lookup function v=[0,0,0,0,1,2,4,6,8,8,8,8]; lookup(v, 4.3) lookup assumes an ordered vector and performs very fast O(log(n)) - mh -- View this message in context: http://www.nabble.com/A-point-in-a-vector--tp25688207p25689277.html Sent from the Octave - General mailing list archive at Nabble.com. From sidney at sidney.com Wed Sep 30 20:40:36 2009 From: sidney at sidney.com (Sidney Markowitz) Date: Thu, 01 Oct 2009 14:40:36 +1300 Subject: feval call to a subfunction fails when it is in a subfunction Message-ID: <4AC40894.70707@sidney.com> I'm new to using Octave and don't know if this is a bug in my code, a bug in Octave, or something wrong with my installed copy of Octave. The following code demonstrates the problem. The first feval, in the main function, works and the result is displayed. The other feval, inside the subfunction switchyard2, gets an error in line 9 error: feval: function `mysin' not found I am using Octave version 3.2.2 compiled on my Macbook under MacOS 10.6.1, downloaded and built from Macports. I put the following text in a file named ./switchyard.m and invoked it in the Octave command line by typing switchyard(10) Do others get the same results? Is there a bug in my example code? Is it a bug in Octave? function y = switchyard(x) z = feval('mysin', x); disp(z); y = switchyard2(x); return; endfunction function y = switchyard2(x) y = feval('mysin', x); return; endfunction function y= mysin(x) y = sin(x); return; endfunction From bpabbott at mac.com Wed Sep 30 20:53:45 2009 From: bpabbott at mac.com (Ben Abbott) Date: Wed, 30 Sep 2009 21:53:45 -0400 Subject: feval call to a subfunction fails when it is in a subfunction In-Reply-To: <4AC40894.70707@sidney.com> References: <4AC40894.70707@sidney.com> Message-ID: On Sep 30, 2009, at 9:40 PM, Sidney Markowitz wrote: > I'm new to using Octave and don't know if this is a bug in my code, a > bug in Octave, or something wrong with my installed copy of Octave. > > The following code demonstrates the problem. The first feval, in the > main function, works and the result is displayed. The other feval, > inside the subfunction switchyard2, gets an error in line 9 > error: feval: function `mysin' not found > > I am using Octave version 3.2.2 compiled on my Macbook under MacOS > 10.6.1, downloaded and built from Macports. I put the following text > in > a file named ./switchyard.m and invoked it in the Octave command > line by > typing switchyard(10) > > Do others get the same results? Is there a bug in my example code? > Is it > a bug in Octave? > > function y = switchyard(x) > z = feval('mysin', x); > disp(z); > y = switchyard2(x); > return; > endfunction > > function y = switchyard2(x) > y = feval('mysin', x); > return; > endfunction > > function y= mysin(x) > y = sin(x); > return; > endfunction It appears that I'm getting the same. octave-3.2.2:4> switchyard(pi) 1.2246e-16 error: feval: function `mysin' not found error: called from: error: /Users/bpabbott/switchyard.m at line 9, column 5 error: /Users/bpabbott/switchyard.m at line 4, column 6 01 function y = switchyard(x) 02 z = feval('mysin', x); 03 disp(z); 04 y = switchyard2(x); 05 return; 06 endfunction 07 08 function y = switchyard2(x) 09 y = feval('mysin', x); 10 return; 11 endfunction 12 13 function y= mysin(x) 14 y = sin(x); 15 return; 16 endfunction I'm also running Mac OS 10.6. I'm presently building the developers sources, so I can't check them till tomorrow. Ben