Structure of Periodic Crystals and Quasicrystals in Ultrathin Films of Ba-Ti-O.