Function f(Ki, Ri) for feistel added