<div dir="ltr"><div class="gmail_default" style="font-family:georgia,serif">Hello,<br><br></div><div class="gmail_default" style="font-family:georgia,serif">I have been trying to use the functions PetscSocketOpen but it gets stuck in this function shooting the following error<br><br>[0]PETSC ERROR: --------------------- Error Message --------------------------------------------------------------<br>[0]PETSC ERROR: Error in system call<br>[0]PETSC ERROR: Connection refused by remote host renoir port 5005<br>[0]PETSC ERROR: See <a href="http://www.mcs.anl.gov/petsc/documentation/faq.html">http://www.mcs.anl.gov/petsc/documentation/faq.html</a> for trouble shooting.<br>[0]PETSC ERROR: Petsc Release Version 3.5.2, Sep, 08, 2014 <br>[0]PETSC ERROR: ./10D on a arch-linux2-c-debug named renoir by hridya Wed Jan 28 10:45:49 2015<br>[0]PETSC ERROR: Configure options --download-mpich<br>[0]PETSC ERROR: #1 PetscOpenSocket() line 133 in /home/hridya/Downloads/petsc-3.5.2/src/sys/classes/viewer/impls/socket/send.c<br>[0]PETSC ERROR: #2 PetscViewerSocketSetConnection() line 400 in /home/hridya/Downloads/petsc-3.5.2/src/sys/classes/viewer/impls/socket/send.c<br>[0]PETSC ERROR: #3 PetscViewerSocketOpen() line 289 in /home/hridya/Downloads/petsc-3.5.2/src/sys/classes/viewer/impls/socket/send.c<br><br></div><div class="gmail_default" style="font-family:georgia,serif">i am using this for the first time. Please help !<br><br></div><div class="gmail_default" style="font-family:georgia,serif">Thanks a lot<br></div><div class="gmail_default" style="font-family:georgia,serif"><br></div></div><div class="gmail_extra"><br clear="all"><div><div class="gmail_signature"><div dir="ltr"><b><font face="georgia, serif">Siddhesh M Godbole</font></b><div><br></div><div><font color="#666666">5th year Dual Degree,</font></div><div><font color="#666666">Civil Eng & Applied Mech.</font></div><div><font color="#666666">IIT Madras</font></div></div></div></div>
<br><div class="gmail_quote">On Tue, Jan 27, 2015 at 6:54 PM, Barry Smith <span dir="ltr"><<a href="mailto:bsmith@mcs.anl.gov" target="_blank">bsmith@mcs.anl.gov</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><br>
  Use PetscBinaryWrite.m from MATLAB (documentation at the top of the file) to save the array into a file then in PETSc use VecLoad() to load the matrix.  PetscBinaryWrite.m is in $PETSC_DIR/bin/matlab or $PETSC_DIR/share/petsc/matlab depending on your version of PETSc.<br>
<span class="HOEnZb"><font color="#888888"><br>
   Barry<br>
</font></span><div class="HOEnZb"><div class="h5"><br>
<br>
<br>
> On Jan 27, 2015, at 1:52 AM, siddhesh godbole <<a href="mailto:siddhesh4godbole@gmail.com">siddhesh4godbole@gmail.com</a>> wrote:<br>
><br>
> Hello,<br>
> i am trying to import an array of 10000 elements into petsc. interfacing fails when i try to use launch('./mycode',np,opt) in my matlab due to some incompatibility. Then i tried importing .mat file into petsc and i got stuck.<br>
> Can you please tell me how can i import an array from matlab into petsc and use it for my calculations?<br>
>  Thanks in advance!<br>
><br>
> Siddhesh M Godbole<br>
><br>
> 5th year Dual Degree,<br>
> Civil Eng & Applied Mech.<br>
> IIT Madras<br>
<br>
</div></div></blockquote></div><br></div>