File: matkaij.html

package info (click to toggle)
petsc 3.14.5%2Bdfsg1-4
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 266,472 kB
  • sloc: ansic: 680,898; python: 33,303; cpp: 16,324; makefile: 14,022; f90: 13,731; javascript: 10,713; fortran: 9,581; sh: 1,373; xml: 619; objc: 445; csh: 192; pascal: 148; java: 13
file content (56 lines) | stat: -rw-r--r-- 3,840 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
<html>
<title>MATKAIJ</title><body bgcolor="FFFFFF">
   <div id="version" align=right><b>petsc-3.14.5 2021-03-03</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.14.5 v3.14.5 docs/manualpages/concepts/matkaij.html "><small>Report Typos and Errors</small></a></div>
<h2>MATKAIJ</h2>
<menu>
<LI><A HREF="../../../src/ksp/ksp/tutorials/ex74.c.html"><CONCEPT>ex74.c</CONCEPT></A>
<menu>
Solves the constant-coefficient 1D heat equation <BR>with an Implicit Runge-Kutta method using MatKAIJ.                  <BR>
                                                                    <BR>
    du      d^2 u                                                   <BR>
    --  = a ----- ; 0 &lt;= x &lt;= 1;                                    <BR>
    dt      dx^2                                                    <BR>
                                                                    <BR>
  with periodic boundary conditions                                 <BR>
                                                                    <BR>
2nd order central discretization in space:                          <BR>
                                                                    <BR>
   [ d^2 u ]     u_{i+1} - 2u_i + u_{i-1}                           <BR>
   [ ----- ]  =  ------------------------                           <BR>
   [ dx^2  ]i              h^2                                      <BR>
                                                                    <BR>
    i = grid index;    h = x_{i+1}-x_i (Uniform)                    <BR>
    0 &lt;= i &lt; n         h = 1.0/n                                    <BR>
                                                                    <BR>
Thus,                                                               <BR>
                                                                    <BR>
   du                                                               <BR>
   --  = Ju;  J = (a/h^2) tridiagonal(1,-2,1)_n                     <BR>
   dt                                                               <BR>
                                                                    <BR>
Implicit Runge-Kutta method:                                        <BR>
                                                                    <BR>
  U^(k)   = u^n + dt \\sum_i a_{ki} JU^{i}                          <BR>
  u^{n+1} = u^n + dt \\sum_i b_i JU^{i}                             <BR>
                                                                    <BR>
  i = 1,...,s (s -&gt; number of stages)                               <BR>
                                                                    <BR>
At each time step, we solve                                         <BR>
                                                                    <BR>
 [  1                                  ]     1                      <BR>
 [ -- I \\otimes A^{-1} - J \\otimes I ] U = -- u^n \\otimes A^{-1} <BR>
 [ dt                                  ]     dt                     <BR>
                                                                    <BR>
  where A is the Butcher tableaux of the implicit                   <BR>
  Runge-Kutta method,                                               <BR>
                                                                    <BR>
with MATKAIJ and KSP.                                               <BR>
                                                                    <BR>
Available IRK Methods:                                              <BR>
  gauss       n-stage Gauss method                                  <BR>
                                                                    <BR>
</menu>
</menu>
</body>
</html>