diff +time/+rk/butcherTableau.m @ 1033:037f203b9bf5 feature/burgers1d

Merge with branch feature/advectioRV to utilize the +rv package
author Vidar Stiernström <vidar.stiernstrom@it.uu.se>
date Thu, 17 Jan 2019 10:44:12 +0100
parents e0560bc4fb7d
children
line wrap: on
line diff
--- a/+time/+rk/butcherTableau.m	Fri Oct 12 08:50:25 2018 +0200
+++ b/+time/+rk/butcherTableau.m	Thu Jan 17 10:44:12 2019 +0100
@@ -1,5 +1,5 @@
 function [s,a,b,c] = butcherTableau(order)
-
+% TODO: Change order from a double to string.
 switch order
   
     case 3
@@ -19,6 +19,15 @@
         a(4,1) = 0; a(4,2) = 0; a(4,3) = 1;
         b = [1/6 1/3 1/3 1/6];
         c = [0, 1/2, 1/2, 1];
+    % case 4-3/8
+    %     % 3/8 RK4 (Kuttas method). Lower truncation error, more flops
+    %     s = 4;
+    %     a = zeros(s,s-1);
+    %     a(2,1) = 1/3; 
+    %     a(3,1) = -1/3; a(3,2) = 1;
+    %     a(4,1) = 1; a(4,2) = -1; a(4,3) = 1;
+    %     b = [1/8 3/8 3/8 1/8];
+    %     c = [0, 1/3, 2/3, 1];
     case 6
         % Runge-Kutta 6 from Alshina07 
         s = 7;