theory Typedef_Morphisms

lemma fns: "fr \<circ> norm = norm \<circ> fr \<Longrightarrow> fa \<circ> Abs = Abs \<circ> fr \<longleftrightarrow> Rep \<circ> fa = fr \<circ> Rep" apply safe apply (frule fns1b) prefer 2 apply (frule fns1a) apply (rule fns3 [THEN iffD1]) prefer 3 apply (rule fns2 [THEN iffD1]) apply (simp_all add: comp_assoc) apply (simp_all add: o_assoc) done

(* Proof state trace *)
proof (prove)
goal (1 subgoal):
 1. fr \<circ> norm = norm \<circ> fr \<Longrightarrow> (fa \<circ> Abs = Abs \<circ> fr) = (Rep \<circ> fa = fr \<circ> Rep) proof (prove)
goal (2 subgoals):
 1. \<lbrakk>fr \<circ> norm = norm \<circ> fr; fa \<circ> Abs = Abs \<circ> fr\<rbrakk> \<Longrightarrow> Rep \<circ> fa = fr \<circ> Rep
 2. \<lbrakk>fr \<circ> norm = norm \<circ> fr; Rep \<circ> fa = fr \<circ> Rep\<rbrakk> \<Longrightarrow> fa \<circ> Abs = Abs \<circ> fr proof (prove)
goal (2 subgoals):
 1. \<lbrakk>fr \<circ> norm = norm \<circ> fr; fa \<circ> Abs = Abs \<circ> fr; Abs \<circ> fr \<circ> Rep = fa\<rbrakk> \<Longrightarrow> Rep \<circ> fa = fr \<circ> Rep
 2. \<lbrakk>fr \<circ> norm = norm \<circ> fr; Rep \<circ> fa = fr \<circ> Rep\<rbrakk> \<Longrightarrow> fa \<circ> Abs = Abs \<circ> fr proof (prove)
goal (2 subgoals):
 1. \<lbrakk>fr \<circ> norm = norm \<circ> fr; Rep \<circ> fa = fr \<circ> Rep\<rbrakk> \<Longrightarrow> fa \<circ> Abs = Abs \<circ> fr
 2. \<lbrakk>fr \<circ> norm = norm \<circ> fr; fa \<circ> Abs = Abs \<circ> fr; Abs \<circ> fr \<circ> Rep = fa\<rbrakk> \<Longrightarrow> Rep \<circ> fa = fr \<circ> Rep proof (prove)
goal (2 subgoals):
 1. \<lbrakk>fr \<circ> norm = norm \<circ> fr; Rep \<circ> fa = fr \<circ> Rep; Abs \<circ> fr \<circ> Rep = fa\<rbrakk> \<Longrightarrow> fa \<circ> Abs = Abs \<circ> fr
 2. \<lbrakk>fr \<circ> norm = norm \<circ> fr; fa \<circ> Abs = Abs \<circ> fr; Abs \<circ> fr \<circ> Rep = fa\<rbrakk> \<Longrightarrow> Rep \<circ> fa = fr \<circ> Rep proof (prove)
goal (3 subgoals):
 1. \<lbrakk>fr \<circ> norm = norm \<circ> fr; Rep \<circ> fa = fr \<circ> Rep; Abs \<circ> fr \<circ> Rep = fa\<rbrakk> \<Longrightarrow> Abs \<circ> fr \<circ> Rep = fa
 2. \<lbrakk>fr \<circ> norm = norm \<circ> fr; Rep \<circ> fa = fr \<circ> Rep; Abs \<circ> fr \<circ> Rep = fa\<rbrakk> \<Longrightarrow> norm \<circ> fr \<circ> norm = norm \<circ> fr
 3. \<lbrakk>fr \<circ> norm = norm \<circ> fr; fa \<circ> Abs = Abs \<circ> fr; Abs \<circ> fr \<circ> Rep = fa\<rbrakk> \<Longrightarrow> Rep \<circ> fa = fr \<circ> Rep proof (prove)
goal (3 subgoals):
 1. \<lbrakk>fr \<circ> norm = norm \<circ> fr; fa \<circ> Abs = Abs \<circ> fr; Abs \<circ> fr \<circ> Rep = fa\<rbrakk> \<Longrightarrow> Rep \<circ> fa = fr \<circ> Rep
 2. \<lbrakk>fr \<circ> norm = norm \<circ> fr; Rep \<circ> fa = fr \<circ> Rep; Abs \<circ> fr \<circ> Rep = fa\<rbrakk> \<Longrightarrow> Abs \<circ> fr \<circ> Rep = fa
 3. \<lbrakk>fr \<circ> norm = norm \<circ> fr; Rep \<circ> fa = fr \<circ> Rep; Abs \<circ> fr \<circ> Rep = fa\<rbrakk> \<Longrightarrow> norm \<circ> fr \<circ> norm = norm \<circ> fr proof (prove)
goal (4 subgoals):
 1. \<lbrakk>fr \<circ> norm = norm \<circ> fr; fa \<circ> Abs = Abs \<circ> fr; Abs \<circ> fr \<circ> Rep = fa\<rbrakk> \<Longrightarrow> Abs \<circ> fr \<circ> Rep = fa
 2. \<lbrakk>fr \<circ> norm = norm \<circ> fr; fa \<circ> Abs = Abs \<circ> fr; Abs \<circ> fr \<circ> Rep = fa\<rbrakk> \<Longrightarrow> norm \<circ> fr \<circ> norm = fr \<circ> norm
 3. \<lbrakk>fr \<circ> norm = norm \<circ> fr; Rep \<circ> fa = fr \<circ> Rep; Abs \<circ> fr \<circ> Rep = fa\<rbrakk> \<Longrightarrow> Abs \<circ> fr \<circ> Rep = fa
 4. \<lbrakk>fr \<circ> norm = norm \<circ> fr; Rep \<circ> fa = fr \<circ> Rep; Abs \<circ> fr \<circ> Rep = fa\<rbrakk> \<Longrightarrow> norm \<circ> fr \<circ> norm = norm \<circ> fr proof (prove)
goal (2 subgoals):
 1. \<lbrakk>fr \<circ> norm = norm \<circ> fr; fa \<circ> Abs = Abs \<circ> fr; Abs \<circ> (fr \<circ> Rep) = fa\<rbrakk> \<Longrightarrow> norm \<circ> (norm \<circ> fr) = norm \<circ> fr
 2. \<lbrakk>fr \<circ> norm = norm \<circ> fr; Rep \<circ> fa = fr \<circ> Rep; Abs \<circ> (fr \<circ> Rep) = fa\<rbrakk> \<Longrightarrow> norm \<circ> (norm \<circ> fr) = norm \<circ> fr proof (prove)
goal:
No subgoals!