Hello,
I would like to perform matrix operations inside a fortran user subroutine, with code_saturne v6. I need Lapack.
I read a post in this forum discussing how to install code_saturne v2 with Lapack.
What is the procedure you reccomend with v6?
Thank you very much for your help.
Best regards,
Daniele
Lapack with v6
Forum rules
Please read the forum usage recommendations before posting.
Please read the forum usage recommendations before posting.
-
- Posts: 4152
- Joined: Mon Feb 20, 2012 3:25 pm
Re: Lapack with v6
Hello,
Iy you use Lapack only in user subroutines, you can simply add the required compile and link flags in a cs_user_scripts.py file (under DATA), in the domain.compile_cflags, domain.compile_cxxflags, and domain.compile_libs entries.
Best regards,
Yvan
Iy you use Lapack only in user subroutines, you can simply add the required compile and link flags in a cs_user_scripts.py file (under DATA), in the domain.compile_cflags, domain.compile_cxxflags, and domain.compile_libs entries.
Best regards,
Yvan
Re: Lapack with v6
Hello Yvan,
Thank you very much for your help.
I am not very good in compiling stuff, could you please help me further: what do I have to specify exactly for domain.compile_...? The location of the Lapack libraries etc?
Thanks a lot for your time.
Best regards,
Daniele
Thank you very much for your help.
I am not very good in compiling stuff, could you please help me further: what do I have to specify exactly for domain.compile_...? The location of the Lapack libraries etc?
Thanks a lot for your time.
Best regards,
Daniele
-
- Posts: 4152
- Joined: Mon Feb 20, 2012 3:25 pm
Re: Lapack with v6
Hello,
On a system where Lapack is installed under /usr, simply use
On a system where it is installed on, for example /opt/lapack, adapt this:
You might then have other errors due to dependencies, and need to add other libriaries (i.E. BLAS) depending on your system.
Best regards,
Yvan
On a system where Lapack is installed under /usr, simply use
Code: Select all
domain.compile_cflags = None
domain.compile_cxxflags = None
domain.compile_fcflags = None
domain.compile_libs = -llapack
Code: Select all
domain.compile_cflags = -I/opt/lapack
domain.compile_cxxflags = None
domain.compile_fcflags = None
domain.compile_libs = "-L/opt/lapack -llapack"
Best regards,
Yvan
Re: Lapack with v6
Thank you very much Yvan.
I managed to properly link Lapack!
Best regards,
Daniele
I managed to properly link Lapack!
Best regards,
Daniele