% % @file relax.m % % @brief % % @copyright % Copyright (©) 2021 EPFL (Ecole Polytechnique Fédérale de Lausanne) % SPC (Swiss Plasma Center) % % SPClibs is free software: you can redistribute it and/or modify it under % the terms of the GNU Lesser General Public License as published by the Free % Software Foundation, either version 3 of the License, or (at your option) % any later version. % % SPClibs is distributed in the hope that it will be useful, but WITHOUT ANY % WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS % FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. % % You should have received a copy of the GNU Lesser General Public License % along with this program. If not, see . % % @authors % (in alphabetical order) % @author Trach-Minh Tran % load relax.mat figure subplot(221) semilogy(jac_1(:,1),jac_1(:,2),gs_1(:,1),gs_1(:,2)) grid on legend('Jacobi', 'GS') xlabel('Iterations'); ylabel('Error') title('NX=32, P=1') subplot(222) semilogy(jac_3(:,1),jac_3(:,2),gs_3(:,1),gs_3(:,2)) grid on legend('Jacobi', 'GS') xlabel('Iterations'); ylabel('Error') title('NX=32, P=3') subplot(223) semilogy(jac_1(:,1),jac_1(:,4),gs_1(:,1),gs_1(:,4)) grid on legend('Jacobi', 'GS') xlabel('Iterations'); ylabel('Discretization error') title('NX=32, P=1') subplot(224) semilogy(jac_3(:,1),jac_3(:,4),gs_3(:,1),gs_3(:,4)) grid on legend('Jacobi', 'GS') xlabel('Iterations'); ylabel('Discretization error') title('NX=32, P=3')