%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
function rawIzero = genNORMeNOE(ATOMnorm,conditions,user)
        
if ~isempty(user.IzeroMethyl) && ~isempty(user.IzeroMethylenePseudo) && ~isempty(user.IzeroSingle)
   
       if ismember(ATOMnorm,      [conditions.methyl(1:8).grpNum])
            
            % if the final magnetization is on a methyl group, the cross
            % peak is a superposition of 3 pathways that are not scaled
            % properly by I(0)
            
                rawIzero = -abs(user.IzeroMethyl);
            
       elseif ismember(ATOMnorm,  [conditions.methyl(9:10).grpNum])
            
            % if the final magnetization is on val where QG1 and QG2 are
            % overlapped, on leu where QD1 and QD2 are overlapped, the
            % cross peak is a superposition of 6 pathways that are not
            % scaled properly by I(0)
            
                rawIzero = -abs(user.IzeroMethyl * 2);
            
       elseif ismember(ATOMnorm,  [conditions.methylene(1:13).grpNum])
            
            % if the final magnetization is on a methylene or aromatic
            % group (QA(gly); QB, QG; QD; QE; QG(ile); QD(asn); QE(gln);
            % QZ(lys, 3HZ has PKa 11); QH1(arg); QH2(arg); QD(phe,tyr);
            % QE(phe,tyr)), the cross peak is a superposition of 2 pathways
            % that are not scaled properly by I(0)
            
                rawIzero = -abs(user.IzeroMethylenePseudo);
            
       elseif ismember(ATOMnorm,  [conditions.methylene(14:15).grpNum])
            
            % if the final magnetization is on arg where QH1 and QH2 are
            % overlapped (although below PKa 12.5, second HH1 invisible),
            % or an aromatic group where QD and QE overlapped, the cross
            % peak is a superposition of 4 pathways that are not scaled
            % properly by I(0)
             
                rawIzero = -abs(user.IzeroMethylenePseudo * 2);            
       else
            
                rawIzero = -abs(user.IzeroSingle);        
       end   
end
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%        
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%        
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%       