
454 Accelerating MATLAB
®
Performance
where accuracy can be traded for speed.* In many cases, NAG is faster yet just as accurate
as MATLAB. For example, in another Mike Croucher article,
1324
NAG’s e01bf() was 9x faster
and gave identical results to MATLAB’s interp1 function.
†
Objective functions (such as fsolve_obj_NAG above) used by NAG routines some-
times require information in addition to the input parameters in the standard interface.
MATLAB callbacks enable using the {} mechanism for passing such extra data, but this is
currently not supported by NAG. We can use alternatives such as global variables, or data
attached to GUI handles.
‡
Howe ...