To pray beautifully when people are present and to pray defectively in private is to scorn the lord with your prayer.
The ritual-prayer gains you nothing from God but greater distance if it does not restrain you from indecency and misdeeds.