The maximum is unbounded because you can keep gaining the same cards from the trash and then trashing them over and over again. I'm pretty sure we can do that with n=2 using this and Diadem (Tournament can replace Pooka or Tracker, as those are only used for their Heirlooms which we don't need because of Diadem).
You're right; of course I forgot something :/. I had meant to only count a gain the first time a physical card is gained in a turn, and I've edited the original post to reflect this.
But, without that change, I guess f(2) is at least 276 plus however many Wisps and non-Diadem Prizes you can gain on this board (probably all of them). Though, f(n) has to be greater than or equal to f(n-1) for some n>2, since you can have Kingdoms with more available cards than this one.