They are spelled differently. Riyū is always and Ryū is always . The latter contains a yō-on. Notice the **small** , which is different from the normal . (If you don't know about small , please refer to any beginner textbook.)
If you saw for in modern Japanese book, it's most likely a typo, but there are rare exceptions:
* If you are reading a very old document (or a citation from an old document), you may see for because the small was not common before the postwar script reform.
* In furigana, a small /// is sometimes rendered like a regular (large) /// because furigana are already small. This depends on the publisher. See the subtle difference below:
![enter image description here](
BTW may be difficult to pronounce/hear to native English speakers.