#1125 closed Bug (fixed)
Allocate pb in geo2ocean
Reported by: | aclsce | Owned by: | smasson |
---|---|---|---|
Priority: | low | Milestone: | |
Component: | OCE | Version: | trunk |
Severity: | Keywords: | SBC | |
Cc: |
Description
Two things :
1) It is needed to put a test on the allocation of tab in "angle" subroutine in geo2ocean module.
I suggest to put a "IF( .NOT. ALLOCATED( gsint ) ) THEN"
2) there is a "IF( ALLOCATED( gsinlon ) ) THEN" in "oce2geo" subroutine in geo2ocean module. I think it is a bug.
A "IF( .NOT. ALLOCATED( gsinlon ) ) THEN" would be better.
Thanks !
curie70 - /ccc/work/cont003/dsm/p86caub/EXTRACT_COMMIT/modipsl/modeles/NEMOGCM/NEMO/OPA_SRC/SBC : svn diff
Index: geo2ocean.F90
===================================================================
--- geo2ocean.F90 (revision 3940)
+++ geo2ocean.F90 (working copy)
@@ -180,11 +180,12 @@
zxffv, zyffv, znffv, & ! x,y components and norm of the vector: between F points left and right a V point
zxuuf, zyuuf, znuuf ! x,y components and norm of the vector: between U points below and above a F point
!!----------------------------------------------------------------------
-
- ALLOCATE( gsint(jpi,jpj), gcost(jpi,jpj), &
- & gsinu(jpi,jpj), gcosu(jpi,jpj), &
- & gsinv(jpi,jpj), gcosv(jpi,jpj), &
- & gsinf(jpi,jpj), gcosf(jpi,jpj), STAT=ierr )
+ IF( .NOT. ALLOCATED( gsint ) ) THEN
+ ALLOCATE( gsint(jpi,jpj), gcost(jpi,jpj), &
+ & gsinu(jpi,jpj), gcosu(jpi,jpj), &
+ & gsinv(jpi,jpj), gcosv(jpi,jpj), &
+ & gsinf(jpi,jpj), gcosf(jpi,jpj), STAT=ierr )
+ ENDIF
IF(lk_mpp) CALL mpp_sum( ierr )
IF( ierr /= 0 ) CALL ctl_stop('STOP', 'angle_msh_geo: unable to allocate arrays' )
@@ -437,7 +438,7 @@
- INTEGER
- ierr ! local integer !!----------------------------------------------------------------------
- IF( ALLOCATED( gsinlon ) ) THEN
+ IF( .NOT. ALLOCATED( gsinlon ) ) THEN
Commit History (2)
Changeset | Author | Time | ChangeLog |
---|---|---|---|
4080 | smasson | 2013-10-20T18:37:47+02:00 | v3_4_STABLE: minor bugfix in geo2ocean, see #1125 |
4079 | smasson | 2013-10-20T18:35:16+02:00 | trunk: minor bugfix in geo2ocean, see #1125 |
Change History (4)
comment:1 Changed 11 years ago by smasson
- Owner changed from NEMO team to smasson
comment:2 Changed 11 years ago by aclsce
You are probably right for my first point. I obtained the error message
"angle_msh_geo: unable to allocate arrays"
and that's why I thought the problem was in angle subroutine. This error message was also used in oce2geo subroutine and was due to the second point of my ticket...and not to the first point of the ticket.
I am sorry for that : you can forget the first point of my ticket.
But maybe you could change the error message by specifying the exact name of the subroutine which writes the message...that could help for a next time...
Thanks !
comment:3 Changed 11 years ago by smasson
- Resolution set to fixed
- Status changed from new to closed
comment:4 Changed 8 years ago by nicolasmartin
- Keywords geo2ocean removed
I agree with the second point.
I don't understand how you can pass twice in angle as teh call to angle is within a if test on lmust_init:
Btw, we should use the same strategy for linit and lmust_init. this is not very clean as it is done now...