TITLE: PUMP/probe experiment
AUTHORS: Alison E E. Malcolm

[DESCRIPTION]
Run a PUMP/probe experiment as described by Gallot, T., et al. "Characterizing the nonlinear interaction of S-and P-waves in a rock sample." Journal of Applied Physics 117.3 (2015): 034902.

[GUIDELINES]
It is best to run the experiment once with a large spacing of delay times to make sure that the acquisition codes are working properly etc.  The PUMP and probe should not be about around 5 Vpp if they are going through the amplifier.

[STEPS]
SECTION: Pre-Experiment Steps
1. Gather equipment and attach transducers to samples.  (Typically P traveling perpendicular to S with the polarization of the S-wave aligned with the polarization of the P-wave.)
SECTION: Pre-Experiment Steps
2. Measure pump and probe velocities using the 'measuring velocities' protocol.
SECTION: Pre-Experiment Steps
3. Calculate the travel time for the pump and probe to reach the centre of the sample.
SECTION: Pre-Experiment Steps
4. Determine the pump/probe delays that you want to measure.  Typically you want the first delays to be from before the PUMP crosses the probe path, and the last ones to be after the last cycle of the PUMP cross the probe path.  

For example, if the probe arrives at the centre after 30 us and the S-wave arrives after 40 us, and the PUMP signal is 20 us in length,  then you could start with a 0 delay (P-wave arrives 10 us before S-wave) and then measure until a delay of 40 us.  This will give you 10 us before the PUMP arrives, 20 us while the two waves interact and 10 us after the PUMP has passed the interaction region.
SECTION: Wiring and Setting up the experiment
5. Attach the following cables (see diagram below)  

SECTION: Wiring and Setting up the experiment
5.1. Function generator 'trig out' to oscilloscope 'ext in'
SECTION: Wiring and Setting up the experiment
5.2. Function generator channel 2 (usually) to amplifier to PUMP source
SECTION: Wiring and Setting up the experiment
5.3. Function generator channel 1 (usually) to probe source
SECTION: Wiring and Setting up the experiment
5.4. probe receiver to filter to oscilloscope channel 1 (usually)
SECTION: Wiring and Setting up the experiment
5.5. PUMP receiver to oscilloscope channel 2 (usually) if monitoring the PUMP before/after experiment

SECTION: Check waveforms
6. PUMP check
SECTION: Check waveforms
7. probe check    
SECTION: Check waveforms
7.1. Set the parameters for the probe, typical values are:
f=800 kHz- 1MHz
amp=1-10 Vpp without amplification
1 cycle, sinusoid
SECTION: Check waveforms
6.1. Set the parameters for the PUMP, typical values are:
f=70-100 kHz
amplitude=3-8 Vpp through the amp (150-400 Vpp)
4 cycles, sine wave
SECTION: Check waveforms
6.2. Look at the PUMP signal, and change the frequency until you have a signal in which you clearly see 4 cycles of your sinusoid recorded on the opposite face of the sample.
SECTION: Check waveforms
7.2. Setup the filter, typical parameters are:
butterworth, high-pass cut-off frequency 600 kHz
SECTION: Check waveforms
7.3. Compare the signal with and without the filter, to make sure that the probe waveform is still clear and has not been changed too much by the filter.  Adjust the frequency of the probe, its amplitude, and the cut-off frequency of the filter until you have a clean pulse.  Example is below.
SECTION: Check waveforms
7.4. Centre the oscilloscope on the probe waveform and zoom in until the waveform fills the screen.  This involves moving the signal left/right (small knob on top of the oscilloscope) as well as changing the horizontal scale (large knob on the oscilloscope).  Record the 'shift' value on the top of the oscilloscope.  Also find the minimum vertical scale that does not clip your data.

SECTION: Record Data
8. Typically we collect the data automatically with a python code, an example of which is here: https://github.com/alisonmalcolm/GAELCodes/tree/master/PUMPprobe .  This set of steps details what is done in that code, without the details (like communicating between the oscilloscope and computer).
SECTION: Record Data
8.1. Setup your time shifts, using the calculations from step 4.  Generally it's best to use a large step (e.g. 5 us) at first, then do a longer run once you have QCd the results.
SECTION: Record Data
8.2. Add in your time delay (found in step 7.4) so that you will record the entire probe waveform.  
SECTION: Record Data
8.3. Record the probe by itself (turn off the output of the PUMP on the function generator)
SECTION: Record Data
8.4. Record the PUMP by itself, on the probe receiving transducer (channel 1) (turn off the output for the probe on the function generator)
SECTION: Check waveforms
6.3. Record this waveform for later.
SECTION: Check waveforms
7.5. Record this waveform for later
SECTION: Record Data
8.5. Record the PUMP and probe together (both channels of the function generator on), using the probe receiving transducer.
SECTION: Record Data
8.6. Change the delay so the probe is sent dt later.
SECTION: Record Data
8.7. Shift the oscilloscope recording window
SECTION: Record Data
8.8. Repeat steps 8.3-8.7 until you have collected all of your delays.
SECTION: Record Data
9. Measure the travel time delay between the signal recorded in 8.3 and the difference between 8.5 and 8.4 (explained below)
SECTION: Data Processing
10. Measure travel time delays, using the ComputeDelays code from here: https://github.com/alisonmalcolm/GAELCodes/tree/master/PUMPprobe