【热力学】3D 布朗运动(matlab实现)

三维布朗运动在Matlab中的快速仿真与平均值计算
本文介绍了如何使用Matlab实现三维布朗运动的快速仿真,并提供了计算初始和最终位置间欧几里得距离的代码。通过示例展示了如何计算给定时间T下的平均值,并附带了相应的代码段和参考文献。

💥💥💞💞欢迎来到本博客❤️❤️💥💥

🏆博主优势:🌞🌞🌞博客内容尽量做到思维缜密,逻辑清晰,为了方便读者。

⛳️座右铭:行百里者,半于九十。

📋📋📋本文目录如下:🎁🎁🎁

目录

💥1 概述

📚2 运行结果

🎉3 参考文献

🌈4 Matlab代码实现

💥1 概述

该仿真演示了三维布朗运动的快速实现,输出是初始位置和最终位置之间的欧几里得距离。
若要计算 T 运行的平均值,请在“命令”窗口中运行以下代码:
>>T=100;
>>n=1:T
>>布朗运动;
>>关闭;
>>D(n)=d;
>>结束
>>图;plot(D),title('距离');
>>dd=平均值(D)

📚2 运行结果

部分代码:

% This simulation illustrates a fast implementation of three dimensional
% Brownian motion, the output is the Euclidean distance between initial
% and final positions.
% To calculate the mean value of T runs, run the following code in the 
% Command window :
%
% >>T=100;
% >> for n=1:T
% >>Brownianmotion;
% >>close;
% >>D(n)=d;
% >>end
% >>figure; plot(D),title(' Distance ');
% >>dd=mean(D)

% (c) Youssef Khmou, Applied mathematics, may 2015.

N=1000;
x=cumsum(randn(1,N));
y=cumsum(randn(1,N));
z=cumsum(randn(1,N));

h=figure;
view(3);
set(gca,'GridLineStyle','--')
hold on;
plot3(x,y,z,'LineWidth',1.5)
axis([min(x) max(x) min(y) max(y) min(z) max(z)]);
xlabel('x');
ylabel('y');
zlabel('z');

🎉3 参考文献

文章中一些内容引自网络,会注明出处或引用为参考文献,难免有未尽之处,如有不妥,请随时联系删除。

[1]张佳欣. “热力学第2.5定律”挑战传统预期[N]. 科技日报,2024-02-09(004).

[2]Gao F ,Oosterlee W C ,Zhang J . A deep learning-based Monte Carlo simulation scheme for stochastic differential equations driven by fractional Brownian motion[J]. Neurocomputing,2024,574.

🌈4 Matlab代码实现

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值