Design of a contact grating setup for mJ-energy THz pulse generation by optical rectification