How are trackers created

How do I create a tracker. How are auto calculated columns such as difference between dates computed?