Author : 刘旭东
许可授权
/*
* Copyright (C) Daniel tulips liu
*
* This 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 3 of the License, or
* (at your option) any later version.
*
* It 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 the
* GNU General Public License for more details.
*
* For a copy of the GNU General Public License,
* see <http://www.gnu.org/licenses/>.
*/
MATLAB C++ 编译器以及 interl FORTRAN编译器
>> mex -setup
MEX 配置为使用 'MinGW64 Compiler (C)' 以进行 C 语言编译。
要选择不同的 C 编译器,请从以下选项中选择一种命令:
Intel Parallel Studio XE 2018 with Microsoft Visual Studio 2017 (C) mex -setup:D:\Softwares\Polyspace\R2020a\bin\win64\mexopts\intel_c_18_vs2017.xm l C
MinGW64 Compiler (C) mex -setup:C:\Users\tulipsliu\AppData\Roaming\MathWorks\MATLAB\R2020a\mex_C_win64.xm l C
Microsoft Visual C++ 2017 (C) mex -setup:D:\Softwares\Polyspace\R2020a\bin\win64\mexopts\msvc2017.xm l C
要选择不同的语言,请从以下选项中选择一种命令:
mex -setup C++
mex -setup FORTRAN
已将 options 文件 'C:\Users\tulipsliu\AppData\Roaming\MathWorks\MATLAB\R2020a\mex_C_win64.xm l' 重命名为 'C:\Users\tulipsliu\AppData\Roaming\MathWorks\MATLAB\R2020a\mex_C_win64_backup.xm l'。
MEX 配置为使用 'Microsoft Visual C++ 2017 (C)' 以进行 C 语言编译。
MEX 配置为使用 'Intel Parallel Studio XE 2018 for Fortran with Microsoft Visual Studio 2017' 以进行 FORTRAN 语言编译。
>>
刚配置好编译器,这样DSGE建模当前国际最流行的使用编译器编译应该可以。
后面的发帖会以编译 FORTRAN 的程序 steady_state.f90 文件试一试效果。