OptFEM2DP1 Toolbox  V1.2b3
Matlab/Octave Optimized P1-Lagrange Finite Element Method in 2D
 All Files Functions Pages
valid_FEMmatrices.m
Go to the documentation of this file.
1 function Test=valid_FEMmatrices()
2 % automatic generation with sage
3 % Copyright:
4 % See \ref license
5 i=1;
6 Test(i).u=@(x,y) x + y;
7 Test(i).cu='x + y';
8 Test(i).v=@(x,y) x - y;
9 Test(i).cv='x - y';
10 Test(i).w=@(x,y) 2.*x + y;
11 Test(i).cw='2*x + y';
12 Test(i).Mass=0.0000000000000000;
13 Test(i).MassW=0.08333333333333333;
14 Test(i).Stiff=0.0000000000000000;
15 Test(i).degree=1;
16 i=2;
17 Test(i).u=@(x,y) 3.*x + 2.*y - 1;
18 Test(i).cu='3*x + 2*y - 1';
19 Test(i).v=@(x,y) 2.*x - 2.*y + 1;
20 Test(i).cv='2*x - 2*y + 1';
21 Test(i).w=@(x,y) 2.*x - 5.*y;
22 Test(i).cw='2*x - 5*y';
23 Test(i).Mass=1.666666666666667;
24 Test(i).MassW=-1.083333333333333;
25 Test(i).Stiff=2.000000000000000;
26 Test(i).degree=1;
27 i=3;
28 Test(i).u=@(x,y) 3.*x.^2 - x.*y + 2.*y.^2;
29 Test(i).cu='3*x^2 - x*y + 2*y^2';
30 Test(i).v=@(x,y) 2.*x.^2 + x.*y - 3.*y.^2 - y;
31 Test(i).cv='2*x^2 + x*y - 3*y^2 - y';
32 Test(i).w=@(x,y) x.*y;
33 Test(i).cw='x*y';
34 Test(i).Mass=-0.7500000000000000;
35 Test(i).MassW=-0.3416666666666667;
36 Test(i).Stiff=0.8333333333333333;
37 Test(i).degree=2;
38 i=4;
39 Test(i).u=@(x,y) 3.*x.^2 - 4.*x.*y + 2.*y.^2 - x + 4.*y + 4;
40 Test(i).cu='3*x^2 - 4*x*y + 2*y^2 - x + 4*y + 4';
41 Test(i).v=@(x,y) 2.*x.^2 + 2.*x.*y - 3.*y.^2 - 2.*y + 1;
42 Test(i).cv='2*x^2 + 2*x*y - 3*y^2 - 2*y + 1';
43 Test(i).w=@(x,y) x.^2 + y.^2 - 3;
44 Test(i).cw='x^2 + y^2 - 3';
45 Test(i).Mass=-0.3611111111111111;
46 Test(i).MassW=0.2805555555555556;
47 Test(i).Stiff=-17.33333333333333;
48 Test(i).degree=2;
49 i=5;
50 Test(i).u=@(x,y) 3.*x.^3 - 2.*x.*y + 2.*y.^2 + 3.*x;
51 Test(i).cu='3*x^3 - 2*x*y + 2*y^2 + 3*x';
52 Test(i).v=@(x,y) -3.*y.^3 + 2.*x.^2 + 2.*x.*y - 2.*y;
53 Test(i).cv='-3*y^3 + 2*x^2 + 2*x*y - 2*y';
54 Test(i).w=@(x,y) x.^2.*y + x.*y.^2 - 2.*x.*y + 1;
55 Test(i).cw='x^2*y + x*y^2 - 2*x*y + 1';
56 Test(i).Mass=-0.5708333333333333;
57 Test(i).MassW=-0.4377380952380952;
58 Test(i).Stiff=10.33333333333333;
59 Test(i).degree=3;
60 i=6;
61 Test(i).u=@(x,y) 3.*x.^4 + 3.*x.^3 + 2.*y.^2;
62 Test(i).cu='3*x^4 + 3*x^3 + 2*y^2';
63 Test(i).v=@(x,y) 2.*y.^4 - 3.*y.^3 + 2.*x.^2;
64 Test(i).cv='2*y^4 - 3*y^3 + 2*x^2';
65 Test(i).w=@(x,y) x.^4 + y.^3 - 3;
66 Test(i).cw='x^4 + y^3 - 3';
67 Test(i).Mass=1.400515873015873;
68 Test(i).MassW=-3.020477994227994;
69 Test(i).Stiff=16.00000000000000;
70 Test(i).degree=4;
71 i=7;
72 Test(i).u=@(x,y) x.^5 + 3.*x.^3.*y.^2 - y.^5;
73 Test(i).cu='x^5 + 3*x^3*y^2 - y^5';
74 Test(i).v=@(x,y) 3.*x.^5 + 2.*x.^3.*y.^2 + 2.*y.^5 + 2.*x.^2.*y.^2;
75 Test(i).cv='3*x^5 + 2*x^3*y^2 + 2*y^5 + 2*x^2*y^2';
76 Test(i).w=@(x,y) -3.*x.^3.*y.^2 + x.^2 + y.^2 + 1;
77 Test(i).cw='-3*x^3*y^2 + x^2 + y^2 + 1';
78 Test(i).Mass=0.9669672919672920;
79 Test(i).MassW=1.011666243809101;
80 Test(i).Stiff=18.73777777777778;
81 Test(i).degree=5;
82 i=8;
83 Test(i).u=@(x,y) x.^6 - x.^5 + 3.*x.^3.*y.^2 - y.^5;
84 Test(i).cu='x^6 - x^5 + 3*x^3*y^2 - y^5';
85 Test(i).v=@(x,y) y.^6 + 3.*x.^5 + 2.*x.^3.*y.^2 + 2.*y.^5 + 2.*x.^2.*y.^2;
86 Test(i).cv='y^6 + 3*x^5 + 2*x^3*y^2 + 2*y^5 + 2*x^2*y^2';
87 Test(i).w=@(x,y) 4.*x.^6 - 3.*x.^3.*y.^3 - y.^6;
88 Test(i).cw='4*x^6 - 3*x^3*y^3 - y^6';
89 Test(i).Mass=0.4305452484023913;
90 Test(i).MassW=0.5553725794902266;
91 Test(i).Stiff=6.920317460317460;
92 Test(i).degree=6;