When can you use 'a same'?

When will we use 'a same', instead of 'the same'? Is it grammatical to say:

  1. We wore a same hat yesterday.
  2. We talked to a same teacher everyday.

Hardly ever, and your two examples are ungrammatical. Just about the only way same can be preceded by a is in a phrase such as a same day service, where the indefinite article relates to service, and same day is adjectival.