unlike Matlab, err in catch(err) is compulsory