bugGNU Octave - Bugs: bug #41566, Bus Error

 
 

bug #41566: Bus Error

Submitted by:  None
Submitted on:  Wed 12 Feb 2014 11:43:48 AM UTC  
 
Category:  Libraries Severity:  3 - Normal
Priority:  5 - Normal Item Group:  Segfault, Bus Error, etc.
Status:  Wont Fix Assigned to:  None
Originator Name:  Michele Riva Originator Email:  -email is unavailable-
Open/Closed:  Closed Release:  3.6.4
Operating System:  Mac OS

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Sat 15 Feb 2014 08:11:21 PM UTC, comment #5:

This seems to be a problem with the 3.6.4 Macports version of Octave, rather than a problem with Octave itself. I think the simplest solution is to upgrade, or wait until Macports produces a 3.8.0 version. Some help for installing on MacOS X is available here: http://wiki.octave.org/Octave_for_MacOS_X

Rik <rik5>
Project Administrator
Thu 13 Feb 2014 11:03:43 PM UTC, comment #4:

Yep sure, that's the same script which causes the panic. I know my octave is not the latest version, but looks like i have to wait for MacPorts to update their repositories to get it. I remind that i use octave 3.6.4 on Mac OS 10.6.8 installed through MacPorts

I also attach the complete output of my terminal while executing the script.

(file #30546)

Anonymous
Wed 12 Feb 2014 02:24:12 PM UTC, comment #3:

Works OK for me on Mac OSX 10.9.1 with Octave 3.8.0
I don't have 3.6.4 at hand to try with.
Can't you just upgrade your Octave version?
c.

Anonymous
Wed 12 Feb 2014 02:14:22 PM UTC, comment #2:

works for me with versions 3.6.4 and 3.8.0 on Windows.
it could be Mac-specific.
I assume you submitted the script before fixing it to avoid the crash, right?

Felipe G. Nievinski <fgnievinski>
Wed 12 Feb 2014 11:47:46 AM UTC, comment #1:

Sorry, just noticed that the editor formatted badly the script, so i attached it.

Anonymous
Wed 12 Feb 2014 11:43:48 AM UTC, original submission:

Hello everyone. I am an engineering student and i use octave for solving exercises. Today i executed some (wrong) code, but rather than telling me what's wrong octave just panics and quits. here's the code:

clear
clc
clf

x=linspace(-2.*pi,2.*pi,1000);
nodi=linspace(-2.*pi,2.*pi,11)
f=@(x) sin(1./(1+x.^2));
X=nodi;
Y=f(nodi);
P=polyfit(X,Y,10)
figure(1)
plot(x,f(x),x,polyval(P,x),nodi,f(nodi),'o')
grid on
err=max(abs(f(x)-polyval(P,x)))

n=[4,8,10];
for k=1:length(n)
distcheb=1:pi./n(k):pi;
nodicheb=cos(distcheb);
X=nodicheb;
Y=f(nodicheb);
P=polyfit(X,Y,n(k)-1);
figure(k+1)
plot(x,f(x),x,polyval(P,x),nodicheb,f(nodicheb),'o')
grid on
err(k)=max(abs(f(x)-polyval(P,x)));
end
err

I found that the issue happens with the line
distcheb=1:pi./n(k):pi;
Again i got the mistake, but why does octave panic on such a line instead of displaying an error?

Anonymous

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

Attached Files
file #30546:  Output.rtf added by None (2KiB - text/rtf)
file #30524:  Lab05es5.m added by None (488B - application/octet-stream - Exercise script)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by rik5 (Posted a comment)
  • -email is unavailable- added by mtmiller (Updated the item)
  • -email is unavailable- added by fgnievinski (Posted a comment)
  • -email is unavailable- added by None (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can add your encouragement to it.
    This task has 0 encouragements so far.

    Only project members can vote.

     

     

     

    Follow 6 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2014-02-15 rik5 StatusNeed Info => Wont Fix
        Open/ClosedOpen => Closed
    2014-02-13 None Attached File- => Added Output.rtf, #30546
    2014-02-13 mtmiller CategoryNone => Libraries
        StatusNone => Need Info
    2014-02-12 None Attached File- => Added Lab05es5.m, #30524

    Back to the top


    Powered by Savane 3.3