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 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160
|
<?xml version="1.0" encoding="UTF-8"?>
<!--
* Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
* Copyright (C) XXXX-2008 - INRIA
*
* This file must be used under the terms of the CeCILL.
* This source file is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
* are also available at
* http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
*
-->
<refentry xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svg="http://www.w3.org/2000/svg" xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:db="http://docbook.org/ns/docbook" version="5.0-subset Scilab" xml:lang="en" xml:id="gmres">
<info>
<pubdate>$LastChangedDate$</pubdate>
</info>
<refnamediv>
<refname>gmres</refname>
<refpurpose> Generalized Minimum RESidual method</refpurpose>
</refnamediv>
<refsynopsisdiv>
<title>Calling Sequence</title>
<synopsis>[x,flag,err,iter,res] = gmres(A,b,rstr,tol,maxi,M,x0)</synopsis>
</refsynopsisdiv>
<refsection>
<title>Parameters</title>
<variablelist>
<varlistentry>
<term>A</term>
<listitem>
<para>n-by-n matrix or function returning <literal>A*x</literal></para>
</listitem>
</varlistentry>
<varlistentry>
<term>b</term>
<listitem>
<para>right hand side vector</para>
</listitem>
</varlistentry>
<varlistentry>
<term>x0</term>
<listitem>
<para>initial guess vector (default: zeros(n,1))</para>
</listitem>
</varlistentry>
<varlistentry>
<term>M</term>
<listitem>
<para>preconditioner: matrix or function returning <literal>M*x</literal> (In the first case, default: eye(n,n))</para>
</listitem>
</varlistentry>
<varlistentry>
<term>rstr</term>
<listitem>
<para>number of iterations between restarts (default: 10)</para>
</listitem>
</varlistentry>
<varlistentry>
<term>maxi</term>
<listitem>
<para>maximum number of iterations (default: n)</para>
</listitem>
</varlistentry>
<varlistentry>
<term>tol</term>
<listitem>
<para>error tolerance (default: 1e-6)</para>
</listitem>
</varlistentry>
<varlistentry>
<term>x</term>
<listitem>
<para>solution vector</para>
</listitem>
</varlistentry>
<varlistentry>
<term>err</term>
<listitem>
<para>final residual norm</para>
</listitem>
</varlistentry>
<varlistentry>
<term>iter</term>
<listitem>
<para>number of iterations performed</para>
</listitem>
</varlistentry>
<varlistentry>
<term>flag</term>
<listitem>
<variablelist>
<varlistentry>
<term>0 =</term>
<listitem>
<para><literal>gmres</literal> converged to the desired tolerance within <literal>maxi</literal> iterations</para>
</listitem>
</varlistentry>
<varlistentry>
<term>1 =</term>
<listitem>
<para>no convergence given <literal>maxi</literal></para>
</listitem>
</varlistentry>
</variablelist>
</listitem>
</varlistentry>
<varlistentry>
<term>res</term>
<listitem>
<para>residual vector</para>
</listitem>
</varlistentry>
</variablelist>
</refsection>
<refsection>
<title>Description</title>
<variablelist>
<varlistentry>
<term>GMRES </term>
<listitem>
<para>solves the linear system <literal>Ax=b</literal> using the Generalized Minimal residual method with restarts.</para>
</listitem>
</varlistentry>
<varlistentry>
<term>Details </term>
<listitem>
<para>of this algorithm are described in :</para>
<para>"Templates for the Solution of Linear Systems: Building Blocks for
Iterative Methods", Barrett, Berry, Chan, Demmel, Donato, Dongarra,
Eijkhout, Pozo, Romine, and Van der Vorst, SIAM Publications, 1993 (ftp
netlib2.cs.utk.edu; cd linalg; get templates.ps).</para>
<para>"Iterative Methods for Sparse Linear Systems, Second Edition" Saad,
SIAM Publications, 2003 (ftp ftp.cs.umn.edu; cd dept/users/saad/PS; get
all_ps.zip).</para>
</listitem>
</varlistentry>
</variablelist>
</refsection>
<refsection>
<title>Examples</title>
<programlisting role="example"><![CDATA[
// GMRES call x=gmres(A,b);
]]></programlisting>
</refsection>
<refsection>
<title>See Also</title>
<simplelist type="inline">
<member>
<link linkend="pcg">pcg</link>
</member>
<member>
<link linkend="qmr">qmr</link>
</member>
</simplelist>
</refsection>
<refsection>
<title>Authors</title>
<para>Sage Group (IRISA, 2005) </para>
</refsection>
</refentry>
|