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
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML3.2 EN">
<HTML>
<HEAD> <link rel="canonical" href="http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Mat/MatISSetPreallocation.html" />
<META NAME="GENERATOR" CONTENT="DOCTEXT">
<TITLE>MatISSetPreallocation</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/Mat/MatISSetPreallocation.html "><small>Report Typos and Errors</small></a></div>
<A NAME="MatISSetPreallocation"><H1>MatISSetPreallocation</H1></A>
Preallocates memory for a <A HREF="../Mat/MATIS.html#MATIS">MATIS</A> parallel matrix.
<H3><FONT COLOR="#CC3333">Synopsis</FONT></H3>
<PRE>
#include "petscmat.h"
PetscErrorCode MatISSetPreallocation(Mat B,PetscInt d_nz,const PetscInt d_nnz[],PetscInt o_nz,const PetscInt o_nnz[])
</PRE>
Collective on <A HREF="../Sys/MPI_Comm.html#MPI_Comm">MPI_Comm</A>
<P>
<H3><FONT COLOR="#CC3333">Input Parameters</FONT></H3>
<TABLE border="0" cellpadding="0" cellspacing="0">
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B>B </B></TD><TD>- the matrix
</TD></TR>
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B>d_nz </B></TD><TD>- number of nonzeros per row in DIAGONAL portion of local submatrix
(same value is used for all local rows)
</TD></TR>
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B>d_nnz </B></TD><TD>- array containing the number of nonzeros in the various rows of the
DIAGONAL portion of the local submatrix (possibly different for each row)
or NULL, if d_nz is used to specify the nonzero structure.
The size of this array is equal to the number of local rows, i.e 'm'.
For matrices that will be factored, you must leave room for (and set)
the diagonal entry even if it is zero.
</TD></TR>
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B>o_nz </B></TD><TD>- number of nonzeros per row in the OFF-DIAGONAL portion of local
submatrix (same value is used for all local rows).
</TD></TR>
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B>o_nnz </B></TD><TD>- array containing the number of nonzeros in the various rows of the
OFF-DIAGONAL portion of the local submatrix (possibly different for
each row) or NULL, if o_nz is used to specify the nonzero
structure. The size of this array is equal to the number
of local rows, i.e 'm'.
</TD></TR></TABLE>
<P>
If the *_nnz parameter is given then the *_nz parameter is ignored
<P>
<P>
Notes: This function has the same interface as the MPIAIJ preallocation routine in order to simplify the transition
from the asssembled format to the unassembled one. It overestimates the preallocation of <A HREF="../Mat/MATIS.html#MATIS">MATIS</A> local
matrices; for exact preallocation, the user should set the preallocation directly on local matrix objects.
<P>
<H3><FONT COLOR="#CC3333">Keywords</FONT></H3>
matrix
<BR>
<P>
<H3><FONT COLOR="#CC3333">See Also</FONT></H3>
<A HREF="../Mat/MatCreate.html#MatCreate">MatCreate</A>(), <A HREF="../Mat/MatCreateIS.html#MatCreateIS">MatCreateIS</A>(), <A HREF="../Mat/MatMPIAIJSetPreallocation.html#MatMPIAIJSetPreallocation">MatMPIAIJSetPreallocation</A>(), <A HREF="../Mat/MatISGetLocalMat.html#MatISGetLocalMat">MatISGetLocalMat</A>()
<BR><P><B><P><B><FONT COLOR="#CC3333">Level:</FONT></B>intermediate
<BR><FONT COLOR="#CC3333">Location:</FONT></B><A HREF="../../../src/mat/impls/is/matis.c.html#MatISSetPreallocation">src/mat/impls/is/matis.c</A>
<BR><A HREF="./index.html">Index of all Mat 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>
|