trcv code simplified