rand('state',0)
本篇博文参考:http://ilovematlab.cn/thread-57952-1-1.htmlrand('state',0)Resets the generator to its initial state. rand('state',s)表示随机产生数的状态state,一般情况下不用指定状态。但是有的书籍作者为了让读者能够看到和他书本的同样结果,采用了设置state,rand('s