reserve k,m,n for Nat,
  i1,i2,i3 for Integer,
  e for set;
reserve i,k,m,n,p,x,y for Nat;

theorem
  i2 > 0 & i3 >= 0 implies (i1 mod (i2*i3)) mod i3 = i1 mod i3
proof
  assume that
A1: i2 > 0 and
A2: i3 >= 0;
  per cases by A2;
  suppose
    i3 > 0;
    then i2*i3 <> 0 by A1,XCMPLX_1:6;
    then (i1 mod (i2*i3)) mod i3 = (i1 - (i1 div (i2*i3))*(i2*i3)) mod i3 by
INT_1:def 10
      .= (i1 + (-(i2*(i1 div i2*i3)))*i3) mod i3;
    hence thesis by NAT_D:61;
  end;
  suppose
A3: i3 = 0;
    then (i1 mod (i2*i3)) mod i3 = 0 by INT_1:def 10;
    hence thesis by A3,INT_1:def 10;
  end;
end;
