Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.

Fortran Compiler for Ansys

DAYENG66
초급자
7,478 조회수

I am trying to use and Ansys batch file to compile some user programmable features in ANSYS.  I am using a .bat file from ANSYS to create the dynamically linked library.  When I did this with a previous employer it required a very old version of Visual Studio (VS2012 with VS2012 C++ update4) and then I installed Intel Parallel Studio XE 2015) with the licenses purchased at a fairly high cost.

It seems that newer ANSYS version are a more current.  The current Ansys version calls for.  Microsoft Visual Studio Professional 2017 Version 15.0 (including the MS C++ compiler), Intel C++ 2019.3.203 and Intel Visual FORTRAN 2019.3.203.  How do I get these versions of Intel C++ and Fortran?  I can install Intel® Fortran Compiler Classic 2021.1 and Intel® Fortran Compiler (Beta), but don't see 2019.3.203.  It seems like these compilers installed at no cost (could that be true?)

When I attempt with the "classic fortran" it does not recognize the ifort command.  I have the following up environment variable.  IFORT_COMPILER19=C:\Program Files (x86)\Intel\oneAPI\compiler\2021.1.2\windows\

I will attach the .bat file as a .txt.  I suspect I am doing something silly,  or I don't have the right installation.  I notice in the .bat file the following line where ifort_home is the environment variable above.   I can't find compilervars.bat in that location.

call "%IFORT_HOME%\bin\compilervars.bat" %IFORT_PLATFORM% %VSVER%

 

 

0 포인트
1 솔루션
Steve_Lionel
명예로운 기여자 III
7,468 조회수

The oneAPI file is called setvars.bat - different from before.

원본 게시물의 솔루션 보기

0 포인트
8 응답
DAYENG66
초급자
7,474 조회수

It is giving me trouble attaching the .bin file as a .txt file

0 포인트
Steve_Lionel
명예로운 기여자 III
7,469 조회수

The oneAPI file is called setvars.bat - different from before.

0 포인트
DAYENG66
초급자
7,452 조회수

Hmm.  Perhaps ansys revised their ansusershared.bat file between the version I have on my laptop and that of my desktop.  Unfortunately the student version which I am using currently does not have the option to custom install.  So I had to copy the customization folder that included the .bat file

I changed my environment variable path since that file is located in an earlier folder, and modified the .bat file.  It executes no but aborts during compilation.  In the past, it was a bit more graceful with compilation errors.  After fixing the error and rerunning it needed to install .NET Framework 3.5 )includes .Net 2.0 and 3.0) but seems to have work.   I will test it and report back.  Thanks for your help.

 

0 포인트
mecej4
명예로운 기여자 III
7,439 조회수

To most of us, excepting the few who are also users of Ansys (and such third party packages), there is little to gain from reading vendor batch files such as the one that you attached. You will have to read the Ansys documentation or consult other users of Ansys and modify those batch files to make Ansys work with a different version of the Intel compiler than the one referenced in the Ansys documentation.

0 포인트
DAYENG66
초급자
7,420 조회수

This is actually the 3rd time I have gotten ANSYS user programmable features to compile.  The first time I had an IT department set it up.  The 2nd time an IT guy purchased the license and I set it up.  This time I am unemployed and on my own.  Each time the methodology changed a little.   Ansys help can best be described as "bread crumbs" to help you find your way.  I am just really pleased that I was able to do it this time without buying anything.  I recall the compilers being rather pricey before.  The advice to look for the setvars file was exactly what I needed.

I have confirmed that it successfully created the .dll files (USERCREEP in this case).

0 포인트
YaxiongChen
초급자
6,833 조회수

Do I have to pay before I have install the fortran compiler? 

0 포인트
Barbara_P_Intel
6,748 조회수

The oneAPI compilers, including Fortran, are free, unless you would like Priority Support.  See this page.  

If you want to pay for Priority Support, see this page.

Fortran is included in the HPC Toolkit.

 

0 포인트
YaxiongChen
초급자
6,714 조회수

I am trying to link ansys with fortran. They highly recommend the specific version of FORTRAN. Do you know if I can get a license for the older product Intel® Parallel Studio XE Composer Edition for Fortran and C++ Windows*?  Currently it only supports those who have registered for it before. My company are willing to buy it if I can show them it works. 

0 포인트
응답