% Matlab plot script for ppc_fd1() finite difference solver.
PLOT_WITH_MATLAB_FD_XVEC = [
-1 -0.8 -0.6 -0.4 -0.2 0 0.2 0.4 0.6 0.8 1 
];
PLOT_WITH_MATLAB_FD_TVEC = [
0 0.015625 0.03125 0.046875 0.0625 0.078125 0.09375 0.109375 0.125 0.140625 0.15625 0.171875 0.1875 0.203125 0.21875 0.234375 0.25 0.265625 0.28125 0.296875 0.3125 0.328125 0.34375 0.359375 0.375 0.390625 0.40625 0.421875 0.4375 0.453125 0.46875 0.484375 0.5 
];
PLOT_WITH_MATLAB_FD_ZMAT = [
-1 -1 -1 -1 -1 0 1 1 1 1 1 
-1 -0.998807 -0.9927 -0.955327 -0.726601 2.26986e-08 0.726601 0.955328 0.992706 0.998839 1 
-0.999937 -0.993963 -0.971281 -0.877902 -0.5817 2.06848e-07 0.581701 0.877908 0.97131 0.9941 0.999937 
-0.998909 -0.984085 -0.939256 -0.804846 -0.494048 9.0458e-07 0.494052 0.804864 0.939327 0.984332 0.998909 
-0.995322 -0.96961 -0.903224 -0.742804 -0.435376 2.60887e-06 0.435387 0.742841 0.903342 0.969932 0.995322 
-0.988588 -0.951776 -0.86713 -0.691183 -0.393088 5.72799e-06 0.393109 0.691243 0.867293 0.952152 0.988588 
-0.979079 -0.931871 -0.832788 -0.648073 -0.360929 1.04231e-05 0.360964 0.648158 0.832991 0.932285 0.979079 
-0.967491 -0.910946 -0.800861 -0.611666 -0.335483 1.66083e-05 0.335533 0.611777 0.801097 0.911384 0.967491 
-0.9545 -0.889767 -0.771468 -0.580521 -0.31473 2.40323e-05 0.314798 0.580656 0.771729 0.890215 0.9545 
-0.940654 -0.868844 -0.744499 -0.55354 -0.297396 3.23568e-05 0.297483 0.553697 0.744779 0.869289 0.940654 
-0.926362 -0.848494 -0.719758 -0.529896 -0.282638 4.12115e-05 0.282744 0.530072 0.720051 0.848927 0.926362 
-0.911918 -0.8289 -0.697031 -0.508963 -0.269873 5.02328e-05 0.269996 0.509156 0.69733 0.829314 0.911918 
-0.89753 -0.810154 -0.676107 -0.490266 -0.258685 5.90923e-05 0.258826 0.490471 0.676406 0.810545 0.89753 
-0.883336 -0.792289 -0.656793 -0.473434 -0.248772 6.75162e-05 0.248928 0.473649 0.657089 0.792655 0.883336 
-0.86943 -0.775304 -0.638917 -0.458179 -0.239905 7.5294e-05 0.240075 0.458402 0.639207 0.775643 0.86943 
-0.855873 -0.759173 -0.622326 -0.444271 -0.23191 8.22792e-05 0.232092 0.444498 0.622608 0.759487 0.855873 
-0.842701 -0.74386 -0.606887 -0.431523 -0.224653 8.83843e-05 0.224844 0.431753 0.607159 0.744149 0.842701 
-0.829933 -0.729321 -0.592482 -0.419786 -0.218025 9.3571e-05 0.218225 0.420016 0.592744 0.729587 0.829933 
-0.817578 -0.715512 -0.579009 -0.408934 -0.211942 9.78404e-05 0.212147 0.409164 0.57926 0.715756 0.817578 
-0.805634 -0.702386 -0.566377 -0.398863 -0.206331 0.000101223 0.206542 0.399091 0.566617 0.70261 0.805634 
-0.794097 -0.689899 -0.554508 -0.389485 -0.201137 0.000103769 0.20135 0.389711 0.554737 0.690104 0.794097 
-0.782956 -0.678008 -0.543331 -0.380727 -0.19631 0.000105543 0.196525 0.380948 0.543549 0.678196 0.782956 
-0.7722 -0.666674 -0.532785 -0.372524 -0.191809 0.000106615 0.192024 0.372741 0.532993 0.666845 0.7722 
-0.761815 -0.655858 -0.522815 -0.364821 -0.1876 0.000107057 0.187815 0.365033 0.523013 0.656016 0.761815 
-0.751787 -0.645527 -0.513373 -0.35757 -0.183654 0.000106942 0.183867 0.357777 0.513561 0.645671 0.751787 
-0.742101 -0.635648 -0.504415 -0.350731 -0.179944 0.000106339 0.180155 0.350932 0.504593 0.63578 0.742101 
-0.732743 -0.626192 -0.495903 -0.344265 -0.176448 0.000105315 0.176656 0.344461 0.496072 0.626313 0.732743 
-0.723697 -0.617131 -0.487801 -0.338142 -0.173148 0.000103928 0.173352 0.338332 0.487963 0.617242 0.723697 
-0.714951 -0.60844 -0.48008 -0.332333 -0.170025 0.000102234 0.170224 0.332517 0.480233 0.608542 0.714951 
-0.706489 -0.600096 -0.472711 -0.326811 -0.167064 0.000100282 0.167259 0.32699 0.472856 0.60019 0.706489 
-0.6983 -0.592078 -0.465668 -0.321556 -0.164253 9.81171e-05 0.164443 0.321728 0.465806 0.592163 0.6983 
-0.690371 -0.584365 -0.458929 -0.316545 -0.161579 9.57781e-05 0.161764 0.316711 0.45906 0.584443 0.690371 
-0.682689 -0.57694 -0.452473 -0.311762 -0.159032 9.32997e-05 0.159212 0.311922 0.452597 0.577012 0.682689 
];
surf ( PLOT_WITH_MATLAB_FD_XVEC, PLOT_WITH_MATLAB_FD_TVEC, PLOT_WITH_MATLAB_FD_ZMAT )
xlabel('x')
ylabel('t')
zlabel('u')
colormap jet
