改变 STREAMING 部分--基于MATLAB的LBM代码

本文介绍了一种改进的基于MATLAB的LBM(格子玻尔兹曼)代码,着重解决了之前版本存在的震荡问题和长时间运行后出现的问题。通过不再使用circshift函数,代码的稳定性和效率得到了提升。示例代码展示了围绕圆柱体的通道流动,包括初始化条件、边界条件和碰撞流步的处理。
摘要由CSDN通过智能技术生成

      有啥LBM相关问题Feel free to tell us~~毕竟群众力量大嘛~格子玻尔兹曼救星QQ群:293267908。

      之前上传的代码有震荡问题,而且运行时间久了就爆炸。。。昨天重写传播部分,不再使用circshift函数之后就解决了。

 

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% cylinder.m: Channel flow past a cylinderical        
%             obstacle, using a LB method            
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Lattice Boltzmann sample, written in C
% Copyright (C) 2006 Jonas Latt
% Address: Rue General Dufour 24,  1211 Geneva 4, Switzerland
% E-mail: Jonas.Latt@cui.unige.ch
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% This program is free software; you can redistribute it and/or
% modify it under the terms of the GNU General Public License
% as published by the Free Software Foundation; either version 2
% of the License, or (at your option) any later version.
% This program is distributed in the hope that it will be useful,
% but WITHOUT ANY WARRANTY; without even the implied warranty of
% MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See

评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值