If a person touched an object that made him impure, forgot about it, and then knowingly ate sacrifices, he has to bring a “variable” offering that depends on his means. This case is explicitly mentioned in the Torah. However, if he remembered about his impurity but forgot that the food he was eating was holy, he is equally liable, only this case in not mentioned in the Torah but is rather derived.
Similarly, if he forgot about his impurity and visited the Temple, this is the second of the “two” cases mentioned in the Torah. If he remembered about the impurity but forgot about the Temple, this is the additional derived case.
Asked Rav Pappa, what if he forgot about the laws of impurity? - But what exactly did he forget? If he forgot if it is a lizard or a frog that makes him impure – let him go and learn it with the children in school! Rather, what if he forgot the amount of lizard's meat that makes him impure on contact, is it like a lentil or more, what is the law? - This question remains unresolved.
Art: Luisa Vitelli - Parrot, Blue Tit, Two Lizards, and Vases