How to take acoustic measurements of a clasroom
It doesn't matter where your microphone is in the room when you take the measurement. What you need to do is find where the peaks are in the cross correlation (each peak corresponds to an echo at a certain lag/delay), figure out what the corresponding inverse filter needs to be to cancel out the sound.

If you're trying to do echo cancellation in MATLAB and have the signal processing toolbox, take a look at the example in xcorr by typing:


  doc xcorr 


for a simple example.

Edit 1:To find the inverse filter required, you need to calculate the transfer function between the source and the mic. (edit: sentence in here was misleading) Once your filters are set up, as long as nothing is changing you should be able to cancel the echoes produced by the room.

Edit 2: To get the room impulse response you typically use a long LFM chirp (some people pop a balloon) and a microphone, then calculate the transfer function between the input signal and the recorded signal. Here's an example paper of what you can do: http://www.artalabs.hr/papers/im-aaaa2003.pdf

Edit 3: 


  You do realise that reverberation (or echoes as you described) are dependent on location and even time? 


you said you are making an "impulse response invariant" filter. So as long as neither your source or microphone are moving, the IIR filter created from your Room Impulse Response measurement will cancel out your echoes...just make sure the mic and speaker stay in the same spot.