theorem appendinj2 (l1 l2 r1 r2: nat):
$ len l2 = len r2 -> (l1 ++ l2 = r1 ++ r2 <-> l1 = r1 /\ l2 = r2) $;
Step | Hyp | Ref | Expression |
1 |
|
appendinj1 |
len l1 = len r1 -> (l1 ++ l2 = r1 ++ r2 <-> l1 = r1 /\ l2 = r2) |
2 |
|
addcan1 |
len l1 + len l2 = len r1 + len l2 <-> len l1 = len r1 |
3 |
|
appendlen |
len (l1 ++ l2) = len l1 + len l2 |
4 |
|
appendlen |
len (r1 ++ r2) = len r1 + len r2 |
5 |
|
anr |
len l2 = len r2 /\ l1 ++ l2 = r1 ++ r2 -> l1 ++ l2 = r1 ++ r2 |
6 |
5 |
leneqd |
len l2 = len r2 /\ l1 ++ l2 = r1 ++ r2 -> len (l1 ++ l2) = len (r1 ++ r2) |
7 |
3, 4, 6 |
eqtr3g |
len l2 = len r2 /\ l1 ++ l2 = r1 ++ r2 -> len l1 + len l2 = len r1 + len r2 |
8 |
|
anl |
len l2 = len r2 /\ l1 ++ l2 = r1 ++ r2 -> len l2 = len r2 |
9 |
8 |
eqcomd |
len l2 = len r2 /\ l1 ++ l2 = r1 ++ r2 -> len r2 = len l2 |
10 |
9 |
addeq2d |
len l2 = len r2 /\ l1 ++ l2 = r1 ++ r2 -> len r1 + len r2 = len r1 + len l2 |
11 |
7, 10 |
eqtrd |
len l2 = len r2 /\ l1 ++ l2 = r1 ++ r2 -> len l1 + len l2 = len r1 + len l2 |
12 |
2, 11 |
sylib |
len l2 = len r2 /\ l1 ++ l2 = r1 ++ r2 -> len l1 = len r1 |
13 |
1, 12 |
syl |
len l2 = len r2 /\ l1 ++ l2 = r1 ++ r2 -> (l1 ++ l2 = r1 ++ r2 <-> l1 = r1 /\ l2 = r2) |
14 |
13, 5 |
mpbid |
len l2 = len r2 /\ l1 ++ l2 = r1 ++ r2 -> l1 = r1 /\ l2 = r2 |
15 |
|
anrl |
len l2 = len r2 /\ (l1 = r1 /\ l2 = r2) -> l1 = r1 |
16 |
|
anrr |
len l2 = len r2 /\ (l1 = r1 /\ l2 = r2) -> l2 = r2 |
17 |
15, 16 |
appendeqd |
len l2 = len r2 /\ (l1 = r1 /\ l2 = r2) -> l1 ++ l2 = r1 ++ r2 |
18 |
14, 17 |
ibida |
len l2 = len r2 -> (l1 ++ l2 = r1 ++ r2 <-> l1 = r1 /\ l2 = r2) |
Axiom use
axs_prop_calc
(ax_1,
ax_2,
ax_3,
ax_mp,
itru),
axs_pred_calc
(ax_gen,
ax_4,
ax_5,
ax_6,
ax_7,
ax_10,
ax_11,
ax_12),
axs_set
(elab,
ax_8),
axs_the
(theid,
the0),
axs_peano
(peano1,
peano2,
peano5,
addeq,
muleq,
add0,
addS,
mul0,
mulS)