function ipm = getIndexim(ipn,ind1,ind2)

ipm = -1;
for n = 1 : length(ind1)
    if ind1(n) == ipn
        ipm = ind2(n);
        break
    end
end