Changeset 4059 for trunk/LMDZ.MARS/libf


Ignore:
Timestamp:
Feb 10, 2026, 10:18:01 AM (2 weeks ago)
Author:
jbclement
Message:

Mars PCM:
Deletion of 'qsurf' in the information provided by "start1D.txt" since it is unused and unnecessary until now. Addition of an error-leading check to prevent an unintended situation (which should not happen) regarding the presence of starting files.
JBC

Location:
trunk/LMDZ.MARS/libf/phymars/dyn1d
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/LMDZ.MARS/libf/phymars/dyn1d/init_testphys1d_mod.F90

    r4043 r4059  
    538538else
    539539    do iq = 1,nq
    540         read(3,*,iostat = ierr) header, (qsurf(1,iq,j), j = 1,size(qsurf,3)), (q(1,ilayer,iq), ilayer = 1,nlayer)
     540        read(3,*,iostat = ierr) header, (q(1,ilayer,iq), ilayer = 1,nlayer)
    541541        if (ierr /= 0) error stop 'Not enough atmospheric layers defined in the file "'//trim(start1Dname)//'" for the tracer "'//trim(header)//'"!'
    542542        if (trim(tname(iq)) /= trim(header)) then
  • trunk/LMDZ.MARS/libf/phymars/dyn1d/testphys1d.F90

    r4043 r4059  
    129129if (startfiles_1D) then
    130130    inquire(file = 'start1D.txt',exist = therestart1D)
    131     if (startfiles_1D .and. .not. therestart1D) then
     131    if (.not. therestart1D) then
    132132        write(*,*) 'There is no "start1D.txt" file!'
    133133        write(*,*) 'Initialization is done with default values.'
     
    139139    endif
    140140endif
     141if (therestart1D .and. .not. therestartfi) error stop 'There is a "start1D.txt" but no "startfi.nc". There might be problems for the initialization (for example ''qsurf'')!'
    141142
    142143call init_testphys1d('start1D.txt','startfi.nc',therestart1D,therestartfi,ngrid,nlayer,odpref,nq,q, &
     
    261262
    262263! Writing the "restart1D.txt" file for the next run
    263 if (startfiles_1D) call writerestart1D('restart1D.txt',psurf,pa,preff,tsurf(1,:),nlayer,size(tsurf,2),temp,u,v,nq,noms,qsurf(1,:,:),q)
     264if (startfiles_1D) call writerestart1D('restart1D.txt',psurf,pa,preff,tsurf(1,:),nlayer,size(tsurf,2),temp,u,v,nq,noms,q)
    264265
    265266write(*,*) "testphys1d: everything is cool!"
  • trunk/LMDZ.MARS/libf/phymars/dyn1d/writerestart1D_mod.F90

    r4043 r4059  
    55contains
    66
    7 SUBROUTINE writerestart1D(filename,psurf,pa,preff,tsurf,nlayer,nslope,temp,u,v,nq,qnames,qsurf,q)
     7SUBROUTINE writerestart1D(filename,psurf,pa,preff,tsurf,nlayer,nslope,temp,u,v,nq,qnames,q)
    88
    99implicit none
     
    1616real, dimension(nlayer),     intent(in) :: temp, u, v
    1717real, dimension(nlayer,nq),  intent(in) :: q
    18 real, dimension(nq,nslope),  intent(in) :: qsurf
    1918character(*), dimension(nq), intent(in) :: qnames
    2019
     
    2625write(1,*) 'ps', psurf, pa, preff
    2726do i = 1,nq
    28     write(1,*) qnames(i), (qsurf(i,j), j = 1,nslope), (q(il,i), il = 1,nlayer)
     27    write(1,*) qnames(i), (q(il,i), il = 1,nlayer)
    2928enddo
    3029write(1,*) 'u', (u(il), il = 1,nlayer)
Note: See TracChangeset for help on using the changeset viewer.