esokos / isola

ISOLA: A moment tensor retrieval software
http://seismo.geology.upatras.gr/isola/
33 stars 15 forks source link

Compilation elemse.for and gr_xyz.for #4

Open rcabdia opened 1 year ago

rcabdia commented 1 year ago

Dear developer,

I am building a LINUX docker for isola (elemse and gr_xyz). I couldn't succesfully compile either of programs with gfortran (compiler in which I am inetrested because is easier to include in a docker). I am don't know if the problem is that it is the compatibility of gfortran to compile it of it is necessary addtional tools such as gfortran-multilib or gfortran-8-multilib.

Normally I compile as follows gfortran -O3 -c elemse.for gfortran -O3 -c gr_xyz.for gfortran -O3 elemse.o -o elemse gfortran -O3 gr_xyz.o -o gr_xyz

Then I do a simple test (with the auxiliary files in the same folder crust

al.dat, grdat.hed,param.inc,soutype.dat and station.dat)

./gr_xyz 0 0 0 0000 ./elemse 4 0000 0 test_ifort.zip

I attach you the version I am using of elemse.for and gr_xyz.for.

I was able to compile it with ifortran using MACOS with no problems

Please could you tell me which version of gfortran can compile it or any other suggestion

esokos commented 1 year ago

Hi @rcabdia i have tried compilation using gfortran (v.5.4.0)

here is a small shell to compile all let me know if you have problem (i am not referring to 2022 code!)


!/bin/sh

gfortran acka.for -o acka.exe

gfortran analyze_kag.for

gfortran analyze_once.for

gfortran ang.for -o ang.exe gfortran anggrad.for -o anggrad.exe gfortran anggradone.for -o anggradone.exe gfortran angm.for -o angm.exe gfortran angone.for -o angone.exe gfortran angtwo.for -o angtwo.exe

gfortran conshift.for -o conshift.exe gfortran conshift_mt.for -o conshift_mt.exe gfortran corr_kag.for -o corr_kag.exe gfortran done.for -o done.exe gfortran dsretc.for -o dsretc.exe gfortran elecomb.for -o elecomb.exe gfortran elemse.for -o elemse.exe gfortran gr_xyz.for -O1 -m32 -fbacktrace -ffpe-trap=zero,overflow,underflow -fbounds-check -Wall -Wextra -Wconversion -Wunused-parameter -o gr_xyz.exe

gfortran iso15.for -o iso15.exe

gfortran iso15_31stat_once.for -o iso15_31stat_once.exe gfortran isola15.for -m32 -O -Wall -fcheck=all -g -fbacktrace -Wall -Wextra -o isola15.exe

isola15unc is new

gfortran isola15unc.for -o isola15unc.exe

gfortran isola15_finsour.for -o isola15_finsour.exe gfortran isola15_nointer.for -o isola15_nointer.exe

gfortran kagan_2solutionsonly.for -o kagan_2solutionsonly.exe gfortran kagan_map.for -o kagan_map.exe gfortran nod_manu.for -o nod_manu.exe gfortran norm15.for -o norm15.exe gfortran pokus5all_kag.for -o pokus5all_kag.exe gfortran pokus_once.for -o pokus_once.exe

gfortran sigma5or6.for -o sigma5or6.exe gfortran sigma5or6_gen.for -o sigma5or6_gen.exe gfortran syn_cor.for -o syn_cor.exe

rem gfortran -c tinv.f90

rem gfortran -c nnls.f90

rem gfortran -c time_fixed15.for

rem gfortran -c time_loop_two15.for

rem gfortran time_fixed15.obj nnls.obj tinv.obj

rem gfortran time_loop_two15.obj nnls.obj tinv.obj

gfortran time_fixed15.for -o time_fixed15.exe gfortran time_loop_two15.for -o time_loop_two15.exe

gfortran timfuncas.for -o timfuncas.exe gfortran timfuncas1.for -o timfuncas1.exe gfortran timfuncas2.for -o timfuncas2.exe

mv isola15.exe isola.exe mv norm15.exe norm.exe

cp isola15_nointer.exe isola_nointer.exe

mv iso15.exe iso.exe

rem for jackknifing:

mv isola15_nointer.exe isola_jack.exe

rem for uncertainty mapping:

mv iso15_31stat_once.exe iso_once.exe

rem for time function:

mv time_fixed15.exe time_fixed.exe

rem for joint grid search of two sources and their time functions

mv time_loop_two15.exe time_loop_two.exe

rem from all ANG* codes only ANGone is used in GUI

move all exe one folder up

mv *.exe ..

rcabdia commented 1 year ago

Well with the current gfortran (GNU Fortran (GCC) 10.2.0) does not compile. I tied in an UBUNTU 20.22 suing simply f77 and works to compile elemse and gr_xyz. So I think, I will try to make a docker using ifortran and if it is to complicated I will try using f77.

Many Thanks for your help, I will let you know the progress. I would very appreciate if you could let me know some explanation or help to understand the output of elemse and gr_xyz (elemse.dat and gr XXXX.hea and grXXXX.hes). Where can I find documentation to understand axitra??

Roberto Cabieces

esokos commented 1 year ago

what is the error message you get ? i have noticed that some *for files contain strange characters at the end that cause problems with some compilers.

elemse is not part of AXITRA (gr_xyz is) what do you need to know? format of binary files? or something else .. format is easy just look in the code! for axitra try google!!i don't have a manual.