Closed phil-blain closed 4 years ago
I compiled with ice_dyn_vp.o: FFLAGS += -Wall
added to Macros.conda_macos
. This activates the -Wall
flag only for the ice_dyn_vp.o
target, i.e. when compiling ice_dyn_vp.F90
.
This flag found
use
-imported variables in subroutines.
(see https://gcc.gnu.org/onlinedocs/gcc/Warning-Options.html and https://gcc.gnu.org/onlinedocs/gfortran/Error-and-Warning-Options.html)See 083b611, 71eba9e, 2a5f4b7, 7a8951a, 4931ac2
I fixed trailing whitespace issues, using git diff $(git empty-tree) cicecore/cicedynB/dynamics/ice_dyn_vp.F90
: 0d527f6
I fixed more whitespace issues, and uniformized whitespace for subroutine arguments and intents: 0179edf 7d46f1d 9b6c2bf b32bdfe
I did some more code cleanup in 8218e82 and eadcfa6
I re-read every code comment in ice_dyn_vp
and cleaned up a lot of them, also clarified others in 5ff03ab.
Still need to :
[x] clarify if the conv
and r0
variables in FGMRES (and PGMRES) should be removed. I need to compare with the Saad implementation.
[x] reread the FGMRES algorithm to find a better name and description for ww
I did more variable naming clean up in 1416a7e
I renamed ww
to orig_basis
in 9267229
I removed the conv
and r0
arguments; they were unused. If we change the implementation in the future and we need them, we'll just re-add them.
there are no !phb
comments anymore. I changed some of them to TODO
.
I went through the code and there is a lot of repetitions (copy-paste) between different computations regarding rheology. Here is a list of the computations by subroutines:
calc_zeta_dPr
(ice_dyn_vp
)[cs]sigp[nsew12]
calc_bvec
stress_vp
(ice_dyn_vp
)stress[p,m,12]_[1-4]
matvec
(ice_dyn_vp
)stress[p,m,12]_[1-4]
stressp
is only "linear" part (linear in \partial^n_[x,y] u)[cs]sigp[nsew12]
str
formDiag_step1
(ice_dyn_vp
)strain_rates
(with some coefficients = 0 or 1)stressp
-> only "linear" part)Drheo
(same computation as matvec, but special case for 8 corners...)formDiag_step2
(ice_dyn_vp
)ccb
(i.e. only ccaimp
)stress
(ice_dyn_evp
)stress[p,m,12]_[1-4]
-> different computations (EVP)[cs]sig[p,m,12][nsew]
-> SAME as matvec
str[pm]_tmp
-> SAME as matvec
stress_eap
(ice_dyn_eap
)strain_rates
deformations
[cs]sig[p,m,12][nsew]
-> SAME as matvec
str[pm]_tmp
-> SAME as matvec
We will refactor the code to unify these computations, but in a second step (after the Picard PR).
use
statements~ I did that a while ago, I won't change all interfaces again for now.-Wall
and fix warnings