A man suffering from cancer has a colostomy bag from which stool and gas exit. He has a sufficient time for purification every morning when he changes the bag. What is the ruling on his prayer? Is it permissible for him to pray in this condition? Should he pray the missed prayers each day, or should he wait until he is purified to perform the obligatory prayers?