A Trojan virus is actually not a virus at all. It's a malicious software you may inadvertently download, thinking that you're installing a legitimate program. The purpose of trojan software is either to extort or steal money from you or take control of your computer for mischievous purposes.
The best explanation of the difference between trojan software and a virus or malware is the story about the Trojan War and the Trojan horse.
As the story goes, the Greeks constructed a huge wooden horse filled with soldiers and presented the horse as a parting gift to the City of Troy. Once the horse was inside the city, the Greek soldiers crept out of the hollow horse and attacked the city under cover of darkness.
Viruses are software that are created to infect one computer and then spread to other computers. Trojan software isn't created to spread. It's meant to perform a very specific task on your computer or mobile device.
A Trojan virus is meant to perform malicious tasks on your computer, usually without you even knowing it.