Ubuntu16.04 安装 OpenFOAM4.0

Ubuntu16.04 安装 OpenFOAM4.0

按照以下官网安装步骤操作。

https://openfoam.org/download/4-0-ubuntu/

sudo add-apt-repository http://dl.openfoam.org/ubuntu

sudo sh -c “wget -O - http://dl.openfoam.org/gpg.key | apt-key add -”

sudo apt-get update

sudo apt-get -y install openfoam4

// 执行这一步时网络一定要好,否则会中断下载。(或者搬梯子) 作者这一步执行了好多遍,终于完成了。作者这里比较慢,以小时计。

User Configuration

gedit ~/.bashrc

在.bashrc文件最后输入如下内容:
source /opt/openfoam4/etc/bashrc

// Note 1: If a similar line has already been added to the user’s .bashrc file, e.g. for a previous version of OpenFOAM, then the line should be deleted or, alternatively, commented out by inserting a # at the beginning of the line.
// 由于是 ~/.bashrc,因此只针对某个用户有用。如果其他用户想使用OpenFOAM时,需要对其他用户的 .bashrc 进行配置。

打开一个新终端查看安装是否成功:
simpleFoam -help

// Note 2: If a user wishes to execute simpleFoam in the same terminal window, they must first register the change to the .bashrc file by typing at the terminal prompt (note the dots): source $HOME/.bashrc

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

ou_no

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

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

余额充值