作业帮 > 综合 > 作业

关于mathematica

来源:学生作业帮 编辑:作业帮 分类:综合作业 时间:2024/05/21 13:25:20
关于mathematica
我想用mathematica 研究二维随机行走,想随机走N次后把最终位置的那个点画出来,并且重复做M次,所有点画在一张图上
谁能提供个程序啊
walk[n_,m_] :=
Table[Accumulate[RandomReal[{-1,1},{n,2}]][[-1]],{i,m}]
walk[200,300] // ListPlot
看帮助文件ref/Accumulate