参考:
https://blog.csdn.net/liu_feng_zi_/article/details/107341415
https://www.cnblogs.com/iDove/p/4103231.html
test.f90
program test
print *,"hello world"
end program
普通运行:
ifort test.f90
并行运行:
mpirun -np 2 ./test.f90
错误如下:
mpirun was unable to launch the specified application as it could not access
or execute an executable:
Executable: ./test.f90
Node: localhost
while attempting to start process rank 0.
猜测,可能是我安装的时候,没有安装例子,或者有,但是我也不知道路径。也就是说,这里执行例子时,需要添加绝对路径。
我自己在当前目录下写了个测试程序进行测试
#include <mpi.h>