There is a deeper reason for the choice of the specific numbers in our Mishna, and the virtue of the number five compared to three, and three compared to two.
The Divine Presence connects with man when man manifests some replication of the Divine, however limited it may be. Since G-d is all-encompassing, He can be found when there is a group of people whose number is an all- encompassing one. The number ten is the number of completeness, since no increase is possible within that number. Therefore G-d’s presence resides within a group of ten.
The number four is a number of separation, and represents dispersal in all four directions. We see scripture describing division and separation as “…for I have scattered you like the four directions of the heavens” (Zechariah 2:10). Each of the four directions is discreet and independent of the others.
But the “fifth” is the unifier, since it resides in the middle of the four directions, and it is the middle element which always unifies the other elements. For this reason, five is called “agudah,” a group, with the fifth unifying the other four. (In order to add a fifth element to the four elements of the plane, that additional one must be placed, conceptually, in the middle. This parallels the structure of the number three being the unifier of the number two, with two representing contrast, and the extremes of a line.) So, the verse “…His group upon the earth” is referring to five, even though no number is mentioned explicitly. Five, a unifier, is fundamentally (not simply quantitatively) different than four which represents division. G-d is a unifier and a totality, and the unifying power of five is the reason the Divine presence is more manifest among five people. (See Gevuroth HaShem, the end of Ch. 23 and the beginning of Ch. 58 for further elaboration of the concept of the number of five and its relationship to four. Four is the number representing exile, and five is the number representing redemption. Five is also the number of fingers that make up the hand.)
The same principle applies to the number three, which is why the Tanna teaches “What is the source that when three people are sitting and involved in Torah study that the Divine Presence resides aomong them…”. The number three unifies the division and contrast that exists in every pair of elements, as we explained above (see Mishna 4, part 2 in this chapter, “Three who ate at one table…”). Two represents the fundamental nature of division, with each element contrasting with its opposite. It is the third element that connects and unifies them. Five is still a greater and more complete unifier than three (which is why the Divine presence dwells among five in a more intense way than among three). Five unites four discrete sides, while three unites only two sides, which doesn’t create a complete group, a full “agudah”.
This perspective enables us to provide a response to a difficulty raised by Tosafoth in the first chapter of Masecheth Sukkah (13a, “B’shalosh”). The discussion there implies that three is considered an “agudah” in relation to the bundle of sprigs used for the sprinkling of red heifer purification water. Yet our Mishna implies that an “agudah” is five (which should have required five branches for the bundle used in sprinkling the purification water). Tosafos proposes a correction in the text of our Mishna, where a different proof text would be used to prove that the Divine presence resides among five, and the text “foundation of His group” which mentions “agudah” would be used to prove that the Divine presence resides among three. But he proves that such a correction is not possible, and provides a very stretched response. (We have not brought the details of the discussion in Tosafos in Sukkah, which the Maharal reviews here.)
According to our understanding (the Maharal writes) there is no problem, and all is clear. Even though three is also considered an “agudah,” it is not a complete one. The complete is when the four sides are united together through the number five. (When discussing the “agudah” for the purificationwaters, the one with the minimum number of elements is sufficient. But when assessing the different levels of Divine presence among those involved in Torah study, five is a more complete “agudah” and will have a more intense level of that Divine presence than three.)
Therefore, five people learning involved in Torah study is greater than three, and two is greater than one. For two is till a pair, which enables connection, and “Two are better than one” (Koheleth 4:9). Two is the beginning of true counting, which means uniting discrete single elements. This is the power of two over one.