impulse_begin_and_end_times()
Description: Finds start and end times for transient calculations.
Usage
[t_start, t_end] = impulse_begin_and_end_times(transducer_array, coordinate_grid, medium);
[t_start, t_end] = impulse_begin_and_end_times(transducer_array, coordinate_grid, medium, nthreads);
Arguments
- transducer_array A transducer_array.
- coordinate_grid A coordinate grid struct like the ones created by set_coordinate_grid.
- medium A medium struct like the ones created by set_medium.
- nthreads The number of threads to use in the calculation.
Output Parameters
- t_start The start time for the impulse response calculation.
- t_end The end time for the impulse response calculation.
Notes
Threading in FOCUS is implemented at the transducer level, meaning that single transducers will not benefit from this feature.
Specifying a number of threads larger than the number of CPU cores available will not result in a significant additional speed increase and may in fact result in slower speeds due to additional inter-thread communication overhead.

