Added methods to compare tm structure.