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
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML3.2 EN">
<HTML>
<HEAD>
<META NAME="GENERATOR" CONTENT="DOCTEXT">
<TITLE>KSPInitialResidual</TITLE>
</HEAD>
<BODY BGCOLOR="FFFFFF">
<A NAME="KSPInitialResidual"><H1>KSPInitialResidual</H1></A>
Computes the residual.
<H3><FONT COLOR="#CC3333">Synopsis</FONT></H3>
<PRE>
#include "petscksp.h"
int KSPInitialResidual(KSP ksp,Vec vsoln,Vec vt1,Vec vt2,Vec vres,Vec vb)
</PRE>
Collective on <A HREF="../KSP/KSP.html#KSP">KSP</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>vsoln </B></TD><TD>- solution to use in computing residual
</TD></TR>
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B>vt1, vt2 </B></TD><TD>- temporary work vectors
</TD></TR>
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B>vres </B></TD><TD>- calculated residual
</TD></TR>
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B>vb </B></TD><TD>- right-hand-side vector
</TD></TR></TABLE>
<P>
<H3><FONT COLOR="#CC3333">Notes</FONT></H3>
This routine assumes that an iterative method, designed for
<pre>
A x = b
</pre>
will be used with a preconditioner, C, such that the actual problem is either
<pre>
AC u = f (right preconditioning) or
</pre>
<pre>
CA x = Cf (left preconditioning).
</pre>
<P>
<P>
<H3><FONT COLOR="#CC3333">Keywords</FONT></H3>
<A HREF="../KSP/KSP.html#KSP">KSP</A>, residual
<BR>
<P>
<H3><FONT COLOR="#CC3333">See Also</FONT></H3>
KSPMonitor()
<BR><P><B><P><B><FONT COLOR="#CC3333">Level:</FONT></B>developer
<BR><FONT COLOR="#CC3333">Location:</FONT></B><A HREF="../../../src/sles/ksp/interface/itres.c.html#KSPInitialResidual">src/sles/ksp/interface/itres.c</A>
<BR><A HREF="./index.html">Index of all KSP 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>
|