The two most common ways to make a long song are the multi-part suite and the song that goes through changes but keeps returning to a main theme. Yes was great at both of these approaches and here we have examples of each.
Starship Trooper of course is the suite, with three sections that don't have a lot to do with each other but go together well. But in a twist that few could pull off, there's a D.S. from the Disillusion (middle) section back to the Life Seeker (opening) section. You usually don't do that, but it works here because... well, it just works because Yes was great at this kind of thing. Würm is fun, but some of the live versions do tend to go on a bit. It was nice of them to give Wakeman a solo section, which evolved into the duel with Howe, so that was cool.
Yours is No Disgrace and Machine Messiah are longer songs that are just longer songs. Yes were never content to just use basic song structures (two verses, a break, and either another verse or just a chorus). Songs were a journey, a journey has different phases, it takes time. Take a few different turns, come back for another verse or another chorus, then go off in another direction. Yes were known (and sometimes derided) for all their side-long epics, but they had a bunch of great songs in the eight-to-10-minute range as well, and these are two of them.