Difference between revisions of "Installation"
(10 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
== Installation Manual == | == Installation Manual == | ||
The installation | The installation manual can be downloaded from the feap project site at [http://projects.ce.berkeley.edu/feap http://projects.ce.berkeley.edu/feap]. | ||
== Installation Videos == | == Installation Videos == | ||
There are two installation videos demonstrating a [https://www.youtube.com/watch?v=7QAh6QvOT6s windows install] and one demonstrating a [https://www.youtube.com/watch?v=_ohQ__rqq3Y Mac/Unix/Linux] install. | There are two installation videos demonstrating a [https://www.youtube.com/watch?v=7QAh6QvOT6s windows install] and one demonstrating a [https://www.youtube.com/watch?v=_ohQ__rqq3Y Mac/Unix/Linux] install. | ||
== Compilers == | |||
FEAP should compile with most any modern compiler. Compiles have been tested on Mac computers using the GNU Compiler Compilation, gcc/gfortran, (versions 6 through 9.2) as well as with Intel compilers (2019 Update 5); on Windows computers with Intel Compilers (2018 Update 2) with Visual Studio Community 2017; and on Linux computers using the GNU Compiler Compilation, gcc/gfortran, (version 9.3.1). Newer and older compilers should all work fine, but note that pre-version 6 GNU compilers will no longer work. | |||
== Alternative Method for Installation of FEAP on Windows == | == Alternative Method for Installation of FEAP on Windows == | ||
The following workflow demonstrates how to compile and build FEAP 8.5 from source code. The advantage of this new method is that you can build the FEAP main program and all the subroutines at once. In addition, you can run FEAP in debug mode in Visual Studio just like other programs. The workflow has been tested with FEAP 8.5 source code and Intel Fortran Compiler 2013 in Microsoft Visual Studio Pro 2012. Other versions of Intel Fortran Compiler or Visual Studio may also work. These steps may also be used to build an old version of FEAP. If you are compiling | The following workflow demonstrates how to compile and build FEAP 8.5 from source code. The advantage of this new method is that you can build the FEAP main program and all the subroutines at once. In addition, you can run FEAP in debug mode in Visual Studio just like other programs. The workflow has been tested with FEAP 8.5 source code and Intel Fortran Compiler 2013 in Microsoft Visual Studio Pro 2012. Other versions of Intel Fortran Compiler or Visual Studio may also work. These steps may also be used to build an old version of FEAP. If you are compiling FEAPpv source code, see here [https://github.com/keweili/feappv#compiling-and-installation-of-feappv-on-windows]. | ||
In this method, we will create a Visual Studio solution which consists of two projects: the FEAP main program and a static library. At first, we will create a QuickWin Application for FEAP main program and then another project for the static library. | |||
1. Open Visual Studio. | 1. Open Visual Studio. | ||
Line 32: | Line 36: | ||
<li>Select Fortran on the left, then General</li> | <li>Select Fortran on the left, then General</li> | ||
<li>Add following FEAP include directories to the '''Additional Include Directories''': <br / ><code>C:\users\xxx\feap\ver85\include</code> <br /> and the appropriate directory for 32-bit Windows machine: <br /> <code>C:\users\xxx\feap\ver85\include\integer4</code> <br /> or for 64-bit Windows machine <br /> <code>C:\users\xxx\feap\ver85\include\integer8</code>. <br /> You only need one of them for your machine. </li> | <li>Add following FEAP include directories to the '''Additional Include Directories''': <br / ><code>C:\users\xxx\feap\ver85\include</code> <br /> and the appropriate directory for 32-bit Windows machine: <br /> <code>C:\users\xxx\feap\ver85\include\integer4</code> <br /> or for 64-bit Windows machine <br /> <code>C:\users\xxx\feap\ver85\include\integer8</code>. <br /> You only need one of them for your machine. </li> | ||
'''As of version 8.6, one only selects <code>...\include</code>. The interger4/integer8 option has been removed and only 64-bit machines are supported''' | |||
</ol> | </ol> | ||
Line 49: | Line 54: | ||
<li>Add following FEAP include directories to the '''Additional Include Directories''': <br /> <code>C:\users\xxx\feap\ver**\include</code> <br /> and the appropriate directory for 32-bit Windows machine <br /> <code>C:\users\xxx\feap\ver**\include\integer4</code>, <br /> or 64-bit Windows machine, <br /> <code>C:\users\xxx\feap\ver**\include\integer8</code> <br /> Again, you only need one of them. | <li>Add following FEAP include directories to the '''Additional Include Directories''': <br /> <code>C:\users\xxx\feap\ver**\include</code> <br /> and the appropriate directory for 32-bit Windows machine <br /> <code>C:\users\xxx\feap\ver**\include\integer4</code>, <br /> or 64-bit Windows machine, <br /> <code>C:\users\xxx\feap\ver**\include\integer8</code> <br /> Again, you only need one of them. | ||
</li> | </li> | ||
'''As of version 8.6, one only selects <code>...\include</code>. The interger4/integer8 option has been removed and only 64-bit machines are supported''' | |||
</ol> | </ol> | ||
Line 79: | Line 85: | ||
The program is ready to use. If you have any questions or comments about this section of FEAP wiki, please post it at FEAP forum at [http://feap.berkeley.edu/forum/index.php?topic=2124] | The program is ready to use. If you have any questions or comments about this section of FEAP wiki, please post it at FEAP forum at [http://feap.berkeley.edu/forum/index.php?topic=2124] | ||
== PETSc == | |||
If you wish to run parallel computations, then you will need a working version of [https://www.mcs.anl.gov/petsc/ PETSc]. For FEAP version 8.6, we have tested it with PETSc version 3.13.2. | |||
Our typical configuration for PETSc is as follows | |||
<pre> | |||
./configure --download-{parmetis,superlu_dist,openmpi,ml,hypre,metis,mumps,scalapack,blacs} | |||
</pre> | |||
Of these only parmetis and metis are required. We use openmpi as our message passing implementation but mpich or vendor implementations should be fine. | |||
== Common Installation Issues == | == Common Installation Issues == | ||
=== Incorrect pointer selection === | === Incorrect pointer selection === | ||
A very common installation problem is to select the wrong include files include/integer4 versus include/integer8. The [[Memprobe]] program can help with these issues. If you compile and run the program maintain/memprobe.c, it will provide you guidance on selecting the correct include directories. | A very common installation problem with versions 8.5 and earlier is to select the wrong include files include/integer4 versus include/integer8. The [[Memprobe]] program can help with these issues. If you compile and run the program maintain/memprobe.c, it will provide you guidance on selecting the correct include directories. | ||
'''As of version 8.6, the 32-bit pointer option has been removed. Only 64-bit pointer architectures are now supported.''' | |||
=== Should I change ipr in main/feapXY.f === | === Should I change ipr in main/feapXY.f === | ||
Line 109: | Line 126: | ||
</pre> | </pre> | ||
</blockquote> | </blockquote> | ||
In place of '6' use the most up-to-date stable version available for your computer. |
Latest revision as of 06:29, 18 June 2020
Installation Manual
The installation manual can be downloaded from the feap project site at http://projects.ce.berkeley.edu/feap.
Installation Videos
There are two installation videos demonstrating a windows install and one demonstrating a Mac/Unix/Linux install.
Compilers
FEAP should compile with most any modern compiler. Compiles have been tested on Mac computers using the GNU Compiler Compilation, gcc/gfortran, (versions 6 through 9.2) as well as with Intel compilers (2019 Update 5); on Windows computers with Intel Compilers (2018 Update 2) with Visual Studio Community 2017; and on Linux computers using the GNU Compiler Compilation, gcc/gfortran, (version 9.3.1). Newer and older compilers should all work fine, but note that pre-version 6 GNU compilers will no longer work.
Alternative Method for Installation of FEAP on Windows
The following workflow demonstrates how to compile and build FEAP 8.5 from source code. The advantage of this new method is that you can build the FEAP main program and all the subroutines at once. In addition, you can run FEAP in debug mode in Visual Studio just like other programs. The workflow has been tested with FEAP 8.5 source code and Intel Fortran Compiler 2013 in Microsoft Visual Studio Pro 2012. Other versions of Intel Fortran Compiler or Visual Studio may also work. These steps may also be used to build an old version of FEAP. If you are compiling FEAPpv source code, see here [1].
In this method, we will create a Visual Studio solution which consists of two projects: the FEAP main program and a static library. At first, we will create a QuickWin Application for FEAP main program and then another project for the static library.
1. Open Visual Studio.
- Select File -> New -> Project…
- Select QuickWin Application on the left under Intel(R) Visual Fortran, then select QuickWin Application option on the right.
- Name the main program, e.g. feap.
- Select a directory and remember it, e.g.
C:\Users\***\projects\FEAP85\
- At the bottom, add a solution name, e.g. feap85
- Click OK
2. At the top select "Release" build (as opposed to Debug)
3. Right-click the project name (feap) in the Solution Explorer window on the right and select Add -> Existing Item...
- Set the file format to show "All Files (*.*)" in the window if needed
- Add “feap85.f” from the "main" subdirectory of FEAP package, e.g.
C:\users\***\feap\ver85\main
4. Right-click the project name again and select Properties
- Select Fortran on the left, then General
- Add following FEAP include directories to the Additional Include Directories:
C:\users\xxx\feap\ver85\include
and the appropriate directory for 32-bit Windows machine:
C:\users\xxx\feap\ver85\include\integer4
or for 64-bit Windows machine
C:\users\xxx\feap\ver85\include\integer8
.
You only need one of them for your machine.
As of version 8.6, one only selects
...\include
. The interger4/integer8 option has been removed and only 64-bit machines are supported
5. Right-click the solution name (feap85) -> Add -> New Project…
- Select Library on the left under Intel(R) Visual Fortran:
- Select Static Library
- Name library, e.g. lib85
- Click OK
6. At top "Release" build should be selected already. If not, select Release build.
7. Right-click the lib85 Project and select Properties
- Select Fortran, then General on the left
- Add following FEAP include directories to the Additional Include Directories:
C:\users\xxx\feap\ver**\include
and the appropriate directory for 32-bit Windows machine
C:\users\xxx\feap\ver**\include\integer4
,
or 64-bit Windows machine,
C:\users\xxx\feap\ver**\include\integer8
Again, you only need one of them.
As of version 8.6, one only selects
...\include
. The interger4/integer8 option has been removed and only 64-bit machines are supported
8. Right-click the lib85 Project and select Add -> New Folder
- Change the name of the folder to elements
- Right-click the folder elements and select Add -> New Folder. This will create a new subfolder
- Change the name of the subfolder to frame
- Right-click the subfolder frame and Add -> Existing Item...
- Navigate to the FEAP source folder at
C:\Users\***\feap\ver85\elements\frame
- Select all the Fortran source files in that folder and click Add button.
- Repeat steps b to f above to add all the subfolders under the elements folder at
C:\Users\***\feap\ver85\elements
. For example,
C:\Users\***\FEAP\ver85\elements\shells
If the subfolder contains subfolders, you must also add those, for example,
C:\Users\***\FEAP\ver85\elements\material\finite
9. Repeat Step 8 to add the following folders and their subfolders under the FEAP root directory ( C:\Users\***\feap\ver85
): contact, plot, program, user, windows, and one of the folders window1 and window2 (do not add UNIX, include, and main folders in this step).
10. Remove the duplicated files such as pinitm.f and setmem.f under the directory:
C:\Users\***\FEAP\ver85\program\memory
Because those files are also present in the foldder
C:\Users\***\FEAP\ver85\windows\memory
If you have coded some user subroutines, you should also remove the default dummy files under ver85/user
and add your own subroutines to a new folder or the same folder ver85/user
at this step.
11. Right-click the Solution name feap85 given in Step 1 and select Properties
- In the window on the left, select Project Dependencies under Common Properties
- In the project list on the right, select the feap project we created in Step 1 if it is not selected.
- In the "Depends on" window underneath, check the project lib85 to indicate that the project feap depends on project lib85.
- If you want to build FEAP for 64-bit version of Windows, select Configuration Properties in the window on the left. Than, change the solution platform to the "x64" on the top and also change the platform for both the FEAP main project and the lib project.
12. Under the Build tab on the main menu select Build Solution. Then, the Fortran compiler will compile and build the static library and then the FEAP executable file (feap.exe). You can find the executable file in the solution directory chosen in Step 1, e.g.
C:\Users\***\projects\FEAP85\FEAP85\feap\x64\Release
The program is ready to use. If you have any questions or comments about this section of FEAP wiki, please post it at FEAP forum at [2]
PETSc
If you wish to run parallel computations, then you will need a working version of PETSc. For FEAP version 8.6, we have tested it with PETSc version 3.13.2.
Our typical configuration for PETSc is as follows
./configure --download-{parmetis,superlu_dist,openmpi,ml,hypre,metis,mumps,scalapack,blacs}
Of these only parmetis and metis are required. We use openmpi as our message passing implementation but mpich or vendor implementations should be fine.
Common Installation Issues
Incorrect pointer selection
A very common installation problem with versions 8.5 and earlier is to select the wrong include files include/integer4 versus include/integer8. The Memprobe program can help with these issues. If you compile and run the program maintain/memprobe.c, it will provide you guidance on selecting the correct include directories.
As of version 8.6, the 32-bit pointer option has been removed. Only 64-bit pointer architectures are now supported.
Should I change ipr in main/feapXY.f
In general you should not change ipr. ipr stands for integers per (double precision) real. In particular it refers to the ratio of the number of bytes use by a real*8 variable to the number of bytes used by an integer variable. Unless you have an unusual machine, leave ipr as 2. The only situation where you would set ipr = 1 (on a modern computer), is one where you used a compiler flag to force all integer variables to be 8 bytes long. You can do this with ifort using the -i8 flag and gfortran with the -fdefault-integer-8 flag. This is advance stuff; just leave ipr=2, unless you really know what you are doing.
BLAS/LAPACK
In general there should be no reason to use the BLAS and LAPACK files that are provided in packages. Your computer should have pre-loaded BLAS and LAPACK routines. If it does not it is better to install ones that are tuned for your computer, but if you can not, then it is ok to use the ones in packages.
Problems with UBUNTU and other GCC based loaders
The GCC loader type machines do not load files out of archives unless they have already been added to the pending stack. Thus if you have a user macro in an archive, it will get skipped over if previous files on the link line have not yet referred to it. This then results in the dummy user macro getting loaded out of the main FEAP archive. The problem can be fixed by telling the loader to load all the files in a given archive even if they are not on the pending stack. For example if one is using the ARPACK library, one need to replace
$(ARPACKLIB)
on the link line with
-L$(FEAPHOME8_5)/packages/arpack -Wl,-whole-archive -larpack -Wl,-no-whole-archive
The -L lets the compiler know where the archive is located and the -Wl tags are linker directives that force the whole loading of the archive referred to by the -l directive. This needs to be done with all archives (with the exception of the main FEAP archive).
X Error missing fonts
If your install went fine but you got an error saying something like
X Error of failed request: BadName (named color or font does not exist)
then you most likely are missing the Helvetica fonts on your computer. This can usually be solved by load the packages 'xfonts-100dpi' and 'xfonts-75dpi' with your package manager. For example
yum install xfonts-100dpi xfonts-75dpi
or the like using apt
or dnf
etcetera.
IEEE module not available
The file program/nanifchk.f fails to compile because your system does not have the ieee module. This occurs if your gfortran/gcc installation is not particularly current (below gcc version 5). To fix you need to update your compiler version. On Ubuntu-like systems this can be accomplished with the following commands
sudo add-apt-repository ppa:ubuntu-toolchain-r/test sudo apt update sudo apt intstall gfortran-6 gcc-6 g++-6
In place of '6' use the most up-to-date stable version available for your computer.