Function List
This documentation is intended for advanced users. New users may prefer to look over the guides before using the advanced documentation here. A PDF version of this page is also available.

All
 asa_call This function is a gateway to the C++ function that calculates the 3D pressure using the Angular Spectrum Approach.
 asa_run Identical to asa_call but with more error checking and some sanity checking to ensure a proper calculation will occur.
 bioheat_transfer This function uses the Bioheat Transfer Equation to calculate the temperature rise at each point in a medium.
 compare_transient_pressures This function calculates the peak error between two transient pressure fields.
 create_circ_csa This function creates a cylindrical section array of circular transducers.
 create_circ_planar_array This function creates a planar array of circular transducers.
 create_circ_ssa This function creates a spherical section array of circular transducers.
 create_concentric_ring_array Creates an array of concentric ring transducers.
 create_cylindrical_array This function creates a fullyenclosed cylindrical section array of rectangular transducers.
 create_rect_curved_strip_array This function creates a cylindrical section array of rectangular transducers.
 create_rect_enclosed_csa This function creates a fullyenclosed cylindrical section array of rectangular transducers.
 create_rect_enclosed_csa This function creates a fullyenclosed cylindrical section array of rectangular transducers.
 create_rect_planar_array This function creates a planar array of rectangular transducers.
 create_rect_ssa Creates a spherical section array of rectangular transducers.
 create_spherical_shell_planar_array Creates a planar array of spherical shell transducers.
 create_spherically_focused_ring_array Creates an array of spherically focused ring transducers.
 cw_angular_spectrum This function uses the Angular Spectrum Approach to quickly calculate 3D continuouswave pressures given an intial pressure field.
 cw_intensity This function is used to calculate the average intensity of a continuouswave pressure field.
 cw_power This function is used to calculate the power of a continuouswave pressure field.
 cw_pressure This function is used to calculate continuouswave pressures with the Fast Nearfield Method in FOCUS.
 define_media Generates preset media usable for any calculation.
 draw_array This function creates a 3D representation of an arbitrary array of FOCUS transducers.
 draw_circ This is a helper function to draw the circular transducers used by the draw_array function.
 draw_rect This is a helper function to draw the rectangular transducers used by the draw_array function.
 draw_ring This is a helper function to draw the planar ring transducers used by the draw_array function.
 draw_spherically_focused_ring This is a helper function to draw the spherically focused ring transducers used by the draw_array function.
 draw_sphericalshell This is a helper function to draw a single spherical shell transducer used by the draw_array function.
 farfield_cw Calculates the farfield continuouswave pressure generated by a transducer array.
 farfield_cw_parfor Calculates the farfield pressure field generated by a transducer array.
 fftw_asa This function is the C++ binary that implements the Angular Spectrum Approach. It should not be used in any scripts or used directly, as the interface can change. Use asa_call to ensure consistency. Documentation has been omitted. This is a mex function, if it doesn't run please email focus@egr.msu.edu for help.
 find_multiple_focus_phase Calculates phase shifts to focus a transducer array at the given points.
 find_ndiv This function calculates the number of Gaussian quadratures needed to reach an arbitrary tolerance.
 find_phase This function finds a phase adjustment for each transducer such that the phase of all transducers at a given point is the same. This function will likely undergo some significant changes in the near future, but the overall form should remain the same.
 find_single_focus_phase Calculates phase shifts to focus a transducer array at a given point.
 fnm_call This function is the gateway between the Matlab and C++ binary. It does minimal error checking to ensure enough arguments are being passed.
 fnm_cw This function is the C++ MEX file that performs continuouswave calculations using the Fast Nearfield Method.
 fnm_cw_apodized Computes the pressure from pistons or arrays under continuous wave excitation in homogeneous media.
 fnm_cw_parfor Calculate a pressure field using the Fast Nearfield Method and multple threads.
 fnm_cw_single Computes the pressure from pistons under continuous wave excitation in homogeneous media using single precision floating point numbers.
 fnm_cw_sse This function is the C++ MEX file that performs continuouswave calculations using the Fast Nearfield Method and Streaming SIMD Extensions (SSE).
 fnm_run This function is a guided function that does error checking and sanity checks on the input before feeding the information to the C++ binary to get the answer.
 fnm_transient Calculates the transient pressure field from an arbitrary transducer array using the Fast Nearfield Method.
 fnm_transient_call Calculates the transient pressure field from an arbitrary transducer array using the Fast Nearfield Method.
 fnm_transient_parfor Calculates the transient pressure field from an arbitrary transducer array using the Fast Nearfield Method.
 fnm_tsd Calculates the transient pressure field from an arbitrary transducer array using the Fast Nearfield Method and TimeSpace Decomposition or Frequency Domain TimeSpace Decomposition, depending on the input signal.
 fnm_tsd_parfor Calculates the transient pressure field from an arbitrary transducer array using the Fast Nearfield Method.
 get_apodization This function is used get a matrix containing the amplitudes of all elements of a transducer array.
 get_chirp Returns a set of time points describing a linear chirp between two frequencies.
 get_circ This function creates a circular transducer. It is intended to work with the create_circ_arrray functions, but it can be used independently.
 get_excitation_function Returns a set of points corresponding to the given excitation function sampled with the given sampling period. This function is particularly useful for performing FDTSD calculations with excitation functions based on the analytically defined TSD functions.
 get_phases This function is used get a matrix containing the phases of all elements of a transducer array.
 get_pressure Extracts a twodimensional pressure plane from the threedimensional pressure field returned by FOCUS functions (e.g. fnm_call).
 get_rect Creates a rectangular transducer. It is intended to work with the create_rect_array functions, but it can be used independently.
 get_ring This function creates a planar ring transducer. It is intended to work with the create_ring_arrray functions, but it can be used independently.
 get_spherical_shell This function creates a spherical shell transducer. It is intended to be used independently.
 get_spherically_focused_ring This function creates a planar ring transducer. It is intended to work with the create_ring_arrray functions, but it can be used independently.
 get_time_delays This function is used get a matrix containing the time delays of all elements of a transducer array.
 get_tissuestruct Create a structure representing multiple layers of different tissues.
 get_tissuestruct Create a structure representing multiple layers of different tissues.
 impulse_begin_and_end_times Finds start and end times for transient calculations.
 impulse_response Calculates the impulse response of a transducer array.
 impulse_response_parfor Calculates the impulse response of a transducer array.
 kzk_cw Calculates the continuouswave pressure field from an arbitrary transducer array using the KZK equation.
 kzk_transient Calculates the transient pressure field from an arbitrary transducer array using the KZK equation.
 layerasa This function uses the Angular Spectrum Approach to perform calculations in layered media.
 make_tissuestruct Create a structure representing multiple layers of different tissues.
 npsr Unable to load function documentation from /egr/sites/www.egr.msu.edu/cgigroups/fultrasweb/web/documentation/functions/tex/npsr.tex.
 pause2 This is a call back function used by the C++ binary to force an update of the Matlab display buffer. It should not be changed or deleted under any circumstance. If this function is missing, the program WILL NOT WORK.
 plot_transient_pressure Plots the amplitude of each element of a transducer array.
 radiator_cw Unable to load function documentation from /egr/sites/www.egr.msu.edu/cgigroups/fultrasweb/web/documentation/functions/tex/radiator_cw.tex.
 rayleigh_cw Calculates pressure field generated by a transducer array in homogeneous media using the RayleighSommerfeld Integral.
 rayleigh_cw_apodized Calculates pressure field generated by a transducer array in homogeneous media using the RayleighSommerfeld Integral.
 rayleigh_cw_parfor Calculates pressure field generated by a transducer array in homogeneous media using the RayleighSommerfeld Integral.
 rayleigh_cw_sse Calculates pressure field generated by a transducer array in homogeneous media using the RayleighSommerfeld Integral and Streaming SIMD Extensions (SSE).
 rayleigh_transient Calculates pressure field generated by a transducer array in homogeneous media using the RayleighSommerfeld Integral.
 rayleigh_transient_parfor Calculates pressure field generated by a transducer array in homogeneous media using the RayleighSommerfeld Integral.
 rotate_vector_forward Interprets Euler angles to rotate vectors.
 set_apodization This function is used to apodize transducer arrays by setting the amplitudes of the individual transducers.
 set_center_coordinate_grid Creates a coordinate grid centered at the given point.
 set_coordinate_grid Creates a coordinate grid data structure used by FOCUS for various calculations.
 set_digitized_time_delays Determine the time delays needed to focus a transducer array at the given point. Time delays are shifted to fit the temporal grid rather than being allowed to fall between temporal samples.
 set_excitation_function A function to create an excitation function suitable for use with transient_pressure and other transient pressure calculation functions.
 set_fdtsd_excitation A function to create an excitation function for use in Frequency Domain TimeSpace Decomposition (FDTSD) calculations.
 set_layered_medium Create a medium struct for use in ASA layered medium calculations.
 set_medium Create a medium struct for use with other FOCUS functions.
 set_parameters Create a parameter struct for use with FNM functions.
 set_phases This function is used to apodize transducer arrays by setting the amplitudes of the individual transducers.
 set_temporal_coordinate_grid Creates a coordinate grid for use with transient functions.
 set_time_delays Determine the time delays required to focus a transducer array at a given point. Time delays calculated with set_time_delays may fall between temporal samples unless the sampling frequency is provided, in which case the delays are shifted to fit the temporal grid (digitized) rather than being allowed to fall between temporal samples.
 set_time_samples Create a time sample struct for use with transient functions.
 trans_rot This is an internal function used by draw_array and its related functions. Users are not expected to use this function. It is designed to interpret Euler angles when drawing transducer arrays in MATLAB.
 transient_pressure Calculates the transient pressure field from an arbitrary transducer array using the Fast Nearfield Method and TimeSpace Decomposition or Frequency Domain TimeSpace Decomposition, depending on the input signal.

Arrays

Creation
 create_circ_csa This function creates a cylindrical section array of circular transducers.
 create_circ_planar_array This function creates a planar array of circular transducers.
 create_circ_ssa This function creates a spherical section array of circular transducers.
 create_concentric_ring_array Creates an array of concentric ring transducers.
 create_cylindrical_array This function creates a fullyenclosed cylindrical section array of rectangular transducers.
 create_rect_curved_strip_array This function creates a cylindrical section array of rectangular transducers.
 create_rect_enclosed_csa This function creates a fullyenclosed cylindrical section array of rectangular transducers.
 create_rect_planar_array This function creates a planar array of rectangular transducers.
 create_rect_ssa Creates a spherical section array of rectangular transducers.
 create_spherical_shell_planar_array Creates a planar array of spherical shell transducers.
 create_spherically_focused_ring_array Creates an array of spherically focused ring transducers.

Drawing
 draw_array This function creates a 3D representation of an arbitrary array of FOCUS transducers.
 draw_circ This is a helper function to draw the circular transducers used by the draw_array function.
 draw_rect This is a helper function to draw the rectangular transducers used by the draw_array function.
 draw_ring This is a helper function to draw the planar ring transducers used by the draw_array function.
 draw_spherically_focused_ring This is a helper function to draw the spherically focused ring transducers used by the draw_array function.
 draw_sphericalshell This is a helper function to draw a single spherical shell transducer used by the draw_array function.

Single Elements
 get_circ This function creates a circular transducer. It is intended to work with the create_circ_arrray functions, but it can be used independently.
 get_rect Creates a rectangular transducer. It is intended to work with the create_rect_array functions, but it can be used independently.
 get_ring This function creates a planar ring transducer. It is intended to work with the create_ring_arrray functions, but it can be used independently.
 get_spherical_shell This function creates a spherical shell transducer. It is intended to be used independently.
 get_spherically_focused_ring This function creates a planar ring transducer. It is intended to work with the create_ring_arrray functions, but it can be used independently.


Media
 set_medium Create a medium struct for use with other FOCUS functions.
 set_layered_medium Create a medium struct for use in ASA layered medium calculations.
 get_tissuestruct Create a structure representing multiple layers of different tissues.
 define_media Generates preset media usable for any calculation.

Computation

Calculation Parameters
 get_excitation_function Returns a set of points corresponding to the given excitation function sampled with the given sampling period. This function is particularly useful for performing FDTSD calculations with excitation functions based on the analytically defined TSD functions.
 impulse_begin_and_end_times Finds start and end times for transient calculations.
 set_center_coordinate_grid Creates a coordinate grid centered at the given point.
 set_coordinate_grid Creates a coordinate grid data structure used by FOCUS for various calculations.
 set_excitation_function A function to create an excitation function suitable for use with transient_pressure and other transient pressure calculation functions.
 set_fdtsd_excitation A function to create an excitation function for use in Frequency Domain TimeSpace Decomposition (FDTSD) calculations.
 set_time_samples Create a time sample struct for use with transient functions.

ContinuousWave
 bioheat_transfer This function uses the Bioheat Transfer Equation to calculate the temperature rise at each point in a medium.
 cw_angular_spectrum This function uses the Angular Spectrum Approach to quickly calculate 3D continuouswave pressures given an intial pressure field.
 cw_intensity This function is used to calculate the average intensity of a continuouswave pressure field.
 cw_power This function is used to calculate the power of a continuouswave pressure field.
 cw_pressure This function is used to calculate continuouswave pressures with the Fast Nearfield Method in FOCUS.

Transient
 impulse_response Calculates the impulse response of a transducer array.
 transient_pressure Calculates the transient pressure field from an arbitrary transducer array using the Fast Nearfield Method and TimeSpace Decomposition or Frequency Domain TimeSpace Decomposition, depending on the input signal.


Focusing
 set_time_delays Determine the time delays required to focus a transducer array at a given point. Time delays calculated with set_time_delays may fall between temporal samples unless the sampling frequency is provided, in which case the delays are shifted to fit the temporal grid (digitized) rather than being allowed to fall between temporal samples.
 set_phases This function is used to apodize transducer arrays by setting the amplitudes of the individual transducers.
 set_apodization This function is used to apodize transducer arrays by setting the amplitudes of the individual transducers.
 find_single_focus_phase Calculates phase shifts to focus a transducer array at a given point.
 find_multiple_focus_phase Calculates phase shifts to focus a transducer array at the given points.

Supplementary

CW Pressure Calculations
 farfield_cw Calculates the farfield continuouswave pressure generated by a transducer array.
 farfield_cw_parfor Calculates the farfield pressure field generated by a transducer array.
 fnm_call This function is the gateway between the Matlab and C++ binary. It does minimal error checking to ensure enough arguments are being passed.
 fnm_cw This function is the C++ MEX file that performs continuouswave calculations using the Fast Nearfield Method.
 fnm_run This function is a guided function that does error checking and sanity checks on the input before feeding the information to the C++ binary to get the answer.
 fnm_cw_apodized Computes the pressure from pistons or arrays under continuous wave excitation in homogeneous media.
 fnm_cw_parfor Calculate a pressure field using the Fast Nearfield Method and multple threads.
 fnm_cw_single Computes the pressure from pistons under continuous wave excitation in homogeneous media using single precision floating point numbers.
 fnm_cw_sse This function is the C++ MEX file that performs continuouswave calculations using the Fast Nearfield Method and Streaming SIMD Extensions (SSE).
 kzk_cw Calculates the continuouswave pressure field from an arbitrary transducer array using the KZK equation.
 radiator_cw Unable to load function documentation from /egr/sites/www.egr.msu.edu/cgigroups/fultrasweb/web/documentation/functions/tex/radiator_cw.tex.
 rayleigh_cw Calculates pressure field generated by a transducer array in homogeneous media using the RayleighSommerfeld Integral.
 rayleigh_cw_apodized Calculates pressure field generated by a transducer array in homogeneous media using the RayleighSommerfeld Integral.
 rayleigh_cw_parfor Calculates pressure field generated by a transducer array in homogeneous media using the RayleighSommerfeld Integral.
 rayleigh_cw_sse Calculates pressure field generated by a transducer array in homogeneous media using the RayleighSommerfeld Integral and Streaming SIMD Extensions (SSE).

Transient Pressure Calculations
 fnm_transient Calculates the transient pressure field from an arbitrary transducer array using the Fast Nearfield Method.
 fnm_transient_call Calculates the transient pressure field from an arbitrary transducer array using the Fast Nearfield Method.
 fnm_transient_parfor Calculates the transient pressure field from an arbitrary transducer array using the Fast Nearfield Method.
 fnm_tsd Calculates the transient pressure field from an arbitrary transducer array using the Fast Nearfield Method and TimeSpace Decomposition or Frequency Domain TimeSpace Decomposition, depending on the input signal.
 fnm_tsd_parfor Calculates the transient pressure field from an arbitrary transducer array using the Fast Nearfield Method.
 impulse_response_parfor Calculates the impulse response of a transducer array.
 kzk_transient Calculates the transient pressure field from an arbitrary transducer array using the KZK equation.
 rayleigh_transient Calculates pressure field generated by a transducer array in homogeneous media using the RayleighSommerfeld Integral.
 rayleigh_transient_parfor Calculates pressure field generated by a transducer array in homogeneous media using the RayleighSommerfeld Integral.
 find_ndiv This function calculates the number of Gaussian quadratures needed to reach an arbitrary tolerance.
 fftw_asa This function is the C++ binary that implements the Angular Spectrum Approach. It should not be used in any scripts or used directly, as the interface can change. Use asa_call to ensure consistency. Documentation has been omitted. This is a mex function, if it doesn't run please email focus@egr.msu.edu for help.
 get_chirp Returns a set of time points describing a linear chirp between two frequencies.
 layerasa This function uses the Angular Spectrum Approach to perform calculations in layered media.
 npsr Unable to load function documentation from /egr/sites/www.egr.msu.edu/cgigroups/fultrasweb/web/documentation/functions/tex/npsr.tex.


Utilities
 compare_transient_pressures This function calculates the peak error between two transient pressure fields.
 get_apodization This function is used get a matrix containing the amplitudes of all elements of a transducer array.
 get_phases This function is used get a matrix containing the phases of all elements of a transducer array.
 get_time_delays This function is used get a matrix containing the time delays of all elements of a transducer array.
 pause2 This is a call back function used by the C++ binary to force an update of the Matlab display buffer. It should not be changed or deleted under any circumstance. If this function is missing, the program WILL NOT WORK.
 plot_transient_pressure Plots the amplitude of each element of a transducer array.
 rotate_vector_forward Interprets Euler angles to rotate vectors.
 trans_rot This is an internal function used by draw_array and its related functions. Users are not expected to use this function. It is designed to interpret Euler angles when drawing transducer arrays in MATLAB.

Deprecated
 asa_call This function is a gateway to the C++ function that calculates the 3D pressure using the Angular Spectrum Approach.
 asa_run Identical to asa_call but with more error checking and some sanity checking to ensure a proper calculation will occur.
 create_rect_enclosed_csa This function creates a fullyenclosed cylindrical section array of rectangular transducers.
 set_temporal_coordinate_grid Creates a coordinate grid for use with transient functions.
 set_parameters Create a parameter struct for use with FNM functions.
 set_digitized_time_delays Determine the time delays needed to focus a transducer array at the given point. Time delays are shifted to fit the temporal grid rather than being allowed to fall between temporal samples.
 make_tissuestruct Create a structure representing multiple layers of different tissues.
 get_tissuestruct Create a structure representing multiple layers of different tissues.
 get_pressure Extracts a twodimensional pressure plane from the threedimensional pressure field returned by FOCUS functions (e.g. fnm_call).
 find_phase This function finds a phase adjustment for each transducer such that the phase of all transducers at a given point is the same. This function will likely undergo some significant changes in the near future, but the overall form should remain the same.
