Ignore:
Timestamp:
Mar 15, 2019 3:36:25 PM (6 years ago)
Author:
forkel
Message:

editing in kpp4palm: add statements for avoiding unused variables, remove $Id

Location:
palm/trunk/UTIL/chemistry/gasphase_preproc/kpp4palm
Files:
12 edited

Legend:

Unmodified
Added
Removed
  • palm/trunk/UTIL/chemistry/gasphase_preproc/kpp4palm/bin/kpp4palm.ksh

    r3780 r3799  
    4040# -----------------
    4141# $Id$
     42# Removed edit of phot(nphot) for version edit phot(nphot), now done in fortran_file.C (15.03.2019, forkel)
     43# Editing with sed to add dummy statements toavoud unused variables
     44#
     45# 3780 2019-03-05 11:19:45Z forkel
    4246# forkel   05. March 2019: cs_mech and set_cm
    4347# forkel   30. Oktober 2018: Integrating contents of kp4_compress into chem_gasphase_mod.f90
     
    337341$BASE/bin/kpp4palm.exe $PREFIX $MODE $VLEN $DE_INDEX $DE_INDEX_FAST
    338342
    339 #Prelimanary, substitution has to be moved into kpp4palm.exe
     343# Add dummy statements in order to prevent warnings due to unused variables
     344#
     345sed -i -e '/cfactor =/a !  ' kk_kpp.f90
     346sed -i -e '/cfactor =/a    IF ( lu_crow(1) == 1  .OR.  lu_icol(1) == 1  .OR.  lu_irow(1) == 1 )  CONTINUE ' kk_kpp.f90
     347sed -i -e '/cfactor =/a ! Following line is just to avoid compiler message about unused variables' kk_kpp.f90
     348sed -i -e '/cfactor =/a !  ' kk_kpp.f90
     349
    340350if [[ $MODE = "vector" ]]
    341351then
    342   sed -i -e 's/phot(nphot/phot(vl_dim,nphot/g' kk_kpp.f90
    343 fi
     352sed -i -e '/! Computation of equation rates/i ! Following line is just to avoid compiler message about unused variables' kk_kpp.f90
     353sed -i -e '/! Computation of equation rates/i IF ( f(vl,nfix) > 0.0_dp )  CONTINUE' kk_kpp.f90
     354sed -i -e '/! Computation of equation rates/i !  ' kk_kpp.f90
     355else
     356sed -i -e '/! Computation of equation rates/i ! Following line is just to avoid compiler message about unused variables' kk_kpp.f90
     357sed -i -e '/! Computation of equation rates/i IF ( f(nfix) > 0.0_dp )  CONTINUE' kk_kpp.f90
     358sed -i -e '/! Computation of equation rates/i !  ' kk_kpp.f90
     359fi
     360
     361if [[ $MODE = "vector" ]]
     362then
     363sed -i -e '/REAL(kind=dp) :: b/a   IF ( f(vl,nfix) > 0.0_dp )  CONTINUE' kk_kpp.f90
     364sed -i -e '/REAL(kind=dp) :: b/a ! Following line is just to avoid compiler message about unused variables' kk_kpp.f90
     365sed -i -e '/REAL(kind=dp):: b/a !' kk_kpp.f90
     366else
     367sed -i -e '/REAL(kind=dp):: b/a   IF ( f(nfix) > 0.0_dp )  CONTINUE' kk_kpp.f90
     368sed -i -e '/REAL(kind=dp):: b/a ! Following line is just to avoid compiler message about unused variables' kk_kpp.f90
     369sed -i -e '/REAL(kind=dp):: b/a !' kk_kpp.f90
     370fi
     371
     372sed -i -e '/one=1.0_dp/a       IF ( incx == 0 )  CONTINUE' kk_kpp.f90
     373sed -i -e '/one=1.0_dp/a ! Following line is just to avoid compiler message about unused variables' kk_kpp.f90
     374sed -i -e '/one=1.0_dp/a !  ' kk_kpp.f90
     375
     376sed -i -e '/IF (alpha .eq. zero)RETURN/i !  ' kk_kpp.f90
     377sed -i -e '/IF (alpha .eq. zero)RETURN/i ! Following line is just to avoid compiler message about unused variables' kk_kpp.f90
     378sed -i -e '/IF (alpha .eq. zero)RETURN/i     IF ( incx == 0  .OR.  incy == 0 )  CONTINUE' kk_kpp.f90
     379
     380sed -i -e '/INTENT(INOUT):: b(n)/a       IF ( pivot(1) == 0 )  CONTINUE' kk_kpp.f90
     381sed -i -e '/INTENT(INOUT):: b(n)/a ! Following line is just to avoid compiler message about unused variables' kk_kpp.f90
     382sed -i -e '/INTENT(INOUT):: b(n)/a !  ' kk_kpp.f90
    344383
    345384if [[ -e $OUTDIR/${OUTFILE}.f90 ]]
  • palm/trunk/UTIL/chemistry/gasphase_preproc/kpp4palm/src/create_kpp_module.C

    r3797 r3799  
    99//
    1010// ############################################################################
    11 //
    12 //Current revisions:
    13 //------------------
    1411//
    1512//
    1613//Former revisions:
    1714//-----------------
    18 //$Id: create_kpp_module.C 3453 2018-10-30 13:21:51Z forkel $
     15// Deleted $Id since document_changes does not work for C and C++         (15.03.2019, forkel)
     16//
    1917// OpenMP version    (15.03.2019, ketelsen)
    2018//
     
    199197   generate_module_header();
    200198
    201 // create_set_cs
     199// Create subroutine to communicate mechanism name to other modules
    202200   create_set_cs();
    203201
  • palm/trunk/UTIL/chemistry/gasphase_preproc/kpp4palm/src/create_kpp_module.h

    r3780 r3799  
    1818// Former revisions:
    1919// -----------------------
    20 // $Id$
    21 // forkel   22.02.2019: Added create_set_cs
    22 // ketelsen 18.09.2018: Removed create_fill_routine
     20// Deleted $Id since document_changes does not work for C and C++         (15.03.2019, forkel)
     21//
     22// Added create_set_cs   (22.02.2019, forkel)
     23//
     24// Removed create_fill_routine   (18.09.2018, ketelsen)
    2325//
    2426// initial version                                  (Nov. 2016, ketelsen)
  • palm/trunk/UTIL/chemistry/gasphase_preproc/kpp4palm/src/expand_decomp.C

    r3789 r3799  
    99//
    1010// ############################################################################
    11 //Current revisions:
    12 //------------------
    1311//
    1412//
    1513// Former revisions:
    1614// -----------------------
    17 // $Id: expand_decomp.C 3327 2018-10-09 19:55:00Z forkel $
     15// Deleted $Id since document_changes does not work for C and C++   (15.03.2019, forkel)
    1816//
    1917// Added switch for de-indexing == 2 (W is not needed then)       (08.03.2019, forkel)
  • palm/trunk/UTIL/chemistry/gasphase_preproc/kpp4palm/src/expand_decomp.h

    r3458 r3799  
    1111//
    1212// ############################################################################
    13 //Current revisions:
    14 //------------------
    1513//
    1614//
    1715// Former revisions:
    1816// -----------------------
    19 // $Id: expand_decomp.h 3327 2018-10-09 19:55:00Z forkel $
     17// Deleted $Id since document_changes does not work for C and C++   (15.03.2019, forkel)
    2018//
    2119// initial version                                  (Nov. 2016, ketelsen)
  • palm/trunk/UTIL/chemistry/gasphase_preproc/kpp4palm/src/fortran_file.C

    r3797 r3799  
    1111//
    1212//
    13 //Current revisions:
    14 //------------------
    15 //
    16 //
    1713//Former revisions:
    1814//-----------------
    19 //$Id:
     15// Deleted $Id since document_changes does not work for C and C++   (15.03.2019, forkel)
     16//
     17// For vector version edit phot(nphot) - was before done in kpp4pal.ksh (15.03.2019, forkel)
     18//
    2019// OpenMP version    (15.03.2019, ketelsen)
    2120//
     
    676675//  Replace Roundoff = WLAMCH('E') since WLAMCH does not work everywhere
    677676       ip->global_substitute("Roundoff = WLAMCH('E')","roundoff = epsilon(one)");
     677//  For vector version edit  phot(nphot) from INLINE in chem_gasphase_mod.kpp
     678    if(kpp_switches.is_vector()) {
     679        ip->global_substitute("phot(nphot)","phot(vl_dim,nphot)");
     680    }
    678681
    679682// Now do some cosmetics to adapt the KPP generated output a bit o the looks of PALM,
  • palm/trunk/UTIL/chemistry/gasphase_preproc/kpp4palm/src/fortran_file.h

    r3458 r3799  
    1212// ############################################################################
    1313//
    14 //Current revisions:
    15 //------------------
    16 //
    1714//
    1815// Former revisions:
    1916// -----------------------
    20 // $Id: fortran_file.h 3327 2018-10-09 19:55:00Z forkel $
     17// Deleted $Id since document_changes does not work for C and C++         (15.03.2019, forkel)
    2118//
    2219// added edit_Initialize                            (Sept.2018, forkel)
  • palm/trunk/UTIL/chemistry/gasphase_preproc/kpp4palm/src/main.C

    r3458 r3799  
    44//     create_mz_kpp_module
    55//
    6 //     create scalar code from .f90 sources created by KPP to be used in MESSy
     6//     create scalar code from .f90 sources created by KPP to be used in PALM4U
    77//
    8 //     COPYRIGHT Klaus Ketelsen and MPI-CH   April 2007
     8//     COPYRIGHT Klaus Ketelsen and MPI-CH   April 2007,
     9//               Klaus Ketelsen, 2016
    910//
    1011// ############################################################################
    1112//
    12 //Current revisions:
    13 //------------------
    14 //
    15 //
    1613// Former revisions:
    1714// -----------------------
    18 // $Id: main.C 3327 2018-10-09 19:55:00Z forkel $
     15// Deleded $Id since document_changes does not work for C and C++         (15.03.2019, forkel)
    1916//
    2017// initial version       (Nov. 2016, ketelsen)
     
    3532
    3633   cout << "####################################################" <<endl ;
    37    cout << "###             KP4 = KPP POST PROCESSOR         ###" <<endl ;
    38    cout << "###                   Version 1.0                ###" <<endl ;
     34   cout << "###        KPP4PALM = KPP POST PROCESSOR         ###" <<endl ;
     35   cout << "###               KP4 Version 1.0                ###" <<endl ;
    3936   cout << "### (C) by Klaus Ketelsen and MPI-CH, April 2007 ###" <<endl ;
     37   cout << "###               KPP4PALM                       ###" <<endl ;
     38   cout << "### (C) by Klaus Ketelsen, November 2016         ###" <<endl ;
    4039   cout << "####################################################" <<endl ;
    4140
     
    7170
    7271   cout << "####################################################" <<endl ;
    73    cout << "###                END OF KP4                    ###" <<endl ;
     72   cout << "###                END OF KPP4PALM               ###" <<endl ;
    7473   cout << "####################################################" <<endl ;
    7574
  • palm/trunk/UTIL/chemistry/gasphase_preproc/kpp4palm/src/program_line.C

    r3458 r3799  
    1010// ############################################################################
    1111//
    12 //Current revisions:
    13 //------------------
    14 //
    1512//
    1613// Former revisions:
    1714// -----------------------
    18 // $Id: program_line.C 3327 2018-10-09 19:55:00Z forkel $
     15// Deleted $Id since document_changes does not work for C and C++   (15.03.2019, forkel)
    1916//
    2017// global_subtolower     (June 2018, forkel)
  • palm/trunk/UTIL/chemistry/gasphase_preproc/kpp4palm/src/program_line.h

    r3458 r3799  
    1212// ############################################################################
    1313//
    14 //Current revisions:
    15 //------------------
    16 //
    1714//
    1815// Former revisions:
    1916// -----------------------
    20 // $Id: program_line.h 3327 2018-10-09 19:55:00Z forkel $
     17// Deleted $Id since document_changes does not work for C and C++   (15.03.2019, forkel)
    2118//
    2219// added    void   global_subtolower(string &line); (June 2018, forkel)
  • palm/trunk/UTIL/chemistry/gasphase_preproc/kpp4palm/src/utils.C

    r3458 r3799  
    1010// ############################################################################
    1111//
    12 //Current revisions:
    13 //------------------
    14 //
    1512//
    1613// Former revisions:
    1714// -----------------------
    18 // $Id: utils.C 3327 2018-10-09 19:55:00Z forkel $
     15// Deleted $Id since document_changes does not work for C and C++   (15.03.2019, forkel)
    1916//
    2017// initial version                                  (Nov. 2016, ketelsen)
  • palm/trunk/UTIL/chemistry/gasphase_preproc/kpp4palm/src/utils.h

    r3458 r3799  
    1212// ############################################################################
    1313//
    14 //Current revisions:
    15 //------------------
    16 //
    1714//
    1815// Former revisions:
    1916// -----------------------
    20 // $Id: utils.h 3327 2018-10-09 19:55:00Z forkel $
     17// Deleted $Id since document_changes does not work for C and C++   (15.03.2019, forkel)
    2118//
    2219// initial version                                  (Nov. 2016, ketelsen)
Note: See TracChangeset for help on using the changeset viewer.