function [location_map,nflag_map,nflag_sec,nflag,tw0_sec,nflag_01] = Wm_preprocess(half_sum,org_h)
new_DEh = 2 * org_h;
new_1DEh = new_DEh + 1;
new_2DEh = 2 * new_DEh;%嵌入零
new_21DEh = 2 * new_1DEh;%嵌入1
nflag = 0;%这个标识符表示的是个数
nflag_01 = ones(1,2);
nflag_sec = 0;
tw0_sec = 0;%第一类和第二类的共同标示符
if (half_sum <= 255) & (half_sum >= 128)  
    if (abs(new_DEh) <= 2*(255-half_sum)) & (abs(new_1DEh) <= 2*(255-half_sum))
        location_map = 0;    
        if (abs(new_2DEh) <= 2*(255-half_sum)) & (abs(new_2DEh + 1) <= 2*(255-half_sum))  & (abs(new_21DEh) <= 2*(255-half_sum)) & (abs(new_21DEh + 1) <= 2*(255-half_sum))%第三类的判断标准
            nflag_map = 1;
            tw0_sec = 0;
        else 
            nflag_map = - 1;
            tw0_sec = 1;
            if (abs(new_2DEh) <= 2*(255-half_sum)) & (abs(new_2DEh + 1) <= 2*(255-half_sum))
                nflag = nflag + 1;%
                nflag_01(1) = 0; 
                nflag_sec = 1;
            elseif (abs(new_21DEh) <= 2*(255-half_sum)) & (abs(new_21DEh + 1) <= 2*(255-half_sum))
                nflag = nflag + 1;
                nflag_01(2) = 0; 
                nflag_sec = 1;
            end
        end
    else
        location_map = 1; %表示第一类的符号
        nflag_map = 0;%标示三类的符号
        tw0_sec = 1;
    end
elseif (half_sum <= 127) & (half_sum >= 0)  
    if (abs(new_DEh) <= (2*half_sum+1)) & (abs(new_1DEh) <= (2*half_sum+1))
        location_map = 0;         
        if (abs(new_2DEh) <= (2*half_sum+1)) & (abs(new_2DEh + 1) <= (2*half_sum+1))  & (abs(new_21DEh) <= (2*half_sum+1)) & (abs(new_21DEh + 1) <= (2*half_sum+1))
            nflag_map = 1;
            tw0_sec = 0;
        else
            nflag_map = - 1;
            tw0_sec = 1;
            if (abs(new_2DEh) <= (2*half_sum+1)) & (abs(new_2DEh + 1) <= (2*half_sum+1))
                nflag = nflag + 1;
                nflag_01(1) = 0; %嵌入0满足而嵌入1不满足
                nflag_sec = 1;%跳变第二类的标示符
            elseif (abs(new_21DEh) <= (2*half_sum+1)) & (abs(new_21DEh + 1) <= (2*half_sum+1))
                nflag = nflag + 1;
                nflag_01(2) = 0;%嵌入1满足而嵌入0不满足
                nflag_sec = 1; 
             end
        end
    else
        location_map = 1;      
        nflag_map = 0;
        tw0_sec = 1;
    end
end