Miyagi knew naihanchi kata. He describes it in his 'Outline of Karate-do' as one of the basic kata together with sanchin and tensho.
Miyagi and Motobu knew each other well too. But I doubt they ever trained together.
Naihanchi kata is brought to Okinawa by Iwah/Ason ?
Sanseru is imported into Okinawa through Fuzhou chuan fa (crane/tiger/monk fist).
Apperently Seisho Aragaki already knew a version before Kanryo Higaonna started teaching it (but he has been a student of Aragaki). Certainly Kanryu Higaonna, Kanei Ueichi and Norisato teached a version of Sanseru beginning 20th centurie, all originating from Fuzhou. I am certain that all of them knew Naifanchi. But I do not think that there is a direct connection in the applications.
Application of techniques from kata is limited to your imagination. I heard from Kisaki sensei and from Uchiage sensei that Miyagi never teached official bunkai, as a sequence of attack-defense movements, for kata. He would explain techniques from kata but as for application he said 'think, you will figure it out on your own'.