The function, lincos() is missing a function, [ierr,scicos_ver,scs_m]=update_version(scs_m) replacing this with a function, function [a,b,c]=update_version(s) a=0; // err is zero b=s.version; // extract the version c=s; // just copy s endfunction; works. However, I believe this is not what was intended. tomdean