comparison +sbp/HigherVariable.m @ 246:fe26791489e0 feature/beams

Added a bunch of new operators. Still non-functional.
author Jonatan Werpers <jonatan@werpers.com>
date Wed, 31 Aug 2016 17:16:03 +0200
parents 369c643b60c3
children 02423f9323c6
comparison
equal deleted inserted replaced
245:369c643b60c3 246:fe26791489e0
9 end 9 end
10 10
11 11
12 12
13 methods 13 methods
14 function obj = HigherVariable(m,h,order) 14 function obj = HigherVariable(m,h,order, opt)
15 default_arg('opt', '')
15 16
16 if order == 2 17 if order == 2
17 [H, HI, D1, D2, D3, D4, e_1, e_m, M4, Q, S2_1, S2_m, S3_1, S3_m, S_1, S_m] = sbp.higher_variable2(m,h); 18 [H, HI, D1, D2, D3, D4, e_1, e_m, M4, Q, S2_1, S2_m, S3_1, S3_m, S_1, S_m] = sbp.higher_variable2(m,h);
18 obj.borrowing.N.S2 = 1.2500; 19 obj.borrowing.N.S2 = 1.2500;
19 obj.borrowing.N.S3 = 0.4000; 20 obj.borrowing.N.S3 = 0.4000;
20 elseif order == 4 21 elseif order == 4
21 [H, HI, D2, D4, e_1, e_m, M4, S2_1, S2_m, S3_1, S3_m, S_1, S_m] = sbp.higher_variable4(m,h); 22 switch opt
22 obj.borrowing.N.S2 = 0.5055; 23 case 'min_boundary_points'
23 obj.borrowing.N.S3 = 0.9290; 24 [H, HI, D2, D4, e_1, e_m, M4, S2_1, S2_m, S3_1, S3_m, S_1, S_m] = sbp.higher_variable4_min_boundary_points(m,h);
25 % obj.borrowing.N.S2 = 0.5055;
26 % obj.borrowing.N.S3 = 0.9290;
27 otherwise
28 [H, HI, D2, D4, e_1, e_m, M4, S2_1, S2_m, S3_1, S3_m, S_1, S_m] = sbp.higher_variable4(m,h);
29 obj.borrowing.N.S2 = 0.5055;
30 obj.borrowing.N.S3 = 0.9290;
31 end
24 elseif order == 6 32 elseif order == 6
25 [H, HI, D2, D4, e_1, e_m, M4, S2_1, S2_m, S3_1, S3_m, S_1, S_m] = sbp.higher_variable6(m,h); 33 switch opt
26 obj.borrowing.N.S2 = 0.3259; 34 case '2'
27 obj.borrowing.N.S3 = 0.1580; 35 [H, HI, D2, D4, e_1, e_m, M4, S2_1, S2_m, S3_1, S3_m, S_1, S_m] = sbp.higher_variable6_2(m,h);
36 % obj.borrowing.N.S2 = 0.3259;
37 % obj.borrowing.N.S3 = 0.1580;
38 case '3'
39 [H, HI, D2, D4, e_1, e_m, M4, S2_1, S2_m, S3_1, S3_m, S_1, S_m] = sbp.higher_variable6_3(m,h);
40 % obj.borrowing.N.S2 = 0.3259;
41 % obj.borrowing.N.S3 = 0.1580;
42 case 'min_boundary_points'
43 [H, HI, D2, D4, e_1, e_m, M4, S2_1, S2_m, S3_1, S3_m, S_1, S_m] = sbp.higher_variable6_min_boundary_points(m,h);
44 % obj.borrowing.N.S2 = 0.3259;
45 % obj.borrowing.N.S3 = 0.1580;
46 otherwise
47 [H, HI, D2, D4, e_1, e_m, M4, S2_1, S2_m, S3_1, S3_m, S_1, S_m] = sbp.higher_variable6(m,h);
48 obj.borrowing.N.S2 = 0.3259;
49 obj.borrowing.N.S3 = 0.1580;
50 elseif order == 8
51 switch opt
52 case 'min_boundary_points'
53 [H, HI, D2, D4, e_1, e_m, M4, S2_1, S2_m, S3_1, S3_m, S_1, S_m] = sbp.higher_variable8_min_boundary_points(m,h);
54 % obj.borrowing.N.S2 = 0.3259;
55 % obj.borrowing.N.S3 = 0.1580;
56 otherwise
57 [H, HI, D2, D4, e_1, e_m, M4, S2_1, S2_m, S3_1, S3_m, S_1, S_m] = sbp.higher_variable8_higher_boundary_order(m,h);
58 % obj.borrowing.N.S2 = 0.3259;
59 % obj.borrowing.N.S3 = 0.1580;
60 end
61
28 else 62 else
29 error('Invalid operator order.'); 63 error('Invalid operator order.');
30 end 64 end
31 65
32 obj.h = h; 66 obj.h = h;