


remove nucleation handling to solver structure THIS FUNCTION IS NO USER FUNCTION.


0001 function solverState = removeNucleation(solverState) 0002 % remove nucleation handling to solver structure 0003 % 0004 % THIS FUNCTION IS NO USER FUNCTION. 0005 0006 % The elk-library: convex geometry applied to crystallization modeling. 0007 % Copyright (C) 2012 Alexander Reinhold 0008 % 0009 % This program is free software: you can redistribute it and/or modify it 0010 % under the terms of the GNU General Public License as published by the 0011 % Free Software Foundation, either version 3 of the License, or (at your 0012 % option) any later version. 0013 % 0014 % This program is distributed in the hope that it will be useful, but 0015 % WITHOUT ANY WARRANTY; without even the implied warranty of 0016 % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 0017 % General Public License for more details. 0018 % 0019 % You should have received a copy of the GNU General Public License along 0020 % with this program. If not, see <http://www.gnu.org/licenses/>. 0021 0022 %% Task 0023 % it removes: 0024 % * nucleation boundary (second element) 0025 % it retains: 0026 % * the nucleation pivot as non-active 0027 0028 if solverState.flagNucleation 0029 0030 solverState.flagNucleation = 0; 0031 0032 % remove boundary 0033 solverState.hcMatrix(:, 2) = []; 0034 solverState.numberVector(2) = []; 0035 solverState.indexVector(2) = []; 0036 solverState.upVector(2) = []; 0037 0038 % retain nucleation pivot as non-active 0039 solverState.indexVector(1) = -1; 0040 0041 if solverState.flagDensity 0042 error('elk:pbeSolver:wrongInput', ['Sorry, nucleation AND tracking ' ... 0043 ' population densities is not yet properly supported']); 0044 end 0045 else 0046 error('elk:solver:generalError', ['nucleation phenomena shall be ' ... 0047 'removed while it is already removed']); 0048 end 0049 0050 end