[STATEMENT]
lemma P2_case_l_new_1_gt_e0_rewrite:
  assumes "s < order \<G>"
  shows "(\<^bold>g [^] (r * ((order \<G> * order \<G> - s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + x) mod order \<G>)
            + (r * s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + xa) mod order \<G>),
              \<^bold>g [^] (r * \<alpha> * ((order \<G> * order \<G> - s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + x) mod order \<G>)
                + (r * s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + xa) mod order \<G> * \<alpha>) \<otimes>
                  \<^bold>g [^] (t * ((order \<G> * order \<G> - s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + x) mod order \<G>
                    + s * (nat ((fst (bezw t (order \<G>))) mod order \<G>))))) = (\<^bold>g [^] (r * x + xa), \<^bold>g [^] (r * \<alpha> * x + xa * \<alpha>) \<otimes> \<^bold>g [^] (t * x))"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (\<^bold>g [^] (r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G>), \<^bold>g [^] (r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha>) \<otimes> \<^bold>g [^] (t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))))) = (\<^bold>g [^] (r * x + xa), \<^bold>g [^] (r * \<alpha> * x + xa * \<alpha>) \<otimes> \<^bold>g [^] (t * x))
[PROOF STEP]
proof-
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. (\<^bold>g [^] (r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G>), \<^bold>g [^] (r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha>) \<otimes> \<^bold>g [^] (t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))))) = (\<^bold>g [^] (r * x + xa), \<^bold>g [^] (r * \<alpha> * x + xa * \<alpha>) \<otimes> \<^bold>g [^] (t * x))
[PROOF STEP]
have "\<^bold>g [^] ((r::nat) * ((order \<G> * order \<G> - s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + x) mod order \<G>)
                   + (r * s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + xa) mod order \<G>)
                                = \<^bold>g [^] (r * x + xa)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<^bold>g [^] (r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G>) = \<^bold>g [^] (r * x + xa)
[PROOF STEP]
proof(cases "r = 0")
[PROOF STATE]
proof (state)
goal (2 subgoals):
 1. r = 0 \<Longrightarrow> \<^bold>g [^] (r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G>) = \<^bold>g [^] (r * x + xa)
 2. r \<noteq> 0 \<Longrightarrow> \<^bold>g [^] (r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G>) = \<^bold>g [^] (r * x + xa)
[PROOF STEP]
case True
[PROOF STATE]
proof (state)
this:
r = 0

goal (2 subgoals):
 1. r = 0 \<Longrightarrow> \<^bold>g [^] (r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G>) = \<^bold>g [^] (r * x + xa)
 2. r \<noteq> 0 \<Longrightarrow> \<^bold>g [^] (r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G>) = \<^bold>g [^] (r * x + xa)
[PROOF STEP]
then
[PROOF STATE]
proof (chain)
picking this:
r = 0
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
using this:
r = 0

goal (1 subgoal):
 1. \<^bold>g [^] (r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G>) = \<^bold>g [^] (r * x + xa)
[PROOF STEP]
by (simp add: pow_generator_mod)
[PROOF STATE]
proof (state)
this:
\<^bold>g [^] (r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G>) = \<^bold>g [^] (r * x + xa)

goal (1 subgoal):
 1. r \<noteq> 0 \<Longrightarrow> \<^bold>g [^] (r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G>) = \<^bold>g [^] (r * x + xa)
[PROOF STEP]
next
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. r \<noteq> 0 \<Longrightarrow> \<^bold>g [^] (r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G>) = \<^bold>g [^] (r * x + xa)
[PROOF STEP]
case False
[PROOF STATE]
proof (state)
this:
r \<noteq> 0

goal (1 subgoal):
 1. r \<noteq> 0 \<Longrightarrow> \<^bold>g [^] (r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G>) = \<^bold>g [^] (r * x + xa)
[PROOF STEP]
have "[(r::nat) * ((order \<G> * order \<G> - s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + x) mod order \<G>)
                  + (r * s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + xa) mod order \<G> = r * x + xa] (mod order \<G>)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. [r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * x + xa] (mod order \<G>)
[PROOF STEP]
proof-
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. [r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * x + xa] (mod order \<G>)
[PROOF STEP]
have "[r * ((order \<G> * order \<G> - s * (nat (fst (bezw t (order \<G>))) mod order \<G>) + x) mod order \<G>)
                  + (r * s * nat (fst (bezw t (order \<G>))) + xa) mod order \<G>
                        =  (r * (((order \<G> * order \<G> - s * (nat (fst (bezw t (order \<G>))) mod order \<G>)) + x))
                              + (r * s * nat (fst (bezw t (order \<G>))) + xa))] (mod order \<G>)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. [r * ((order \<G> * order \<G> - s * (nat (fst (bezw t (order \<G>))) mod order \<G>) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>))) + xa) mod order \<G> = r * (order \<G> * order \<G> - s * (nat (fst (bezw t (order \<G>))) mod order \<G>) + x) + (r * s * nat (fst (bezw t (order \<G>))) + xa)] (mod order \<G>)
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. [r * ((order \<G> * order \<G> - s * (nat (fst (bezw t (order \<G>))) mod order \<G>) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>))) + xa) mod order \<G> = r * (order \<G> * order \<G> - s * (nat (fst (bezw t (order \<G>))) mod order \<G>) + x) + (r * s * nat (fst (bezw t (order \<G>))) + xa)] (mod order \<G>)
[PROOF STEP]
have "order \<G> \<noteq> 0"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. order \<G> \<noteq> 0
[PROOF STEP]
using order_gt_0
[PROOF STATE]
proof (prove)
using this:
0 < order \<G>

goal (1 subgoal):
 1. order \<G> \<noteq> 0
[PROOF STEP]
by simp
[PROOF STATE]
proof (state)
this:
order \<G> \<noteq> 0

goal (1 subgoal):
 1. [r * ((order \<G> * order \<G> - s * (nat (fst (bezw t (order \<G>))) mod order \<G>) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>))) + xa) mod order \<G> = r * (order \<G> * order \<G> - s * (nat (fst (bezw t (order \<G>))) mod order \<G>) + x) + (r * s * nat (fst (bezw t (order \<G>))) + xa)] (mod order \<G>)
[PROOF STEP]
then
[PROOF STATE]
proof (chain)
picking this:
order \<G> \<noteq> 0
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
using this:
order \<G> \<noteq> 0

goal (1 subgoal):
 1. [r * ((order \<G> * order \<G> - s * (nat (fst (bezw t (order \<G>))) mod order \<G>) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>))) + xa) mod order \<G> = r * (order \<G> * order \<G> - s * (nat (fst (bezw t (order \<G>))) mod order \<G>) + x) + (r * s * nat (fst (bezw t (order \<G>))) + xa)] (mod order \<G>)
[PROOF STEP]
using  cong_add cong_def mod_mult_right_eq
[PROOF STATE]
proof (prove)
using this:
order \<G> \<noteq> 0
\<lbrakk>[?b = ?c] (mod ?a); [?d = ?e] (mod ?a)\<rbrakk> \<Longrightarrow> [?b + ?d = ?c + ?e] (mod ?a)
[?b = ?c] (mod ?a) = (?b mod ?a = ?c mod ?a)
?a * (?b mod ?c) mod ?c = ?a * ?b mod ?c

goal (1 subgoal):
 1. [r * ((order \<G> * order \<G> - s * (nat (fst (bezw t (order \<G>))) mod order \<G>) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>))) + xa) mod order \<G> = r * (order \<G> * order \<G> - s * (nat (fst (bezw t (order \<G>))) mod order \<G>) + x) + (r * s * nat (fst (bezw t (order \<G>))) + xa)] (mod order \<G>)
[PROOF STEP]
by (smt mod_mod_trivial)
[PROOF STATE]
proof (state)
this:
[r * ((order \<G> * order \<G> - s * (nat (fst (bezw t (order \<G>))) mod order \<G>) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>))) + xa) mod order \<G> = r * (order \<G> * order \<G> - s * (nat (fst (bezw t (order \<G>))) mod order \<G>) + x) + (r * s * nat (fst (bezw t (order \<G>))) + xa)] (mod order \<G>)

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
[r * ((order \<G> * order \<G> - s * (nat (fst (bezw t (order \<G>))) mod order \<G>) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>))) + xa) mod order \<G> = r * (order \<G> * order \<G> - s * (nat (fst (bezw t (order \<G>))) mod order \<G>) + x) + (r * s * nat (fst (bezw t (order \<G>))) + xa)] (mod order \<G>)

goal (1 subgoal):
 1. [r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * x + xa] (mod order \<G>)
[PROOF STEP]
hence "[r * ((order \<G> * order \<G> - s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + x) mod order \<G>)
                  + (r * s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + xa) mod order \<G>
                        =  r * (order \<G> * order \<G> - s * (nat ((fst (bezw t (order \<G>))) mod order \<G>))) + r * x
                              + (r * s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + xa)] (mod order \<G>)"
[PROOF STATE]
proof (prove)
using this:
[r * ((order \<G> * order \<G> - s * (nat (fst (bezw t (order \<G>))) mod order \<G>) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>))) + xa) mod order \<G> = r * (order \<G> * order \<G> - s * (nat (fst (bezw t (order \<G>))) mod order \<G>) + x) + (r * s * nat (fst (bezw t (order \<G>))) + xa)] (mod order \<G>)

goal (1 subgoal):
 1. [r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) + r * x + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa)] (mod order \<G>)
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. [r * ((order \<G> * order \<G> - s * (nat (fst (bezw t (order \<G>))) mod order \<G>) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>))) + xa) mod order \<G> = r * (order \<G> * order \<G> - s * (nat (fst (bezw t (order \<G>))) mod order \<G>) + x) + (r * s * nat (fst (bezw t (order \<G>))) + xa)] (mod order \<G>) \<Longrightarrow> [r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) + r * x + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa)] (mod order \<G>)
[PROOF STEP]
have "[r * ((order \<G> * order \<G> - s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + x) mod order \<G>)
                = r * (order \<G> * order \<G> - s * (nat ((fst (bezw t (order \<G>))) mod order \<G>))) + r * x] (mod order \<G>)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. [r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) = r * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) + r * x] (mod order \<G>)
[PROOF STEP]
by (simp add: cong_def distrib_left mod_mult_right_eq)
[PROOF STATE]
proof (state)
this:
[r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) = r * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) + r * x] (mod order \<G>)

goal (1 subgoal):
 1. [r * ((order \<G> * order \<G> - s * (nat (fst (bezw t (order \<G>))) mod order \<G>) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>))) + xa) mod order \<G> = r * (order \<G> * order \<G> - s * (nat (fst (bezw t (order \<G>))) mod order \<G>) + x) + (r * s * nat (fst (bezw t (order \<G>))) + xa)] (mod order \<G>) \<Longrightarrow> [r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) + r * x + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa)] (mod order \<G>)
[PROOF STEP]
then
[PROOF STATE]
proof (chain)
picking this:
[r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) = r * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) + r * x] (mod order \<G>)
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
using this:
[r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) = r * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) + r * x] (mod order \<G>)

goal (1 subgoal):
 1. [r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) + r * x + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa)] (mod order \<G>)
[PROOF STEP]
using assms cong_add gr_implies_not0
[PROOF STATE]
proof (prove)
using this:
[r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) = r * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) + r * x] (mod order \<G>)
s < order \<G>
\<lbrakk>[?b = ?c] (mod ?a); [?d = ?e] (mod ?a)\<rbrakk> \<Longrightarrow> [?b + ?d = ?c + ?e] (mod ?a)
?m < ?n \<Longrightarrow> ?n \<noteq> 0

goal (1 subgoal):
 1. [r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) + r * x + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa)] (mod order \<G>)
[PROOF STEP]
by fastforce
[PROOF STATE]
proof (state)
this:
[r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) + r * x + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa)] (mod order \<G>)

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
[r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) + r * x + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa)] (mod order \<G>)

goal (1 subgoal):
 1. [r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * x + xa] (mod order \<G>)
[PROOF STEP]
hence "[r * ((order \<G> * order \<G> - s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + x) mod order \<G>)
                    + (r * s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + xa) mod order \<G>
                          =  r * order \<G> * order \<G> - r * s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + r * x
                                + r * s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + xa] (mod order \<G>)"
[PROOF STATE]
proof (prove)
using this:
[r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) + r * x + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa)] (mod order \<G>)

goal (1 subgoal):
 1. [r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * order \<G> * order \<G> - r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + r * x + r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa] (mod order \<G>)
[PROOF STEP]
by (simp add: ab_semigroup_mult_class.mult_ac(1) right_diff_distrib' add.assoc)
[PROOF STATE]
proof (state)
this:
[r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * order \<G> * order \<G> - r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + r * x + r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa] (mod order \<G>)

goal (1 subgoal):
 1. [r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * x + xa] (mod order \<G>)
[PROOF STEP]
hence "[r * ((order \<G> * order \<G> - s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + x) mod order \<G>)
                    + (r * s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + xa) mod order \<G>
                          =  r * order \<G> * order \<G> + r * x + xa] (mod order \<G>)"
[PROOF STATE]
proof (prove)
using this:
[r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * order \<G> * order \<G> - r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + r * x + r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa] (mod order \<G>)

goal (1 subgoal):
 1. [r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * order \<G> * order \<G> + r * x + xa] (mod order \<G>)
[PROOF STEP]
proof-
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. [r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * order \<G> * order \<G> - r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + r * x + r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa] (mod order \<G>) \<Longrightarrow> [r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * order \<G> * order \<G> + r * x + xa] (mod order \<G>)
[PROOF STEP]
have "r * order \<G> * order \<G> - r * s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) > 0"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. 0 < r * order \<G> * order \<G> - r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))
[PROOF STEP]
proof-
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. 0 < r * order \<G> * order \<G> - r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))
[PROOF STEP]
have "order \<G> * order \<G> > s * (nat ((fst (bezw t (order \<G>))) mod order \<G>))"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) < order \<G> * order \<G>
[PROOF STEP]
proof-
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) < order \<G> * order \<G>
[PROOF STEP]
have "(nat ((fst (bezw t (order \<G>))) mod order \<G>)) \<le> order \<G>"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. nat (fst (bezw t (order \<G>)) mod int (order \<G>)) \<le> order \<G>
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. nat (fst (bezw t (order \<G>)) mod int (order \<G>)) \<le> order \<G>
[PROOF STEP]
have "\<forall>x0 x1. ((x0::int) mod x1 < x1) = (\<not> x1 + - 1 * (x0 mod x1) \<le> 0)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<forall>x0 x1. (x0 mod x1 < x1) = (\<not> x1 + - 1 * (x0 mod x1) \<le> 0)
[PROOF STEP]
by linarith
[PROOF STATE]
proof (state)
this:
\<forall>x0 x1. (x0 mod x1 < x1) = (\<not> x1 + - 1 * (x0 mod x1) \<le> 0)

goal (1 subgoal):
 1. nat (fst (bezw t (order \<G>)) mod int (order \<G>)) \<le> order \<G>
[PROOF STEP]
then
[PROOF STATE]
proof (chain)
picking this:
\<forall>x0 x1. (x0 mod x1 < x1) = (\<not> x1 + - 1 * (x0 mod x1) \<le> 0)
[PROOF STEP]
have "\<not> int (order \<G>) + - 1 * (fst (bezw t (order \<G>)) mod int (order \<G>)) \<le> 0"
[PROOF STATE]
proof (prove)
using this:
\<forall>x0 x1. (x0 mod x1 < x1) = (\<not> x1 + - 1 * (x0 mod x1) \<le> 0)

goal (1 subgoal):
 1. \<not> int (order \<G>) + - 1 * (fst (bezw t (order \<G>)) mod int (order \<G>)) \<le> 0
[PROOF STEP]
using of_nat_0_less_iff order_gt_0
[PROOF STATE]
proof (prove)
using this:
\<forall>x0 x1. (x0 mod x1 < x1) = (\<not> x1 + - 1 * (x0 mod x1) \<le> 0)
((0::?'a) < of_nat ?n) = (0 < ?n)
0 < order \<G>

goal (1 subgoal):
 1. \<not> int (order \<G>) + - 1 * (fst (bezw t (order \<G>)) mod int (order \<G>)) \<le> 0
[PROOF STEP]
by fastforce
[PROOF STATE]
proof (state)
this:
\<not> int (order \<G>) + - 1 * (fst (bezw t (order \<G>)) mod int (order \<G>)) \<le> 0

goal (1 subgoal):
 1. nat (fst (bezw t (order \<G>)) mod int (order \<G>)) \<le> order \<G>
[PROOF STEP]
then
[PROOF STATE]
proof (chain)
picking this:
\<not> int (order \<G>) + - 1 * (fst (bezw t (order \<G>)) mod int (order \<G>)) \<le> 0
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
using this:
\<not> int (order \<G>) + - 1 * (fst (bezw t (order \<G>)) mod int (order \<G>)) \<le> 0

goal (1 subgoal):
 1. nat (fst (bezw t (order \<G>)) mod int (order \<G>)) \<le> order \<G>
[PROOF STEP]
by linarith
[PROOF STATE]
proof (state)
this:
nat (fst (bezw t (order \<G>)) mod int (order \<G>)) \<le> order \<G>

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
nat (fst (bezw t (order \<G>)) mod int (order \<G>)) \<le> order \<G>

goal (1 subgoal):
 1. s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) < order \<G> * order \<G>
[PROOF STEP]
thus ?thesis
[PROOF STATE]
proof (prove)
using this:
nat (fst (bezw t (order \<G>)) mod int (order \<G>)) \<le> order \<G>

goal (1 subgoal):
 1. s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) < order \<G> * order \<G>
[PROOF STEP]
using assms
[PROOF STATE]
proof (prove)
using this:
nat (fst (bezw t (order \<G>)) mod int (order \<G>)) \<le> order \<G>
s < order \<G>

goal (1 subgoal):
 1. s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) < order \<G> * order \<G>
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. \<lbrakk>nat (fst (bezw t (order \<G>)) mod int (order \<G>)) \<le> order \<G>; s < order \<G>\<rbrakk> \<Longrightarrow> s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) < order \<G> * order \<G>
[PROOF STEP]
have "\<forall>n na. \<not> n \<le> na \<or> \<not> na * order \<G> < n * nat (fst (bezw t (order \<G>)) mod int (order \<G>))"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<forall>n na. \<not> n \<le> na \<or> \<not> na * order \<G> < n * nat (fst (bezw t (order \<G>)) mod int (order \<G>))
[PROOF STEP]
by (meson \<open>nat (fst (bezw (t::nat) (order \<G>)) mod int (order \<G>)) \<le> order \<G>\<close> mult_le_mono not_le)
[PROOF STATE]
proof (state)
this:
\<forall>n na. \<not> n \<le> na \<or> \<not> na * order \<G> < n * nat (fst (bezw t (order \<G>)) mod int (order \<G>))

goal (1 subgoal):
 1. \<lbrakk>nat (fst (bezw t (order \<G>)) mod int (order \<G>)) \<le> order \<G>; s < order \<G>\<rbrakk> \<Longrightarrow> s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) < order \<G> * order \<G>
[PROOF STEP]
then
[PROOF STATE]
proof (chain)
picking this:
\<forall>n na. \<not> n \<le> na \<or> \<not> na * order \<G> < n * nat (fst (bezw t (order \<G>)) mod int (order \<G>))
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
using this:
\<forall>n na. \<not> n \<le> na \<or> \<not> na * order \<G> < n * nat (fst (bezw t (order \<G>)) mod int (order \<G>))

goal (1 subgoal):
 1. s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) < order \<G> * order \<G>
[PROOF STEP]
by(metis  (no_types, opaque_lifting) \<open>(s::nat) < order \<G>\<close> mult_less_cancel2 nat_less_le not_le not_less_zero)
[PROOF STATE]
proof (state)
this:
s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) < order \<G> * order \<G>

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) < order \<G> * order \<G>

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) < order \<G> * order \<G>

goal (1 subgoal):
 1. 0 < r * order \<G> * order \<G> - r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))
[PROOF STEP]
thus ?thesis
[PROOF STATE]
proof (prove)
using this:
s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) < order \<G> * order \<G>

goal (1 subgoal):
 1. 0 < r * order \<G> * order \<G> - r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))
[PROOF STEP]
using False
[PROOF STATE]
proof (prove)
using this:
s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) < order \<G> * order \<G>
r \<noteq> 0

goal (1 subgoal):
 1. 0 < r * order \<G> * order \<G> - r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))
[PROOF STEP]
by auto
[PROOF STATE]
proof (state)
this:
0 < r * order \<G> * order \<G> - r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
0 < r * order \<G> * order \<G> - r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))

goal (1 subgoal):
 1. [r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * order \<G> * order \<G> - r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + r * x + r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa] (mod order \<G>) \<Longrightarrow> [r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * order \<G> * order \<G> + r * x + xa] (mod order \<G>)
[PROOF STEP]
thus ?thesis
[PROOF STATE]
proof (prove)
using this:
0 < r * order \<G> * order \<G> - r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))

goal (1 subgoal):
 1. [r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * order \<G> * order \<G> + r * x + xa] (mod order \<G>)
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. 0 < r * order \<G> * order \<G> - r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) \<Longrightarrow> [r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * order \<G> * order \<G> + r * x + xa] (mod order \<G>)
[PROOF STEP]
have "r * order \<G> * order \<G> + r * x + xa = r * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) + r * x"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. r * order \<G> * order \<G> + r * x + xa = r * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) + r * x
[PROOF STEP]
using \<open>(0::nat) < (r::nat) * order \<G> * order \<G> - r * (s::nat) * nat (fst (bezw (t::nat) (order \<G>)) mod int (order \<G>))\<close> diff_mult_distrib2
[PROOF STATE]
proof (prove)
using this:
0 < r * order \<G> * order \<G> - r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))
?k * (?m - ?n) = ?k * ?m - ?k * ?n

goal (1 subgoal):
 1. r * order \<G> * order \<G> + r * x + xa = r * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) + r * x
[PROOF STEP]
by force
[PROOF STATE]
proof (state)
this:
r * order \<G> * order \<G> + r * x + xa = r * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) + r * x

goal (1 subgoal):
 1. 0 < r * order \<G> * order \<G> - r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) \<Longrightarrow> [r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * order \<G> * order \<G> + r * x + xa] (mod order \<G>)
[PROOF STEP]
then
[PROOF STATE]
proof (chain)
picking this:
r * order \<G> * order \<G> + r * x + xa = r * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) + r * x
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
using this:
r * order \<G> * order \<G> + r * x + xa = r * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) + r * x

goal (1 subgoal):
 1. [r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * order \<G> * order \<G> + r * x + xa] (mod order \<G>)
[PROOF STEP]
by (metis (no_types) \<open>[(r::nat) * ((order \<G> * order \<G> - (s::nat) * nat (fst (bezw (t::nat) (order \<G>)) mod int (order \<G>)) + (x::nat)) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + (xa::nat)) mod order \<G> = r * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) + r * x + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa)] (mod order \<G>)\<close> semiring_normalization_rules(23))
[PROOF STATE]
proof (state)
this:
[r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * order \<G> * order \<G> + r * x + xa] (mod order \<G>)

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
[r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * order \<G> * order \<G> + r * x + xa] (mod order \<G>)

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
[r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * order \<G> * order \<G> + r * x + xa] (mod order \<G>)

goal (1 subgoal):
 1. [r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * x + xa] (mod order \<G>)
[PROOF STEP]
hence "[r * ((order \<G> * order \<G> - s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + x) mod order \<G>)
                    + (r * s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + xa) mod order \<G>
                          = r * x + xa] (mod order \<G>)"
[PROOF STATE]
proof (prove)
using this:
[r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * order \<G> * order \<G> + r * x + xa] (mod order \<G>)

goal (1 subgoal):
 1. [r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * x + xa] (mod order \<G>)
[PROOF STEP]
by (metis (no_types, lifting) mod_mult_self4 add.assoc mult.commute cong_def)
[PROOF STATE]
proof (state)
this:
[r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * x + xa] (mod order \<G>)

goal (1 subgoal):
 1. [r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * x + xa] (mod order \<G>)
[PROOF STEP]
thus ?thesis
[PROOF STATE]
proof (prove)
using this:
[r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * x + xa] (mod order \<G>)

goal (1 subgoal):
 1. [r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * x + xa] (mod order \<G>)
[PROOF STEP]
by blast
[PROOF STATE]
proof (state)
this:
[r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * x + xa] (mod order \<G>)

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
[r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * x + xa] (mod order \<G>)

goal (1 subgoal):
 1. r \<noteq> 0 \<Longrightarrow> \<^bold>g [^] (r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G>) = \<^bold>g [^] (r * x + xa)
[PROOF STEP]
then
[PROOF STATE]
proof (chain)
picking this:
[r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * x + xa] (mod order \<G>)
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
using this:
[r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * x + xa] (mod order \<G>)

goal (1 subgoal):
 1. \<^bold>g [^] (r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G>) = \<^bold>g [^] (r * x + xa)
[PROOF STEP]
using finite_group pow_generator_eq_iff_cong
[PROOF STATE]
proof (prove)
using this:
[r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> = r * x + xa] (mod order \<G>)
finite (carrier \<G>)
finite (carrier \<G>) \<Longrightarrow> (\<^bold>g [^] ?x = \<^bold>g [^] ?y) = [?x = ?y] (mod order \<G>)

goal (1 subgoal):
 1. \<^bold>g [^] (r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G>) = \<^bold>g [^] (r * x + xa)
[PROOF STEP]
by blast
[PROOF STATE]
proof (state)
this:
\<^bold>g [^] (r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G>) = \<^bold>g [^] (r * x + xa)

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
\<^bold>g [^] (r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G>) = \<^bold>g [^] (r * x + xa)

goal (1 subgoal):
 1. (\<^bold>g [^] (r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G>), \<^bold>g [^] (r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha>) \<otimes> \<^bold>g [^] (t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))))) = (\<^bold>g [^] (r * x + xa), \<^bold>g [^] (r * \<alpha> * x + xa * \<alpha>) \<otimes> \<^bold>g [^] (t * x))
[PROOF STEP]
moreover
[PROOF STATE]
proof (state)
this:
\<^bold>g [^] (r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G>) = \<^bold>g [^] (r * x + xa)

goal (1 subgoal):
 1. (\<^bold>g [^] (r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G>), \<^bold>g [^] (r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha>) \<otimes> \<^bold>g [^] (t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))))) = (\<^bold>g [^] (r * x + xa), \<^bold>g [^] (r * \<alpha> * x + xa * \<alpha>) \<otimes> \<^bold>g [^] (t * x))
[PROOF STEP]
have "\<^bold>g [^] (r * \<alpha> * ((order \<G> * order \<G> - s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + x) mod order \<G>)
                      + (r * s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + xa) mod order \<G> * \<alpha>) \<otimes>
                             \<^bold>g [^] (t * ((order \<G> * order \<G> - s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + x) mod order \<G>
                                  + s * (nat ((fst (bezw t (order \<G>))) mod order \<G>))))
                                      =  \<^bold>g [^] (r * \<alpha> * x + xa * \<alpha>) \<otimes> \<^bold>g [^] (t * x)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<^bold>g [^] (r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha>) \<otimes> \<^bold>g [^] (t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)))) = \<^bold>g [^] (r * \<alpha> * x + xa * \<alpha>) \<otimes> \<^bold>g [^] (t * x)
[PROOF STEP]
proof-
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. \<^bold>g [^] (r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha>) \<otimes> \<^bold>g [^] (t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)))) = \<^bold>g [^] (r * \<alpha> * x + xa * \<alpha>) \<otimes> \<^bold>g [^] (t * x)
[PROOF STEP]
have "\<^bold>g [^] (r * \<alpha> * ((order \<G> * order \<G> - s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + x) mod order \<G>) + (r * s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + xa) mod order \<G> * \<alpha>)
              = \<^bold>g [^] (r * \<alpha> * x + xa * \<alpha>)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<^bold>g [^] (r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha>) = \<^bold>g [^] (r * \<alpha> * x + xa * \<alpha>)
[PROOF STEP]
proof-
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. \<^bold>g [^] (r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha>) = \<^bold>g [^] (r * \<alpha> * x + xa * \<alpha>)
[PROOF STEP]
have "[r * \<alpha> * ((order \<G> * order \<G> - s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + x) mod order \<G>) + (r * s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + xa) mod order \<G> * \<alpha>
                  = r * \<alpha> * x + xa * \<alpha>] (mod order \<G>)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. [r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * x + xa * \<alpha>] (mod order \<G>)
[PROOF STEP]
proof-
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. [r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * x + xa * \<alpha>] (mod order \<G>)
[PROOF STEP]
have "[r * \<alpha> * ((order \<G> * order \<G> - s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + x) mod order \<G>) + (r * s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + xa) mod order \<G> * \<alpha>
                  = r * \<alpha> * ((order \<G> * order \<G> - s * (nat ((fst (bezw t (order \<G>))) mod order \<G>))) + x) + (r * s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + xa) * \<alpha>] (mod order \<G>)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. [r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) * \<alpha>] (mod order \<G>)
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. [r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) * \<alpha>] (mod order \<G>)
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. [r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) * \<alpha>] (mod order \<G>)
[PROOF STEP]
by (meson cong_def mod_add_cong mod_mult_left_eq mod_mult_right_eq)
[PROOF STATE]
proof (state)
this:
[r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) * \<alpha>] (mod order \<G>)

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
[r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) * \<alpha>] (mod order \<G>)

goal (1 subgoal):
 1. [r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * x + xa * \<alpha>] (mod order \<G>)
[PROOF STEP]
hence mod_eq: "[r * \<alpha> * ((order \<G> * order \<G> - s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + x) mod order \<G>) + (r * s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + xa) mod order \<G> * \<alpha>
                  = r * \<alpha> * (order \<G> * order \<G> - s * (nat ((fst (bezw t (order \<G>))) mod order \<G>))) + r * \<alpha> * x + r * s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) * \<alpha> + xa * \<alpha>] (mod order \<G>)"
[PROOF STATE]
proof (prove)
using this:
[r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) * \<alpha>] (mod order \<G>)

goal (1 subgoal):
 1. [r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) + r * \<alpha> * x + r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) * \<alpha> + xa * \<alpha>] (mod order \<G>)
[PROOF STEP]
by (simp add: distrib_left distrib_right add.assoc)
[PROOF STATE]
proof (state)
this:
[r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) + r * \<alpha> * x + r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) * \<alpha> + xa * \<alpha>] (mod order \<G>)

goal (1 subgoal):
 1. [r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * x + xa * \<alpha>] (mod order \<G>)
[PROOF STEP]
hence mod_eq': "[r * \<alpha> * ((order \<G> * order \<G> - s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + x) mod order \<G>) + (r * s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + xa) mod order \<G> * \<alpha>
                  = r * \<alpha> * order \<G> * order \<G> - r * \<alpha> * s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + r * \<alpha> * x + r * \<alpha> * s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + xa * \<alpha>] (mod order \<G>)"
[PROOF STATE]
proof (prove)
using this:
[r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) + r * \<alpha> * x + r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) * \<alpha> + xa * \<alpha>] (mod order \<G>)

goal (1 subgoal):
 1. [r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * order \<G> * order \<G> - r * \<alpha> * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + r * \<alpha> * x + r * \<alpha> * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa * \<alpha>] (mod order \<G>)
[PROOF STEP]
by (simp add: semiring_normalization_rules(16) diff_mult_distrib2 semiring_normalization_rules(18))
[PROOF STATE]
proof (state)
this:
[r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * order \<G> * order \<G> - r * \<alpha> * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + r * \<alpha> * x + r * \<alpha> * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa * \<alpha>] (mod order \<G>)

goal (1 subgoal):
 1. [r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * x + xa * \<alpha>] (mod order \<G>)
[PROOF STEP]
hence "[r * \<alpha> * ((order \<G> * order \<G> - s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + x) mod order \<G>) + (r * s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + xa) mod order \<G> * \<alpha>
                  = r * \<alpha> * order \<G> * order \<G> + r * \<alpha> * x + xa * \<alpha>] (mod order \<G>)"
[PROOF STATE]
proof (prove)
using this:
[r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * order \<G> * order \<G> - r * \<alpha> * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + r * \<alpha> * x + r * \<alpha> * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa * \<alpha>] (mod order \<G>)

goal (1 subgoal):
 1. [r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * order \<G> * order \<G> + r * \<alpha> * x + xa * \<alpha>] (mod order \<G>)
[PROOF STEP]
proof(cases "r * \<alpha> = 0")
[PROOF STATE]
proof (state)
goal (2 subgoals):
 1. \<lbrakk>[r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * order \<G> * order \<G> - r * \<alpha> * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + r * \<alpha> * x + r * \<alpha> * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa * \<alpha>] (mod order \<G>); r * \<alpha> = 0\<rbrakk> \<Longrightarrow> [r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * order \<G> * order \<G> + r * \<alpha> * x + xa * \<alpha>] (mod order \<G>)
 2. \<lbrakk>[r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * order \<G> * order \<G> - r * \<alpha> * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + r * \<alpha> * x + r * \<alpha> * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa * \<alpha>] (mod order \<G>); r * \<alpha> \<noteq> 0\<rbrakk> \<Longrightarrow> [r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * order \<G> * order \<G> + r * \<alpha> * x + xa * \<alpha>] (mod order \<G>)
[PROOF STEP]
case True
[PROOF STATE]
proof (state)
this:
r * \<alpha> = 0

goal (2 subgoals):
 1. \<lbrakk>[r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * order \<G> * order \<G> - r * \<alpha> * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + r * \<alpha> * x + r * \<alpha> * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa * \<alpha>] (mod order \<G>); r * \<alpha> = 0\<rbrakk> \<Longrightarrow> [r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * order \<G> * order \<G> + r * \<alpha> * x + xa * \<alpha>] (mod order \<G>)
 2. \<lbrakk>[r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * order \<G> * order \<G> - r * \<alpha> * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + r * \<alpha> * x + r * \<alpha> * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa * \<alpha>] (mod order \<G>); r * \<alpha> \<noteq> 0\<rbrakk> \<Longrightarrow> [r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * order \<G> * order \<G> + r * \<alpha> * x + xa * \<alpha>] (mod order \<G>)
[PROOF STEP]
then
[PROOF STATE]
proof (chain)
picking this:
r * \<alpha> = 0
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
using this:
r * \<alpha> = 0

goal (1 subgoal):
 1. [r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * order \<G> * order \<G> + r * \<alpha> * x + xa * \<alpha>] (mod order \<G>)
[PROOF STEP]
by (metis mod_eq' diff_zero mult_0 plus_nat.add_0)
[PROOF STATE]
proof (state)
this:
[r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * order \<G> * order \<G> + r * \<alpha> * x + xa * \<alpha>] (mod order \<G>)

goal (1 subgoal):
 1. \<lbrakk>[r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * order \<G> * order \<G> - r * \<alpha> * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + r * \<alpha> * x + r * \<alpha> * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa * \<alpha>] (mod order \<G>); r * \<alpha> \<noteq> 0\<rbrakk> \<Longrightarrow> [r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * order \<G> * order \<G> + r * \<alpha> * x + xa * \<alpha>] (mod order \<G>)
[PROOF STEP]
next
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. \<lbrakk>[r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * order \<G> * order \<G> - r * \<alpha> * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + r * \<alpha> * x + r * \<alpha> * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa * \<alpha>] (mod order \<G>); r * \<alpha> \<noteq> 0\<rbrakk> \<Longrightarrow> [r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * order \<G> * order \<G> + r * \<alpha> * x + xa * \<alpha>] (mod order \<G>)
[PROOF STEP]
case False
[PROOF STATE]
proof (state)
this:
r * \<alpha> \<noteq> 0

goal (1 subgoal):
 1. \<lbrakk>[r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * order \<G> * order \<G> - r * \<alpha> * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + r * \<alpha> * x + r * \<alpha> * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa * \<alpha>] (mod order \<G>); r * \<alpha> \<noteq> 0\<rbrakk> \<Longrightarrow> [r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * order \<G> * order \<G> + r * \<alpha> * x + xa * \<alpha>] (mod order \<G>)
[PROOF STEP]
hence bound: " r * \<alpha> * order \<G> * order \<G> - r * \<alpha> * s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) > 0"
[PROOF STATE]
proof (prove)
using this:
r * \<alpha> \<noteq> 0

goal (1 subgoal):
 1. 0 < r * \<alpha> * order \<G> * order \<G> - r * \<alpha> * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))
[PROOF STEP]
proof-
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. r * \<alpha> \<noteq> 0 \<Longrightarrow> 0 < r * \<alpha> * order \<G> * order \<G> - r * \<alpha> * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))
[PROOF STEP]
have "s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) < order \<G> * order \<G>"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) < order \<G> * order \<G>
[PROOF STEP]
using assms
[PROOF STATE]
proof (prove)
using this:
s < order \<G>

goal (1 subgoal):
 1. s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) < order \<G> * order \<G>
[PROOF STEP]
by (simp add: mult_strict_mono nat_less_iff)
[PROOF STATE]
proof (state)
this:
s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) < order \<G> * order \<G>

goal (1 subgoal):
 1. r * \<alpha> \<noteq> 0 \<Longrightarrow> 0 < r * \<alpha> * order \<G> * order \<G> - r * \<alpha> * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))
[PROOF STEP]
thus ?thesis
[PROOF STATE]
proof (prove)
using this:
s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) < order \<G> * order \<G>

goal (1 subgoal):
 1. 0 < r * \<alpha> * order \<G> * order \<G> - r * \<alpha> * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))
[PROOF STEP]
using False
[PROOF STATE]
proof (prove)
using this:
s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) < order \<G> * order \<G>
r * \<alpha> \<noteq> 0

goal (1 subgoal):
 1. 0 < r * \<alpha> * order \<G> * order \<G> - r * \<alpha> * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))
[PROOF STEP]
by auto
[PROOF STATE]
proof (state)
this:
0 < r * \<alpha> * order \<G> * order \<G> - r * \<alpha> * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
0 < r * \<alpha> * order \<G> * order \<G> - r * \<alpha> * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))

goal (1 subgoal):
 1. \<lbrakk>[r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * order \<G> * order \<G> - r * \<alpha> * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + r * \<alpha> * x + r * \<alpha> * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa * \<alpha>] (mod order \<G>); r * \<alpha> \<noteq> 0\<rbrakk> \<Longrightarrow> [r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * order \<G> * order \<G> + r * \<alpha> * x + xa * \<alpha>] (mod order \<G>)
[PROOF STEP]
thus ?thesis
[PROOF STATE]
proof (prove)
using this:
0 < r * \<alpha> * order \<G> * order \<G> - r * \<alpha> * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))

goal (1 subgoal):
 1. [r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * order \<G> * order \<G> + r * \<alpha> * x + xa * \<alpha>] (mod order \<G>)
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. 0 < r * \<alpha> * order \<G> * order \<G> - r * \<alpha> * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) \<Longrightarrow> [r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * order \<G> * order \<G> + r * \<alpha> * x + xa * \<alpha>] (mod order \<G>)
[PROOF STEP]
have "r * \<alpha> * order \<G> * order \<G> = r * \<alpha> * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)))
                                                      + r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) * \<alpha>"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. r * \<alpha> * order \<G> * order \<G> = r * \<alpha> * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) + r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) * \<alpha>
[PROOF STEP]
using bound diff_mult_distrib2
[PROOF STATE]
proof (prove)
using this:
0 < r * \<alpha> * order \<G> * order \<G> - r * \<alpha> * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))
?k * (?m - ?n) = ?k * ?m - ?k * ?n

goal (1 subgoal):
 1. r * \<alpha> * order \<G> * order \<G> = r * \<alpha> * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) + r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) * \<alpha>
[PROOF STEP]
by force
[PROOF STATE]
proof (state)
this:
r * \<alpha> * order \<G> * order \<G> = r * \<alpha> * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) + r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) * \<alpha>

goal (1 subgoal):
 1. 0 < r * \<alpha> * order \<G> * order \<G> - r * \<alpha> * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) \<Longrightarrow> [r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * order \<G> * order \<G> + r * \<alpha> * x + xa * \<alpha>] (mod order \<G>)
[PROOF STEP]
then
[PROOF STATE]
proof (chain)
picking this:
r * \<alpha> * order \<G> * order \<G> = r * \<alpha> * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) + r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) * \<alpha>
[PROOF STEP]
have "r * \<alpha> * order \<G> * order \<G> + r * \<alpha> * x = r * \<alpha> * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)))
                                                                  + r * \<alpha> * x + r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) * \<alpha>"
[PROOF STATE]
proof (prove)
using this:
r * \<alpha> * order \<G> * order \<G> = r * \<alpha> * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) + r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) * \<alpha>

goal (1 subgoal):
 1. r * \<alpha> * order \<G> * order \<G> + r * \<alpha> * x = r * \<alpha> * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) + r * \<alpha> * x + r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) * \<alpha>
[PROOF STEP]
by presburger
[PROOF STATE]
proof (state)
this:
r * \<alpha> * order \<G> * order \<G> + r * \<alpha> * x = r * \<alpha> * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) + r * \<alpha> * x + r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) * \<alpha>

goal (1 subgoal):
 1. 0 < r * \<alpha> * order \<G> * order \<G> - r * \<alpha> * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) \<Longrightarrow> [r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * order \<G> * order \<G> + r * \<alpha> * x + xa * \<alpha>] (mod order \<G>)
[PROOF STEP]
then
[PROOF STATE]
proof (chain)
picking this:
r * \<alpha> * order \<G> * order \<G> + r * \<alpha> * x = r * \<alpha> * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) + r * \<alpha> * x + r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) * \<alpha>
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
using this:
r * \<alpha> * order \<G> * order \<G> + r * \<alpha> * x = r * \<alpha> * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) + r * \<alpha> * x + r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) * \<alpha>

goal (1 subgoal):
 1. [r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * order \<G> * order \<G> + r * \<alpha> * x + xa * \<alpha>] (mod order \<G>)
[PROOF STEP]
using mod_eq
[PROOF STATE]
proof (prove)
using this:
r * \<alpha> * order \<G> * order \<G> + r * \<alpha> * x = r * \<alpha> * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) + r * \<alpha> * x + r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) * \<alpha>
[r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) + r * \<alpha> * x + r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) * \<alpha> + xa * \<alpha>] (mod order \<G>)

goal (1 subgoal):
 1. [r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * order \<G> * order \<G> + r * \<alpha> * x + xa * \<alpha>] (mod order \<G>)
[PROOF STEP]
by presburger
[PROOF STATE]
proof (state)
this:
[r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * order \<G> * order \<G> + r * \<alpha> * x + xa * \<alpha>] (mod order \<G>)

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
[r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * order \<G> * order \<G> + r * \<alpha> * x + xa * \<alpha>] (mod order \<G>)

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
[r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * order \<G> * order \<G> + r * \<alpha> * x + xa * \<alpha>] (mod order \<G>)

goal (1 subgoal):
 1. [r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * x + xa * \<alpha>] (mod order \<G>)
[PROOF STEP]
thus ?thesis
[PROOF STATE]
proof (prove)
using this:
[r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * order \<G> * order \<G> + r * \<alpha> * x + xa * \<alpha>] (mod order \<G>)

goal (1 subgoal):
 1. [r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * x + xa * \<alpha>] (mod order \<G>)
[PROOF STEP]
by (metis (mono_tags, lifting) add.assoc cong_def mod_mult_self3)
[PROOF STATE]
proof (state)
this:
[r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * x + xa * \<alpha>] (mod order \<G>)

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
[r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * x + xa * \<alpha>] (mod order \<G>)

goal (1 subgoal):
 1. \<^bold>g [^] (r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha>) = \<^bold>g [^] (r * \<alpha> * x + xa * \<alpha>)
[PROOF STEP]
then
[PROOF STATE]
proof (chain)
picking this:
[r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * x + xa * \<alpha>] (mod order \<G>)
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
using this:
[r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * x + xa * \<alpha>] (mod order \<G>)

goal (1 subgoal):
 1. \<^bold>g [^] (r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha>) = \<^bold>g [^] (r * \<alpha> * x + xa * \<alpha>)
[PROOF STEP]
using finite_group pow_generator_eq_iff_cong
[PROOF STATE]
proof (prove)
using this:
[r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha> = r * \<alpha> * x + xa * \<alpha>] (mod order \<G>)
finite (carrier \<G>)
finite (carrier \<G>) \<Longrightarrow> (\<^bold>g [^] ?x = \<^bold>g [^] ?y) = [?x = ?y] (mod order \<G>)

goal (1 subgoal):
 1. \<^bold>g [^] (r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha>) = \<^bold>g [^] (r * \<alpha> * x + xa * \<alpha>)
[PROOF STEP]
by blast
[PROOF STATE]
proof (state)
this:
\<^bold>g [^] (r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha>) = \<^bold>g [^] (r * \<alpha> * x + xa * \<alpha>)

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
\<^bold>g [^] (r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha>) = \<^bold>g [^] (r * \<alpha> * x + xa * \<alpha>)

goal (1 subgoal):
 1. \<^bold>g [^] (r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha>) \<otimes> \<^bold>g [^] (t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)))) = \<^bold>g [^] (r * \<alpha> * x + xa * \<alpha>) \<otimes> \<^bold>g [^] (t * x)
[PROOF STEP]
also
[PROOF STATE]
proof (state)
this:
\<^bold>g [^] (r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha>) = \<^bold>g [^] (r * \<alpha> * x + xa * \<alpha>)

goal (1 subgoal):
 1. \<^bold>g [^] (r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha>) \<otimes> \<^bold>g [^] (t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)))) = \<^bold>g [^] (r * \<alpha> * x + xa * \<alpha>) \<otimes> \<^bold>g [^] (t * x)
[PROOF STEP]
have "\<^bold>g [^] (t * ((order \<G> * order \<G> - s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + x) mod order \<G> + s * (nat ((fst (bezw t (order \<G>))) mod order \<G>))))
                    = \<^bold>g [^] (t * x)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<^bold>g [^] (t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)))) = \<^bold>g [^] (t * x)
[PROOF STEP]
proof-
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. \<^bold>g [^] (t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)))) = \<^bold>g [^] (t * x)
[PROOF STEP]
have "[t * ((order \<G> * order \<G> - s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + x) mod order \<G> + s * (nat ((fst (bezw t (order \<G>))) mod order \<G>))) = t * x] (mod order \<G>)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. [t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) = t * x] (mod order \<G>)
[PROOF STEP]
proof-
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. [t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) = t * x] (mod order \<G>)
[PROOF STEP]
have "[t * ((order \<G> * order \<G> - s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + x) mod order \<G> + s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)))
                    = (t * (order \<G> * order \<G> - s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + x + s * (nat ((fst (bezw t (order \<G>))) mod order \<G>))))] (mod order \<G>)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. [t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) = t * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)))] (mod order \<G>)
[PROOF STEP]
using cong_def mod_add_left_eq mod_mult_cong
[PROOF STATE]
proof (prove)
using this:
[?b = ?c] (mod ?a) = (?b mod ?a = ?c mod ?a)
(?a mod ?c + ?b) mod ?c = (?a + ?b) mod ?c
\<lbrakk>?a mod ?c = ?a' mod ?c; ?b mod ?c = ?b' mod ?c\<rbrakk> \<Longrightarrow> ?a * ?b mod ?c = ?a' * ?b' mod ?c

goal (1 subgoal):
 1. [t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) = t * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)))] (mod order \<G>)
[PROOF STEP]
by blast
[PROOF STATE]
proof (state)
this:
[t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) = t * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)))] (mod order \<G>)

goal (1 subgoal):
 1. [t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) = t * x] (mod order \<G>)
[PROOF STEP]
hence "[t * ((order \<G> * order \<G> - s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) + x) mod order \<G> + s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)))
                    = t * (order \<G> * order \<G> + x )] (mod order \<G>)"
[PROOF STATE]
proof (prove)
using this:
[t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) = t * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)))] (mod order \<G>)

goal (1 subgoal):
 1. [t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) = t * (order \<G> * order \<G> + x)] (mod order \<G>)
[PROOF STEP]
proof-
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. [t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) = t * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)))] (mod order \<G>) \<Longrightarrow> [t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) = t * (order \<G> * order \<G> + x)] (mod order \<G>)
[PROOF STEP]
have "order \<G> * order \<G> - s * (nat ((fst (bezw t (order \<G>))) mod order \<G>)) > 0"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. 0 < order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))
[PROOF STEP]
proof-
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. 0 < order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))
[PROOF STEP]
have "(nat ((fst (bezw t (order \<G>))) mod order \<G>)) \<le> order \<G>"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. nat (fst (bezw t (order \<G>)) mod int (order \<G>)) \<le> order \<G>
[PROOF STEP]
using nat_le_iff order.strict_implies_order order_gt_0
[PROOF STATE]
proof (prove)
using this:
(nat ?x \<le> ?n) = (?x \<le> int ?n)
?a < ?b \<Longrightarrow> ?a \<le> ?b
0 < order \<G>

goal (1 subgoal):
 1. nat (fst (bezw t (order \<G>)) mod int (order \<G>)) \<le> order \<G>
[PROOF STEP]
by (simp add: order.strict_implies_order)
[PROOF STATE]
proof (state)
this:
nat (fst (bezw t (order \<G>)) mod int (order \<G>)) \<le> order \<G>

goal (1 subgoal):
 1. 0 < order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))
[PROOF STEP]
thus ?thesis
[PROOF STATE]
proof (prove)
using this:
nat (fst (bezw t (order \<G>)) mod int (order \<G>)) \<le> order \<G>

goal (1 subgoal):
 1. 0 < order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))
[PROOF STEP]
by (metis assms diff_mult_distrib le0 linorder_neqE_nat mult_strict_mono not_le zero_less_diff)
[PROOF STATE]
proof (state)
this:
0 < order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
0 < order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))

goal (1 subgoal):
 1. [t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) = t * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)))] (mod order \<G>) \<Longrightarrow> [t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) = t * (order \<G> * order \<G> + x)] (mod order \<G>)
[PROOF STEP]
thus ?thesis
[PROOF STATE]
proof (prove)
using this:
0 < order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))

goal (1 subgoal):
 1. [t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) = t * (order \<G> * order \<G> + x)] (mod order \<G>)
[PROOF STEP]
using \<open>[(t::nat) * ((order \<G> * order \<G> - (s::nat) * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + (x::nat)) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) = t * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)))] (mod order \<G>)\<close>
[PROOF STATE]
proof (prove)
using this:
0 < order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))
[t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) = t * (order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)))] (mod order \<G>)

goal (1 subgoal):
 1. [t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) = t * (order \<G> * order \<G> + x)] (mod order \<G>)
[PROOF STEP]
by auto
[PROOF STATE]
proof (state)
this:
[t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) = t * (order \<G> * order \<G> + x)] (mod order \<G>)

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
[t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) = t * (order \<G> * order \<G> + x)] (mod order \<G>)

goal (1 subgoal):
 1. [t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) = t * x] (mod order \<G>)
[PROOF STEP]
thus ?thesis
[PROOF STATE]
proof (prove)
using this:
[t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) = t * (order \<G> * order \<G> + x)] (mod order \<G>)

goal (1 subgoal):
 1. [t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) = t * x] (mod order \<G>)
[PROOF STEP]
by (metis (no_types, opaque_lifting) add.commute cong_def mod_mult_right_eq mod_mult_self1)
[PROOF STATE]
proof (state)
this:
[t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) = t * x] (mod order \<G>)

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
[t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) = t * x] (mod order \<G>)

goal (1 subgoal):
 1. \<^bold>g [^] (t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)))) = \<^bold>g [^] (t * x)
[PROOF STEP]
thus ?thesis
[PROOF STATE]
proof (prove)
using this:
[t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) = t * x] (mod order \<G>)

goal (1 subgoal):
 1. \<^bold>g [^] (t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)))) = \<^bold>g [^] (t * x)
[PROOF STEP]
using finite_group pow_generator_eq_iff_cong
[PROOF STATE]
proof (prove)
using this:
[t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))) = t * x] (mod order \<G>)
finite (carrier \<G>)
finite (carrier \<G>) \<Longrightarrow> (\<^bold>g [^] ?x = \<^bold>g [^] ?y) = [?x = ?y] (mod order \<G>)

goal (1 subgoal):
 1. \<^bold>g [^] (t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)))) = \<^bold>g [^] (t * x)
[PROOF STEP]
by blast
[PROOF STATE]
proof (state)
this:
\<^bold>g [^] (t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)))) = \<^bold>g [^] (t * x)

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
\<^bold>g [^] (t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)))) = \<^bold>g [^] (t * x)

goal (1 subgoal):
 1. \<^bold>g [^] (r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha>) \<otimes> \<^bold>g [^] (t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)))) = \<^bold>g [^] (r * \<alpha> * x + xa * \<alpha>) \<otimes> \<^bold>g [^] (t * x)
[PROOF STEP]
ultimately
[PROOF STATE]
proof (chain)
picking this:
\<^bold>g [^] (r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha>) = \<^bold>g [^] (r * \<alpha> * x + xa * \<alpha>)
\<^bold>g [^] (t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)))) = \<^bold>g [^] (t * x)
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
using this:
\<^bold>g [^] (r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha>) = \<^bold>g [^] (r * \<alpha> * x + xa * \<alpha>)
\<^bold>g [^] (t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)))) = \<^bold>g [^] (t * x)

goal (1 subgoal):
 1. \<^bold>g [^] (r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha>) \<otimes> \<^bold>g [^] (t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)))) = \<^bold>g [^] (r * \<alpha> * x + xa * \<alpha>) \<otimes> \<^bold>g [^] (t * x)
[PROOF STEP]
by argo
[PROOF STATE]
proof (state)
this:
\<^bold>g [^] (r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha>) \<otimes> \<^bold>g [^] (t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)))) = \<^bold>g [^] (r * \<alpha> * x + xa * \<alpha>) \<otimes> \<^bold>g [^] (t * x)

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
\<^bold>g [^] (r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha>) \<otimes> \<^bold>g [^] (t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)))) = \<^bold>g [^] (r * \<alpha> * x + xa * \<alpha>) \<otimes> \<^bold>g [^] (t * x)

goal (1 subgoal):
 1. (\<^bold>g [^] (r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G>), \<^bold>g [^] (r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha>) \<otimes> \<^bold>g [^] (t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))))) = (\<^bold>g [^] (r * x + xa), \<^bold>g [^] (r * \<alpha> * x + xa * \<alpha>) \<otimes> \<^bold>g [^] (t * x))
[PROOF STEP]
ultimately
[PROOF STATE]
proof (chain)
picking this:
\<^bold>g [^] (r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G>) = \<^bold>g [^] (r * x + xa)
\<^bold>g [^] (r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha>) \<otimes> \<^bold>g [^] (t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)))) = \<^bold>g [^] (r * \<alpha> * x + xa * \<alpha>) \<otimes> \<^bold>g [^] (t * x)
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
using this:
\<^bold>g [^] (r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G>) = \<^bold>g [^] (r * x + xa)
\<^bold>g [^] (r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha>) \<otimes> \<^bold>g [^] (t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)))) = \<^bold>g [^] (r * \<alpha> * x + xa * \<alpha>) \<otimes> \<^bold>g [^] (t * x)

goal (1 subgoal):
 1. (\<^bold>g [^] (r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G>), \<^bold>g [^] (r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha>) \<otimes> \<^bold>g [^] (t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))))) = (\<^bold>g [^] (r * x + xa), \<^bold>g [^] (r * \<alpha> * x + xa * \<alpha>) \<otimes> \<^bold>g [^] (t * x))
[PROOF STEP]
by simp
[PROOF STATE]
proof (state)
this:
(\<^bold>g [^] (r * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G>), \<^bold>g [^] (r * \<alpha> * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G>) + (r * s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + xa) mod order \<G> * \<alpha>) \<otimes> \<^bold>g [^] (t * ((order \<G> * order \<G> - s * nat (fst (bezw t (order \<G>)) mod int (order \<G>)) + x) mod order \<G> + s * nat (fst (bezw t (order \<G>)) mod int (order \<G>))))) = (\<^bold>g [^] (r * x + xa), \<^bold>g [^] (r * \<alpha> * x + xa * \<alpha>) \<otimes> \<^bold>g [^] (t * x))

goal:
No subgoals!
[PROOF STEP]
qed