# CCTM error running CMAQ5.3.2.1

**URL:** <https://forum.cmascenter.org/t/cctm-error-running-cmaq5-3-2-1/4460>\
**Category:** CMAQ\
**Tags:** cmaq\
**Created:** [October 5, 2023, 3:40pm UTC](https://forum.cmascenter.org/t/cctm-error-running-cmaq5-3-2-1/4460 "2023-10-05T15:40:34Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![nna](https://avatars.discourse-cdn.com/v4/letter/n/ac8455/32.png) [@nna](https://forum.cmascenter.org/u/nna)\
**Post date:** [October 5, 2023, 3:40pm UTC](https://forum.cmascenter.org/t/cctm-error-running-cmaq5-3-2-1/4460/1 "2023-10-05T15:40:34Z")

</div>

Hello, I have errors about “GRIDDESC”. I am sure the GRIDDESC is in the specified path and the GRIDNAME in it matches that I set in run\_cctm.csh. Here are the logfile and GRIDDESC. Thank you so much!

’ ’  
‘LamCon\_40N\_97W’  
2 33.000 45.000 -97.000 -97.000 40.000  
’ ’  
‘US\_d01’  
‘LamCon\_40N\_97W’ -2754000.000 -1794000.000 12000.000 12000.000 459 299 1  
’ ’

```
 Execution ID "mcip"
 Grid name "US_d01_CROSS"
 Dimensions: 299 rows, 459 cols, 23 lays, 16 vbles
 NetCDF ID: 65536 opened as READONLY            
 Starting date and time 2023009:000000 (0:00:00 Jan. 9, 2023)
 Timestep 010000 (1:00:00 hh:mm:ss)
 Maximum current record number 25

 MET data determined based on WRF ARW version 3.9.1

 Closing file MET_CRO_3D

 ========================================
 |>--- RETRIEVE HORIZONTAL GRID ---<|
 ========================================

 File "GRIDDESC" opened for input on unit: 98
 /share/atmoschem/nwu3/CMAQv5.3.2.1/data/mcip/GRIDDESC

 
 >>--->> WARNING in subroutine HGRD_INIT on PE 000
 Failure retrieving horizontal grid parameters
 
 
 >>--->> WARNING in subroutine GRID_INIT
 *** Failure defining horizontal domain
 

 *** ERROR ABORT in subroutine DRIVER on PE 000          
 *** Failure defining domain configuration
 PM3EXIT: date&time specified as 0
 Date&time specified as 0

```

---

<div class="post-metadata">

**Author:** ![cjcoats](https://avatars.discourse-cdn.com/v4/letter/c/ac8455/32.png) [@cjcoats](https://forum.cmascenter.org/u/cjcoats)\
**Post date:** [October 5, 2023, 3:59pm UTC](https://forum.cmascenter.org/t/cctm-error-running-cmaq5-3-2-1/4460/2 "2023-10-05T15:59:53Z")

</div>

It would be interesting to see what happens when you use this file and _ **m3tools** _ program \* [_ **latlon** _](https://www.cmascenter.org/ioapi/documentation/all_versions/html/LATLON.html)to try to generate a `LATLON` file – does that work, or else what are the error messages?

If the CCTM is properly using I/O API routine [`DSCGRID`](https://www.cmascenter.org/ioapi/documentation/all_versions/html/DSCGRID.html) to read the GRIDDESC file, then you should be getting proper error-messages from it, describing just what the nature of the error is. But I don’t see such messages ;-(

---

<div class="post-metadata">

**Author:** ![hogrefe.christian](https://avatars.discourse-cdn.com/v4/letter/h/74df32/32.png) [@hogrefe.christian](https://forum.cmascenter.org/u/hogrefe.christian)\
**Post date:** [October 5, 2023, 5:26pm UTC](https://forum.cmascenter.org/t/cctm-error-running-cmaq5-3-2-1/4460/3 "2023-10-05T17:26:58Z")

</div>

I think HGRD\_DEF.F does call DSCGRID:

```
C With GRID_NAME (only input) retrieve all horizontal grid parameters from
C the grid description file pointed to by the GRIDDESC env var:
            WRITE( LOGDEV, * )
            CALL LOG_HEADING( LOGDEV, "Retrieve Horizontal Grid" )
            IF ( .NOT. DSCGRID ( GRID_NAME,
     & COORD_SYS_NAME, GDTYP_GD, 
     & P_ALP_GD, P_BET_GD, P_GAM_GD,
     & XCENT_GD, YCENT_GD,
     & XORIG_GD, YORIG_GD, XCELL_GD, YCELL_GD,
     & GL_NCOLS, GL_NROWS, NTHIK ) ) THEN
               XMSG = 'Failure retrieving horizontal grid parameters'
               CALL M3WARN ( 'HGRD_INIT', 0, 0, XMSG )
               SUCCESS = .FALSE.; RETURN
            END IF

```

If `setenv GRID_NAME US_d01` and `setenv GRIDDESC /share/atmoschem/nwu3/CMAQv5.3.2.1/data/mcip/GRIDDESC` are both set in the run script, I am not quite sure why this error would occur if the GRIDDESC file is o.k. - the test suggested by @cjcoats would be an independent way of verifying that it is.

I am not sure if this is a problem or not, but the GRIDDESC file I’ve been using and the [example GRIDDESC file provided with the I/O API documentation](https://www.cmascenter.org/ioapi/documentation/all_versions/html/GRIDDESC.txt) have a quoted space at the end of the coordinate and grid blocks, not at the beginning like in the one you posted above.

---

<div class="post-metadata">

**Author:** ![cjcoats](https://avatars.discourse-cdn.com/v4/letter/c/ac8455/32.png) [@cjcoats](https://forum.cmascenter.org/u/cjcoats)\
**Post date:** [October 5, 2023, 5:32pm UTC](https://forum.cmascenter.org/t/cctm-error-running-cmaq5-3-2-1/4460/4 "2023-10-05T17:32:50Z")

</div>

Good eyes, Christian !!

There are two parts to a GRIDDESC: the “map projections” section and the “grids” section. Both of these have lists of names and defining parameters, that are **ended** by a quoted blank in what would otherwise be the name-portion of the respective section. A blank **leading** the “map projections” section would say that there are zero map projections, and what follows should be the list of grid-names and grid-parameters. Which, of course, does not match up with the rest of the original poster’s file.

---

<div class="post-metadata">

**Author:** ![nna](https://avatars.discourse-cdn.com/v4/letter/n/ac8455/32.png) [@nna](https://forum.cmascenter.org/u/nna)\
**Post date:** [October 5, 2023, 5:51pm UTC](https://forum.cmascenter.org/t/cctm-error-running-cmaq5-3-2-1/4460/5 "2023-10-05T17:51:48Z")

</div>

Thank you so much for your reply! I’ll test it.

---

<div class="post-metadata">

**Author:** ![nna](https://avatars.discourse-cdn.com/v4/letter/n/ac8455/32.png) [@nna](https://forum.cmascenter.org/u/nna)\
**Post date:** [October 5, 2023, 6:00pm UTC](https://forum.cmascenter.org/t/cctm-error-running-cmaq5-3-2-1/4460/6 "2023-10-05T18:00:34Z")

</div>

I’m sorry that I omit the last line in my GRIDDESC when I posted it. I will corrected it in the original post. It is generated by MCIP run, and have a quoted space at the end. The GRID\_NAME and GRIDDESC are both specified in the run script. I’m quite confused about this error ☹

---

<div class="post-metadata">

**Author:** ![nna](https://avatars.discourse-cdn.com/v4/letter/n/ac8455/32.png) [@nna](https://forum.cmascenter.org/u/nna)\
**Post date:** [October 10, 2023, 1:22pm UTC](https://forum.cmascenter.org/t/cctm-error-running-cmaq5-3-2-1/4460/7 "2023-10-10T13:22:31Z")

</div>

It proves that there is an issue with my I/O. Thank you for your help!
