Remember in about third or fourth grade when you, maybe, learned to diagram a sentence???
you(understood pronoun)do(verb) THIS (subject of sentence) in memory of Me.(merely explains why you are doing THIS. In fact, (you do this) is a proper imperative sentence by itself and it needs no additional words to be said!
Fourth grade, for me, was 1964. I see what you mentioned as the equivalent of explaining all the various muscle movements required to simply grab a cup. But now you grab a cup without even thinking about it and only rarely drop one.:-)
Sentence structure now just “happens”.