Replacement for Matlab's SYSTEM command