Installing Packages

Description: Description: Description: Description: Description: Description: Description: Description: Description: AceFEM Description: Description: Description: Description: Description: Description: Description: Description: AceGen

 

 


Table of Contents

Installation procedure. 2

Operating system requirements. 2

Using AceGen. 3

Using AceFEM and AceShare. 4

Tutorials and manual 5

Default C compiler 5

Windows. 5

Linux. 5

Mac. 6

For advanced users. 6

Other C compilers. 6

Compiling in linking the generated C, Fortran and Matlab files. 6

 


 

Installation procedure

 

1.     download installation file as instructed

2.     unzip the installation file to arbitrary directory
(the option "Use folder names" in WinZip must be switched on!)

3.     If Mathematica is opened, completely close Mathematica.

4.     Run the Mathematica notebook  Install.nb.

 

The packages are by default installed to $UserBaseDirectory. The user base installation directory $UserBaseDirectory is set by Mathematica (e.g. for Windows 7 $BaseDirectory is set to "C:\\Users\\username\\AppData\\Roaming\\Mathematica"). In this case, the packages can be used only by the current user.

Alternatively, the packages can be installed to $BaseDirectory. $BaseDirectory is normally accessible to all users (network installation). User should be able to read and write to $BaseDirectory directory at the time of installation. This usually requires administrators’ privileges.

 

AceGen/AceFEM packages are automatic code generation systems, thus they create new executable files and they run newly created executable files. PLEASE be certain that the account and the directory from which the packages are used do have proper privileges to create new executable files.  On the newer operating systems this might not be the default value for the new account!!! Sometimes the antivirus software might also prevent the use of Ace-packages. One does not need to be a computer expert to use Ace-packages, however one may need a help from the expert to set the proper privileges for the user account!

Additional instructions specific to the certain operating system are given in section Default C compiler.

 

Operating system requirements

The information about the version of operating system on which the executables were build is given during the installation procedure. Only 64 bit systems are supported. The latest version might not work on older versions of Mathematica or operating systems!!

 

Additional requirements

 

Windows 7: In order to use the Windows 7 operating system one needs to make the following update:

https://support.microsoft.com/en-us/help/2999226/update-for-universal-c-runtime-in-windows

 

Linux: Additional Linux component that is required, but not normally automatically installed is uuid-dev library.

 

Mac: Xcode package.

Using AceGen

 

1.     load the AceGen code generator with the command Get["AceGen`"]

  1. the AceGen palette will appear

 

Line Callout 3: open the AceGen help window and follow the tutorial lectures 

 

 

 


 

Using AceFEM and AceShare

 

  1. load the AceFEM finite element environment with the command Get["AceFEM`"]

2.     Line Callout 3: open the AceShare window and search for available built-in and on-line finite element solutions Line Callout 3: open the AceFEM help window and follow the tutorial lecturesthe AceFEM palette will appear

 


 

Tutorials and manual

 

  1. Tutorial lectures and manual are incorporated into the Mathematica´s help system.

 

  1. In order to get help for the specific command first highlight the command and then press the Help button at the top of the AceGen/AceFEM palette.

 

  1. Printable version of the manual and the tutorial lectures can be downloaded from the product web site

·       http://symech.fgg.uni-lj.si/User/AceGenPrint.pdf

·       http://symech.fgg.uni-lj.si/User/AceFEMPrint.pdf

 

Default C compiler

 

C compiler is not obligatory for the generation of the source codes by AceGen. However, the compiled codes would run significantly faster than the codes in native Mathematica or Matlab language.

Windows

On Windows the MinGW gcc is used by default. The MinGW compiler is collection of freely available and freely distributable Windows specific header files and import libraries combined with GNU toolsets. For more information see http://www.mingw.org/. The MinGW compiler is installed by AceGen installation procedure. DO NOT INSTALL YOUR OWN MinGW!

Linux

By default the installation looks for the existing version of the gcc C compiler.  The gcc C compiler is freely available for Linux. And is a part of standard installation procedure.

 

Additional component that is required but not normally automatically installed is uuid-dev library. See below a snapshot of the installation procedure under Ubuntu Linux and OpenSuSE.

Ubuntu

libuuid-devel_suse

OpenSuSE

Mac

The gcc C compiler is freely available for Mac systems, however not installed automatically. On the newer versions of Mac OS, the C compiler has to be installed additionally. User has to register first at the Apple site as an application developer, after that Xcode package can be downloaded. The gcc C compiler is a part of Xcode package.

For advanced users

Other C compilers

 

If the C compiler is not located automatically, then the user has to set the SMTCDirectory variable located in “Paths.m” file manually after the installation of the AceGen system. The “Paths.m” file is after the installation located at:

 

ToFileName[{$UserBaseDirectory, "Applications","AceGen","AceCommon"},"Paths.m"]

 

The information about the chosen compiler is stored as the

 

SMTCDirectory={"name","","path to 64-bit compiler"}

 

system variable in the initialization file “Paths.m”. The standard value for the SMTCDirectory variable is as follows:

 

OS

SMTCDirectory

Linux

SMTCDirectory={"Linux GCC","/usr/bin/gcc", }

Mac

SMTCDirectory={"Xcode","/usr/bin/gcc","/usr/bin/gcc"}

Windows
MinGW

SMTCDirectory={"MinGW","","...MinGW/MinGW64/bin/gcc.exe"}

 

 

Compiling in linking the generated C, Fortran and Matlab files

 

The header file SMS.h has to be available when compiling AceGen generated C or Fortran files. Source code of some supplementary routines is available in SMSUtility.c or SMSUtility.f file that has to be compiled and linked together with the user code.

C file

header

$UserBaseDirectory/Applications/AceGen/Include/C/SMS.h

supplementary routines

$UserBaseDirectory/Applications/AceGen/Include/C/SMSUtility.c

Matrix functions as a library

$UserBaseDirectory/Applications/AceGen/Include/C/libaceutilityXXX

XXX depends on OS and compiler

Fortran file

header

$UserBaseDirectory/Applications/AceGen/Include/Fortran/SMS.h

supplementary routines

$UserBaseDirectory/Applications/AceGen/Include/Fortran /SMSUtility.c

Matrix functions as a library

$UserBaseDirectory/Applications/AceGen/Include/Fortran/libaceutilityXXX

XXX depends on OS and compiler

Matlab file

header

not required

supplementary routines

not required

The user base installation directory $UserBaseDirectory is set by Mathematica.