 All right. G'day all. This is my attempt to explain my answer to the plus in an injective task We got a bit stuck during class, but I think I've worked it out. Well, I've worked at a solution That's for sure if I run this it works and I understand why it works So let's talk through it. There's likely to be a better solution, of course So we were given the start in Trozan and then induction on in which gave us these two to solve We didn't even get past the first one But I've worked out that one with that too much trouble Intros to get the hypothesis up there. Sorry to get the M up there Then I'm going to do a simplification in H which can do the computation on the noughts Zeroes and turn them into a single zero Then I'm going to rewrite on H so that's taking zero in The hypothesis and turning it Into an M plus and I think yes now I've got M plus M equals M And I just decided that was a more interesting thing to start from so I started from it and things worked out okay So I'm doing that induction on that M now There's really nothing else to do there But if I induct on the different versions of M I should find out that the only one that it can work for is when M is zero, right? That's what we're aiming for here So induct on M and on the zero one that's easy zero plus zero is zero reflexivity done But the second one is the challenging one So I've got that SM plus SM equals SM. This is the one that can't be true So I've looked up the plus in SM one what I wanted to do is do an inversion I want to say look there's a spot here where we've got the wrong constructors setup Because that's what we have got too many constructors on the left-hand side So I did the rewrite with the plus in SM as in suggested, but I did it on the hypothesis On H. So we're doing on H. I pulled out one of the S's Should I say H instead H, but it's just too too long a habit So now I've got something H Which is impossible because there's zero which is one of our constructors on the left and S Are the constructor on the right? So I do the inversion on that hypothesis and it blows up Good one case down. Maybe something similar to that will work for the second one so we hit that one and we do the intros again and Looks like I probably want to induct on them again. So I do Didn't do any rewrites first. Maybe I could have it might have made things easier But we do the induction on M. So we got the zero case again Which we're expecting to be the easy one. So SM equals zero Definitely can't be right. In fact, I don't think I even need this simple in H I think I do in the simple in H. Sorry. So essay n equals zero can't be right, but I can't invert on my goal I can only invert on on hypothesis things above So I do the simplification on H again the same one. I did no different one simplification on H to Extract out one of those S's because that's what the plus will do when you're given two things with S's Pulls out one of the S's now. I've got in H something that can be inverted away and that blows up Okay Last case here, which is the last part of the Induction on M and I see my hypothesis looks Well, so I'm not quite sure how it works out the I mean I can see that the inversion here SN plus SN equals SM plus SM should pull pull out for me N plus Sn equals M plus SN and it didn't know what that's very useful But I'm only half sure of that one. So this I guess is the magic step that I'm not a hundred percent sure on this inversion on H because It's constructed. It's not just two constructors, right? It's it's Ah, so I guess there must be simplifications happening. Let me just see if that's what's happening So the simplification pulls the S's out of both sides. Yes. Now it makes sense So the inversions doing the simplification first. So let's do that explicitly. I do the simplification and then I do the inversion But the inversion doesn't blow everything up. It just brings out another Hypothesis H1 that I can use now. I'm gonna rewrite that hypothesis using the same Theory from before so I'm rewriting inner hypothesis And that theory says that N plus SN equals S plus blah blah So I do that once and it pulls the S out the front in H1 I do that again so I can pull the S out the front of the right-hand side and now I'm ready for inversion again Inversion on H1 because I've got two constructors that are the same So the two bodies will be the same and I do that and I pull that yet another hypothesis that N prime plus N prime equals M plus M Now that matches brilliantly with the IHN so all the way through here I was struggling to get something that lined up with IHN prime. I had things that had extra S's in them all the time But now I've gotten exactly to where I want to be with the N prime and the N prime matching up perfectly So if I apply IHN to sorry to H2 It takes away the It simplifies the right-hand side, okay, so it takes away the pluses and turns them just into singles Which is exactly what I need because now I can do a rewrite using H2 in the goal Rewrite H2 in the goal gives me SM equals SM resex flexibility and we're done Okay, so all the magic disappeared there on my third time around the last bit that was magic I didn't quite get was the simplification happening before the inversion But now that I've worked that out. It all makes perfect sense. So hopefully that makes perfect sense to you They did say it was an exercise in practice in using in and the Solution which is long ish does use lots of in so maybe it's the one they were aiming for But regardless it works and I explained it What more can we ask for? That's it for now