misc_linking-abaqus-visual-studio-and-fortan - ttnc...

14
www. .com Dr. Khazar Hayat, UOL Dr. Khazar Hayat Asst. Professor, Mechanical Eng. Dept. The University of Lahore (UOL), Pakistan [email protected] https://sites.google.com/site/khazarhayat/

Upload: lamkhuong

Post on 06-Feb-2018

259 views

Category:

Documents


6 download

TRANSCRIPT

Page 1: misc_linking-abaqus-visual-studio-and-fortan - TTNC …ttncglobal.com/.../12/Misc_Linking-ABAQUS-VISUAL-STUDIO-and-FO… · o Intel Fortran compiler o Microsoft visual studio Abaqus

www.

.com

Dr. Khazar Hayat, UOL

Dr. Khazar HayatAsst. Professor, Mechanical Eng. Dept.

The University of Lahore (UOL), [email protected]

https://sites.google.com/site/khazarhayat/

Page 2: misc_linking-abaqus-visual-studio-and-fortan - TTNC …ttncglobal.com/.../12/Misc_Linking-ABAQUS-VISUAL-STUDIO-and-FO… · o Intel Fortran compiler o Microsoft visual studio Abaqus

www.

.com

Dr. Khazar Hayat, UOL

o Abaqus

o Intel Fortran compiler

o Microsoft visual studio

Abaqus

6.10/6.11/6.12 Abaqus 6.13

Intel Visual

Fortran 11.1

Intel Visual Fortran

11.1

Intel Parallel Studio

XE10

Intel Parallel Studio

XE13

MSV Studio 2008 MSV Studio 2008 MSV Studio 2010 MSV Studio 2012

PS:• Microsoft Visual Studio Professional editions should be used. EPXRESS editions are

not going to work.• Note that Intel Parallel Studio XE13 best works with MS VS2012• It is a common misconception that linking-setup is sensitive to the order of

installation, which is not true however. The only think to keep in mind is that theFortran Compiler should be installed after installing Microsoft Visual Studio in orderto integrate the Compiler with MS VS. Abaqus could be installed either before orafter installing these two.

Page 3: misc_linking-abaqus-visual-studio-and-fortan - TTNC …ttncglobal.com/.../12/Misc_Linking-ABAQUS-VISUAL-STUDIO-and-FO… · o Intel Fortran compiler o Microsoft visual studio Abaqus

www.

.com

Dr. Khazar Hayat, UOL

MS Visual Studio

o First, install Microsoft Visual Studio 2008/2012 (All Components)

Fortran Compiler

o Then, install Intel FORTRAN Compiler/Intel Parallel Studio

o Must check the INTEGRATE WITH VISUAL STUDIO option during theinstallation

Abaqus

o Lastly, install Abaqus 6.13 (i.e. A step by step video showing theinstallation of Abaqus 6.13 can be found in the link below:http://www.youtube.com/watch?v=YRt4QHQBLiw)

Page 4: misc_linking-abaqus-visual-studio-and-fortan - TTNC …ttncglobal.com/.../12/Misc_Linking-ABAQUS-VISUAL-STUDIO-and-FO… · o Intel Fortran compiler o Microsoft visual studio Abaqus

www.

.com

Dr. Khazar Hayat, UOL

Step 1: Combining FORTRAN Compiler & Visual Studio

Step 2: Invoking FORTRAN Compiler & Visual Studio

Step 3: Linking verification

Step 4: Setting Optimized Running (Optional)

Page 5: misc_linking-abaqus-visual-studio-and-fortan - TTNC …ttncglobal.com/.../12/Misc_Linking-ABAQUS-VISUAL-STUDIO-and-FO… · o Intel Fortran compiler o Microsoft visual studio Abaqus

www.

.com

Dr. Khazar Hayat, UOL

Step 1

o Locate following Fortran & Visual Studio files

o Add the file paths to your computer's environment variables that canbe found by clicking “Properties” of Computer and then choosing“Advanced System Settings”, then, select “Environment Variables”.And, finally, fine the variable named "Path" and update it.

File type Typical path

ifortvars.bat

(Fortran)

C:\Program Files (x86)\Intel\Compiler\11.1\048\bin\

C:\Program Files (x86)\Intel\ComposerXE-2011\bin\

vcvarsamd64.bat

(Visual Studio)

C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\bin\amd64

C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\bin\amd64

Page 6: misc_linking-abaqus-visual-studio-and-fortan - TTNC …ttncglobal.com/.../12/Misc_Linking-ABAQUS-VISUAL-STUDIO-and-FO… · o Intel Fortran compiler o Microsoft visual studio Abaqus

www.

.com

Dr. Khazar Hayat, UOL

Step 2a:

o Locate the Abaqus Command file & CAE file. The paths to locatethese files usually looks like this: :

Version Typical paths of Abaqus Command file & CAE file

6.12 C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Abaqus 6.12-1

6.13 C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Abaqus 6.13-1

Page 7: misc_linking-abaqus-visual-studio-and-fortan - TTNC …ttncglobal.com/.../12/Misc_Linking-ABAQUS-VISUAL-STUDIO-and-FO… · o Intel Fortran compiler o Microsoft visual studio Abaqus

www.

.com

Dr. Khazar Hayat, UOL

Step 2b:

o Abaqus Command file: Right Click and then choose properties. OnTarget you will see this given path, and needs to be changed asfollowing:

o Save changes, after modification.

Target path

Given C:\Windows\SysWOW64\cmd.exe /k

Modified

"C:\Program Files (x86)\Intel\Compiler\11.1\048\bin\ifortvars.bat" intel64

vs2008 & C:\Windows\SysWOW64\cmd.exe /k

"C:\Program Files (x86)\Intel\ComposerXE-2011\bin\ifortvars.bat" intel64

vs2010 & C:\Windows\SysWOW64\cmd.exe /k

Note: Notice that the icon that the shortcut icon that used to be a black display has nowchanged and shows some gears. This is deliberately made to happen so as todistinguish if the Abaqus Command has been setup correctly.

Page 8: misc_linking-abaqus-visual-studio-and-fortan - TTNC …ttncglobal.com/.../12/Misc_Linking-ABAQUS-VISUAL-STUDIO-and-FO… · o Intel Fortran compiler o Microsoft visual studio Abaqus

www.

.com

Dr. Khazar Hayat, UOL

Step 2c:

o Abaqus CAE file: Right Click and then choose properties. On Targetyou will see this given path, and needs to be changed as following:

o Save changes, after modification.

Target paths of Abaqus CAE 6.12/6.13

Given• C:\SIMULIA\Abaqus\Commands\abq6121.bat cae || pause

• C:\SIMULIA\Abaqus\Commands\abq6131.bat cae || pause

Modified

• "C:\Program Files (x86)\Intel\Compiler\11.1\048\bin\ifortvars.bat" intel64

vs2008 & C:\SIMULIA\Abaqus\Commands\abq6121.bat cae || pause

• "C:\Program Files (x86)\Intel\ComposerXE-2011\bin\ifortvars.bat" intel64

vs2010 & C:\SIMULIA\Abaqus\Commands\abq6131.bat cae || pause

Page 9: misc_linking-abaqus-visual-studio-and-fortan - TTNC …ttncglobal.com/.../12/Misc_Linking-ABAQUS-VISUAL-STUDIO-and-FO… · o Intel Fortran compiler o Microsoft visual studio Abaqus

www.

.com

Dr. Khazar Hayat, UOL

Step 3:

o Open Abaqus Command window & type:

Command Description

abaqus verify –all To verify all Abaqus products.

abaqus verify –user_stdTo verify Abaqus Standard with user subroutines has been set

up correctly

Page 10: misc_linking-abaqus-visual-studio-and-fortan - TTNC …ttncglobal.com/.../12/Misc_Linking-ABAQUS-VISUAL-STUDIO-and-FO… · o Intel Fortran compiler o Microsoft visual studio Abaqus

www.

.com

Dr. Khazar Hayat, UOL

Step 4:

o If you try to run a sample job with a user subroutine, you may noticethat the following messages appear in the .log file.

o Solution to circumvent automatic cpu dispatching and eliminatethese messages, find the Abaqus environment file (i.e.abaqus_v6.env) located in the following directory, and open with atext editor:

(col. 18) remark: <SUBROUTINE NAME> has been targeted for automatic cpu dispatch

Version Typical paths of env. file

6.12 C:\SIMULIA\Abaqus\6.13-1\SMA\site

6.13 C:\SIMULIA\Abaqus\6.12-1\SMA\site

Page 11: misc_linking-abaqus-visual-studio-and-fortan - TTNC …ttncglobal.com/.../12/Misc_Linking-ABAQUS-VISUAL-STUDIO-and-FO… · o Intel Fortran compiler o Microsoft visual studio Abaqus

www.

.com

Dr. Khazar Hayat, UOL

Step 4:

o Scroll down to find the compile_fortran command and remove the# symbols before the commands. (This symbol is the commentdescriptor in PYTHON®. By removing it, you activate internaloptimization and debugging while compiling your source code.

Note:• If your processor is not multi-threaded then those (‘/Od’,’/Ob0’) commands

may not appear in the env file or the # ymbols may be already missing.• Between the commands '/Od', '/Ob0' there must be a comma descriptor “,”.

If one does not exist, then you may have to insert in manually.

Page 12: misc_linking-abaqus-visual-studio-and-fortan - TTNC …ttncglobal.com/.../12/Misc_Linking-ABAQUS-VISUAL-STUDIO-and-FO… · o Intel Fortran compiler o Microsoft visual studio Abaqus

www.

.com

Dr. Khazar Hayat, UOL

Error Description:

o “The executable standard.exe aborted with system error code1073741819”

Caused by Intel Haswell (4th-5th gen) processors

Solution:

o Go to the directory C:\SIMULIA\Abaqus\6.13-x\code\bin

o Scroll down to find the file named “mkl_avx2.dll”

o Just rename it to “mkl_avx2.dll.11.0.0.1”

If error persist then:

o there is some error in the code UMAT, and

it is required to thoroughly checked.

Page 13: misc_linking-abaqus-visual-studio-and-fortan - TTNC …ttncglobal.com/.../12/Misc_Linking-ABAQUS-VISUAL-STUDIO-and-FO… · o Intel Fortran compiler o Microsoft visual studio Abaqus

www.

.com

Dr. Khazar Hayat, UOL

All this information related to “Linking Abaqus, Fortran

compiler and MS Visual Studio” has been provided by:

Mr. Nick Vasios ([email protected])

Senior Undergraduate Mechanical Engineer

University of Thessaly, School of Engineering

Page 14: misc_linking-abaqus-visual-studio-and-fortan - TTNC …ttncglobal.com/.../12/Misc_Linking-ABAQUS-VISUAL-STUDIO-and-FO… · o Intel Fortran compiler o Microsoft visual studio Abaqus

www.

.com

Dr. Khazar Hayat, UOL

Dr. Khazar HayatAsst. Professor, Mechanical Eng. Dept.

The University of Lahore (UOL), [email protected]

https://sites.google.com/site/khazarhayat/