Rav Moshe Soloveitchik once came late to davening and when he reached גאל ישראל before the shmona esrei of shachris the tzibbur started mussaf. He debated with himself as to whether he should daven shachris by himself or mussaf with the tzibbur. There are two issues. 1] Does the ענין of being מסמיך גאולה לתפילה apply to mussaf as well [in which case maybe he should say mussaf with the tzibbur] or only to shachris and maariv. 2] Does one fulfill the mitzva of tfilla bi-tzibbur if davening at the same time that the tzibbur davens a different tfilla [in which case even if he davens shachris it would be considered tfilla bi-tzibbur].
He decided to daven ....... mussaf! [Shocker]
He felt that it is important to be מסמיך גאולה לתפילה in one tfilla - regardless of whether it is shachris or mussaf.
His father Rav Chaim agreed with him but added that even if he would have davened shachris it would still have been considered tfilla bi-tzibbur. He proved this from the gemara [21a] that says that if one already davened and found the tzibbur davening, if he can be מחדש דבר he should daven and if not, he shouldn't. Said Reb Chaim: We are talking about a person who already davened his tfillas chova [obligatory tfilla] and now he wants to daven a tfillas nedava [voluntary tfilla] with the tzibbur that is davening a tfillas chova. So we see that it is considered tfilla bi-tzibbur even if he is davening a different tfilla than everyone else.
ספר זכרון אש תמיד תקמב
We must note that the Magen Avraham [סי' צ] writes that it's NOT considered tfilla bi-tzibbur. See the sefer Piskei Tshuvos ח"א עמ' תשא for more sources on this interesting shyla.
Love and blessings:-)