<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0">
  <channel>
    <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/265216</link>
    <title>MATLAB Central Newsreader - MATLAB segmentation violation on matrix multiplication</title>
    <description>Feed for thread: MATLAB segmentation violation on matrix multiplication</description>
    <language>en-us</language>
    <copyright>&amp;copy;1994-2012 by MathWorks, Inc.</copyright>
    <webmaster>webmaster@mathworks.com</webmaster>
    <generator>MATLAB Central Newsreader</generator>
    <docs>http://blogs.law.harvard.edu/tech/rss</docs>
    <ttl>60</ttl>
    <image>
      <title>MathWorks</title>
      <url>http://www.mathworks.com/images/membrane_icon.gif</url>
    </image>
    <item>
      <pubDate>Sat, 07 Nov 2009 02:16:03 -0500</pubDate>
      <title>MATLAB segmentation violation on matrix multiplication</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/265216#692837</link>
      <author>Aditya Rawal</author>
      <description>Here is my code:&lt;br&gt;
&lt;br&gt;
clear;&lt;br&gt;
clc;&lt;br&gt;
v_temp1 = zeros(2,2);&lt;br&gt;
&lt;br&gt;
A = [4 2 ; 2 4];&lt;br&gt;
M_matrix = [1 1 ; 1 1];&lt;br&gt;
C = A * M_matrix&lt;br&gt;
&lt;br&gt;
Interestingly i get segmentation fault whenever i fire this code on a CPU cluster, but it ofcourse runs well on my local machine. I am sure there is some setup issue, but don't know what...&lt;br&gt;
Another thing is that when i replace the multiplication operator with addition/subtraction, it works... &lt;br&gt;
&lt;br&gt;
Here is the error that i am getting..&lt;br&gt;
------------------------------------------------------------------------&lt;br&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;Segmentation violation detected at Fri Nov  6 20:13:51 2009&lt;br&gt;
------------------------------------------------------------------------&lt;br&gt;
&lt;br&gt;
Configuration:&lt;br&gt;
&amp;nbsp;&amp;nbsp;MATLAB Version:   7.5.0.338 (R2007b)&lt;br&gt;
&amp;nbsp;&amp;nbsp;MATLAB License:   168993&lt;br&gt;
&amp;nbsp;&amp;nbsp;Operating System: Linux 2.6.24.6+desktop10+25.63 #1 SMP Thu Nov 5 15:03:22 CST 2009 i686&lt;br&gt;
&amp;nbsp;&amp;nbsp;GNU C Library:    2.7 stable&lt;br&gt;
&amp;nbsp;&amp;nbsp;Window System:    No active display&lt;br&gt;
&amp;nbsp;&amp;nbsp;Current Visual:   None&lt;br&gt;
&amp;nbsp;&amp;nbsp;Processor ID:     x86 Family 6 Model 7 Stepping 6, GenuineIntel&lt;br&gt;
&amp;nbsp;&amp;nbsp;Virtual Machine:  Java 1.6.0 with Sun Microsystems Inc. Java HotSpot(TM) Client VM mixed mode, sharing&lt;br&gt;
&amp;nbsp;&amp;nbsp;Default Charset:  US-ASCII&lt;br&gt;
&lt;br&gt;
Register State:&lt;br&gt;
&amp;nbsp;&amp;nbsp;eax = 00000000   ebx = 44598510&lt;br&gt;
&amp;nbsp;&amp;nbsp;ecx = 00000000   edx = 00000002&lt;br&gt;
&amp;nbsp;&amp;nbsp;esi = 44eedaac   edi = 00000000&lt;br&gt;
&amp;nbsp;&amp;nbsp;ebp = 4459fd00   esp = 44eeba18&lt;br&gt;
&amp;nbsp;&amp;nbsp;eip = 43c8f761   flg = 00010246&lt;br&gt;
&lt;br&gt;
Stack Trace:&lt;br&gt;
&amp;nbsp;&amp;nbsp;[0] mkl.so:SearchPath~(0x645f6c6d, 0x732e6665, 111, 0) + 41 bytes&lt;br&gt;
&lt;br&gt;
Please follow these steps to report this problem to The MathWorks so we&lt;br&gt;
have the best chance of correcting it:&lt;br&gt;
&lt;br&gt;
The next time MATLAB is launched under typical usage, a dialog box will&lt;br&gt;
open to help you send the error log to The MathWorks. Alternatively, you&lt;br&gt;
can send an e-mail to segv@mathworks.com with the following file attached:&lt;br&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;/tmp/matlab_crash_dump.26316&lt;br&gt;
&lt;br&gt;
If the problem is reproducible, please submit a Service Request via:&lt;br&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;a href=&quot;http://www.mathworks.com/support/contact_us/ts/help_request_1.html&quot;&gt;http://www.mathworks.com/support/contact_us/ts/help_request_1.html&lt;/a&gt;&lt;br&gt;
&lt;br&gt;
A technical support engineer might contact you with further information.&lt;br&gt;
&lt;br&gt;
Thank you for your help. Save your workspace and restart MATLAB.</description>
    </item>
    <item>
      <pubDate>Sat, 07 Nov 2009 03:08:02 -0500</pubDate>
      <title>Re: MATLAB segmentation violation on matrix multiplication</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/265216#692840</link>
      <author>James Tursa</author>
      <description>&quot;Aditya Rawal&quot; &amp;lt;aditya@cs.utexas.edu&amp;gt; wrote in message &amp;lt;hd2l93$f06$1@fred.mathworks.com&amp;gt;...&lt;br&gt;
&amp;gt; Here is my code:&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; clear;&lt;br&gt;
&amp;gt; clc;&lt;br&gt;
&amp;gt; v_temp1 = zeros(2,2);&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; A = [4 2 ; 2 4];&lt;br&gt;
&amp;gt; M_matrix = [1 1 ; 1 1];&lt;br&gt;
&amp;gt; C = A * M_matrix&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; Interestingly i get segmentation fault whenever i fire this code on a CPU cluster, but it ofcourse runs well on my local machine. I am sure there is some setup issue, but don't know what...&lt;br&gt;
&amp;gt; Another thing is that when i replace the multiplication operator with addition/subtraction, it works... &lt;br&gt;
&lt;br&gt;
Matrix multiplication calls a BLAS library function, whereas add/subtract do not. I suspect your cluster MATLAB is loading an incompatible version of the BLAS libraries to compute with, but I don't know how to fix your problem. Do you have mixed 64-bit and 32-bit versions installed?&lt;br&gt;
&lt;br&gt;
James Tursa</description>
    </item>
    <item>
      <pubDate>Sat, 07 Nov 2009 07:38:03 -0500</pubDate>
      <title>Re: MATLAB segmentation violation on matrix multiplication</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/265216#692855</link>
      <author>Aditya Rawal</author>
      <description>Hi James,&lt;br&gt;
&lt;br&gt;
How do i find if i have both 32 bit and 64 bit installed?&lt;br&gt;
&lt;br&gt;
Thanks&lt;br&gt;
Aditya&lt;br&gt;
&lt;br&gt;
&quot;James Tursa&quot; &amp;lt;aclassyguy_with_a_k_not_a_c@hotmail.com&amp;gt; wrote in message &amp;lt;hd2oai$f1d$1@fred.mathworks.com&amp;gt;...&lt;br&gt;
&amp;gt; &quot;Aditya Rawal&quot; &amp;lt;aditya@cs.utexas.edu&amp;gt; wrote in message &amp;lt;hd2l93$f06$1@fred.mathworks.com&amp;gt;...&lt;br&gt;
&amp;gt; &amp;gt; Here is my code:&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; clear;&lt;br&gt;
&amp;gt; &amp;gt; clc;&lt;br&gt;
&amp;gt; &amp;gt; v_temp1 = zeros(2,2);&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; A = [4 2 ; 2 4];&lt;br&gt;
&amp;gt; &amp;gt; M_matrix = [1 1 ; 1 1];&lt;br&gt;
&amp;gt; &amp;gt; C = A * M_matrix&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; Interestingly i get segmentation fault whenever i fire this code on a CPU cluster, but it ofcourse runs well on my local machine. I am sure there is some setup issue, but don't know what...&lt;br&gt;
&amp;gt; &amp;gt; Another thing is that when i replace the multiplication operator with addition/subtraction, it works... &lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; Matrix multiplication calls a BLAS library function, whereas add/subtract do not. I suspect your cluster MATLAB is loading an incompatible version of the BLAS libraries to compute with, but I don't know how to fix your problem. Do you have mixed 64-bit and 32-bit versions installed?&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; James Tursa</description>
    </item>
  </channel>
</rss>

