File: PETSC_VIEWER_SOCKET_.html

package info (click to toggle)
petsc 3.7.5%2Bdfsg1-4
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 163,864 kB
  • ctags: 618,438
  • sloc: ansic: 515,133; python: 29,793; makefile: 20,458; fortran: 18,998; cpp: 6,515; f90: 3,914; sh: 1,012; xml: 621; objc: 445; csh: 240; java: 13
file content (64 lines) | stat: -rw-r--r-- 4,947 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML3.2 EN">
<HTML>
<HEAD> <link rel="canonical" href="http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Viewer/PETSC_VIEWER_SOCKET_.html" />
<META NAME="GENERATOR" CONTENT="DOCTEXT">
<TITLE>PETSC_VIEWER_SOCKET_</TITLE>
</HEAD>
<BODY BGCOLOR="FFFFFF">
   <div id="version" align=right><b>petsc-3.7.5 2017-01-01</b></div>
   <div id="bugreport" align=right><a href="mailto:petsc-maint@mcs.anl.gov?subject=Typo or Error in Documentation &body=Please describe the typo or error in the documentation: petsc-3.7.5 v3.7.5 docs/manualpages/Viewer/PETSC_VIEWER_SOCKET_.html "><small>Report Typos and Errors</small></a></div>
<A NAME="PETSC_VIEWER_SOCKET_"><H1>PETSC_VIEWER_SOCKET_</H1></A>
Creates a socket viewer shared by all processors in a communicator. 
<H3><FONT COLOR="#CC3333">Synopsis</FONT></H3>
<PRE>
PetscViewer  PETSC_VIEWER_SOCKET_(MPI_Comm comm)
</PRE>
Collective on <A HREF="../Sys/MPI_Comm.html#MPI_Comm">MPI_Comm</A>
<P>
<H3><FONT COLOR="#CC3333">Input Parameter</FONT></H3>
<DT><B>comm </B> -the MPI communicator to share the socket <A HREF="../Viewer/PetscViewer.html#PetscViewer">PetscViewer</A>
<br>
<P>

<P>
<H3><FONT COLOR="#CC3333">Options Database Keys</FONT></H3>
For use with the default <A HREF="../Viewer/PETSC_VIEWER_SOCKET_WORLD.html#PETSC_VIEWER_SOCKET_WORLD">PETSC_VIEWER_SOCKET_WORLD</A> or if
NULL is passed for machine or <A HREF="../Sys/PETSC_DEFAULT.html#PETSC_DEFAULT">PETSC_DEFAULT</A> is passed for port
<pre>
   -viewer_socket_machine &lt;machine&gt;
</pre>
<pre>
   -viewer_socket_port &lt;port&gt;
</pre>
<P>
<H3><FONT COLOR="#CC3333">Environmental variables</FONT></H3>
<TABLE border="0" cellpadding="0" cellspacing="0">
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B>PETSC_VIEWER_SOCKET_PORT portnumber</B></TD><TD>- -   PETSC_VIEWER_SOCKET_MACHINE machine name
</TD></TR>
<P>
<H3><FONT COLOR="#CC3333">Notes</FONT></H3>
Unlike almost all other PETSc routines, PetscViewer_SOCKET_ does not return
an error code.  The socket <A HREF="../Viewer/PetscViewer.html#PetscViewer">PetscViewer</A> is usually used in the form
<pre>
      XXXView(XXX object,<A HREF="../Viewer/PETSC_VIEWER_SOCKET_.html#PETSC_VIEWER_SOCKET_">PETSC_VIEWER_SOCKET_</A>(comm));
</pre>
<P>
Currently the only socket client available is MATLAB. See
src/dm/examples/tests/ex12.c and ex12.m for an example of usage.
<P>
Connects to a waiting socket and stays connected until <A HREF="../Viewer/PetscViewerDestroy.html#PetscViewerDestroy">PetscViewerDestroy</A>() is called.
<P>
Use this for communicating with an interactive MATLAB session, see <A HREF="../Viewer/PETSC_VIEWER_MATLAB_.html#PETSC_VIEWER_MATLAB_">PETSC_VIEWER_MATLAB_</A>() for writing output to a
.mat file. Use <A HREF="../Sys/PetscMatlabEngineCreate.html#PetscMatlabEngineCreate">PetscMatlabEngineCreate</A>() or <A HREF="../Sys/PETSC_MATLAB_ENGINE_.html#PETSC_MATLAB_ENGINE_">PETSC_MATLAB_ENGINE_</A>(), <A HREF="../Sys/PETSC_MATLAB_ENGINE_SELF.html#PETSC_MATLAB_ENGINE_SELF">PETSC_MATLAB_ENGINE_SELF</A>, or <A HREF="../Sys/PETSC_MATLAB_ENGINE_WORLD.html#PETSC_MATLAB_ENGINE_WORLD">PETSC_MATLAB_ENGINE_WORLD</A>
for communicating with a MATLAB Engine
<P>
<H3><FONT COLOR="#CC3333">See Also</FONT></H3>
 <A HREF="../Viewer/PETSC_VIEWER_SOCKET_WORLD.html#PETSC_VIEWER_SOCKET_WORLD">PETSC_VIEWER_SOCKET_WORLD</A>, <A HREF="../Viewer/PETSC_VIEWER_SOCKET_SELF.html#PETSC_VIEWER_SOCKET_SELF">PETSC_VIEWER_SOCKET_SELF</A>, <A HREF="../Viewer/PetscViewerSocketOpen.html#PetscViewerSocketOpen">PetscViewerSocketOpen</A>(), <A HREF="../Viewer/PetscViewerCreate.html#PetscViewerCreate">PetscViewerCreate</A>(),
<BR><A HREF="../Viewer/PetscViewerSocketSetConnection.html#PetscViewerSocketSetConnection">PetscViewerSocketSetConnection</A>(), <A HREF="../Viewer/PetscViewerDestroy.html#PetscViewerDestroy">PetscViewerDestroy</A>(), <A HREF="../Viewer/PETSC_VIEWER_SOCKET_.html#PETSC_VIEWER_SOCKET_">PETSC_VIEWER_SOCKET_</A>(), <A HREF="../Viewer/PetscViewerBinaryWrite.html#PetscViewerBinaryWrite">PetscViewerBinaryWrite</A>(), <A HREF="../Viewer/PetscViewerBinaryRead.html#PetscViewerBinaryRead">PetscViewerBinaryRead</A>(),
<A HREF="../Viewer/PetscViewerBinaryWriteStringArray.html#PetscViewerBinaryWriteStringArray">PetscViewerBinaryWriteStringArray</A>(), <A HREF="../Viewer/PetscViewerBinaryGetDescriptor.html#PetscViewerBinaryGetDescriptor">PetscViewerBinaryGetDescriptor</A>(), <A HREF="../Viewer/PETSC_VIEWER_MATLAB_.html#PETSC_VIEWER_MATLAB_">PETSC_VIEWER_MATLAB_</A>()
<P><B><P><B><FONT COLOR="#CC3333">Level:</FONT></B>intermediate
<BR><FONT COLOR="#CC3333">Location:</FONT></B><A HREF="../../../src/sys/classes/viewer/impls/socket/send.c.html#PETSC_VIEWER_SOCKET_">src/sys/classes/viewer/impls/socket/send.c</A>
<BR><A HREF="./index.html">Index of all Viewer routines</A>
<BR><A HREF="../../index.html">Table of Contents for all manual pages</A>
<BR><A HREF="../singleindex.html">Index of all manual pages</A>
</BODY></HTML>