Answer already given, but this Or HaChaim gives a fuller discussion:
An additional meaning of the verse and the way it is phrased is that
G'd appeared to Abraham for Abraham's sake. The Torah here alludes to
something discussed in Baba Metzia 86. Rabbi Chama son of Chanina
stated that this vision occurred on the third day after the
circumcision. G'd came and enquired after Abraham's wellbeing. How did
Rabbi Chama know that it was the third day? If we were to deduce this
from Genesis 34,25, where we are told that the third day after the
people of Shechem had circumsised themselves was a day they
experienced additional pains, this cannot be, because we have a
definitive statement in Shabbat 134 that the first and second day
after the circumcision are more dangerous to the patient! True, the
Talmud there distinguishes between the pain and the relative healing
process experienced by adults (pain lasts longer, healing occurs more
slowly), compared to that experienced by minors. However, such a
distinction applies only to the third day, not to the first two days.
On the first two days everyone experiences the most pain.
Besides, do not use the fact that Shimon
and Levi did not attack the people of Shechem until the third day
after their circumcision as an argument. These sons of Jacob were not
concerned with the pain of the people of Shechem but with their
physical weakness, their relative inability to offer resistance. The
third day is definitely the day such patients feel weakest. Regarding
the danger of infection from the wound and danger to life, etc., the
first two days are far more dangerous than the third day. Why should
we assume then that G'd did not come and visit Abraham on the first or
second day after the circumcision? I have found an interesting comment
in the Tur Yore Deah item 335 in which he quotes this folio in the
Talmud without mentioning that it was on the third day. According to
that version the simple message of Rabbi Chama is that G'd came to pay
a visit to the sick. [The discussion in Shabbat 134 concerns washing a
baby with hot water on the third day after the circumcision if the
third day is on the Sabbath; permission to do this indicates that on
that day the baby's life is in danger. Ed.]
He also explains why Hashem might not have visited Avraham on the first day:
According to the opinion of Ran that the first and the third days are
the most dangerous to the patient, whereas the second day is not
sufficiently dangerous to desecrate the Sabbath, we can understand the
matter better. When you do not feel in danger, G'd applies the general
rule of not visiting the sick during the first three hours of the
morning. On the first day one also does not visit the sick as we know
from Nedarim 40. When Rava was sick, he told his household not to tell
anyone on the first day about his being sick in order not to influence
his horoscope negatively. Rashi explains this to mean "that one should
not talk about the sick person." [As long as the matter is not public
knowledge an immediate cure may result without the debits and merits
of the sick person being reviewed in heaven because of people talking
about him. Ed.] However Rava did want the fact that he was sick
publicised from the second day on, so that all those who hated him
should rejoice over his being sick. This would help diminish his
debits [in the accounts kept in the celestial ledger. Ed.]. Rabbi
Chama did not think G'd visited on the first day, as such a visit
would certainly not have gone unnoticed, and as a result tongues would
have been set wagging. Yerushalmi Peah third chapter states that the
relatives of a sick person may visit him immediately; this is because
such visits do not contribute to the sickness of the patient becoming
public knowledge. There is certainly no doubt that G'd Himself must be
viewed as a very close relative of the sick person. However, a visit
by G'd would most certainly attract attention. According to the
opinion that there is no difference in the degree of danger on either
of the respective three days, this would leave the question of why
Rabbi Chama had to mention the third day as the day G'd visited
Abraham. We may have to assume that these people had the version of
the Tur which did not mention the third day at all.
I will note a couple of interesting points:
- That gemara says Hashem took the sun out its sheath to prevent visitors (looking after Avraham)
- Hashem sent visitors!
- The gemara further up states that Avraham was rewarded in 3 ways for his 3 good deeds (quote below). Perhaps, this is further enhanced by the fact that Avraham was at his weakest on this day, the third day!
The Gemara notes: And in stating this, Rav disagrees with that
statement of Rabbi Ḥama, son of Rabbi Ḥanina. As Rabbi Ḥama, son of
Rabbi Ḥanina, says, and likewise the school of Rabbi Yishmael taught:
In reward for three acts of hospitality that Abraham performed for the
angels, his descendants merited three rewards. The Gemara elaborates:
In reward for providing them with curd and milk, the Jewish people
merited the manna; in reward for: “And he stood [omed] by them,” the
Jews merited the pillar [amud] of cloud; in reward for Abraham saying:
“Let now a little water be fetched,” they merited the well of Miriam.
This statement does not distinguish between actions performed by
Abraham himself and those performed by means of a messenger.