Ontology for task-based clinical guidelines and the theory of granular partitions