A compound represented by formula (I) or a pharmacologically acceptable salt thereof which has an inhibitory effect on PDE9 and, therefore, is expected as being capable of increasing the cGMP level in the brain. Since the inhibitory effect on PDE9 and an increase in the cGMP level contribute to improvement in learning and memory behavior, the aforesaid compound or a pharmacologically acceptable salt thereof would be available as a remedy for cognitive dysfunction in Alzheimer's disease.In formula (I): R