Index: /palm/trunk/SCRIPTS/.mrun.config.forwind
===================================================================
--- /palm/trunk/SCRIPTS/.mrun.config.forwind	(revision 1098)
+++ /palm/trunk/SCRIPTS/.mrun.config.forwind	(revision 1099)
@@ -5,11 +5,13 @@
 %mainprog          palm.f90
 %base_directory    $HOME/palm/current_version
-%base_data         $base_directory/JOBS
-%output_data       /data/work/fw/<replace by your username>/palm/current_version/JOBS
-# Replace <replace by your username> by your username on FLOW. Replace "/fw/" by "/iwes/" if
-# your user directory resides in /iwes/.
+%base_data         ~/palm/current_version/jobs
+################################################################################
+# Replace <<REPLACE BY YOUR USERNAME> by your username on FLOW. Replace "/fw/" 
+# by "/iwes/" if your user directory resides in /iwes/.
+################################################################################
+%output_data       /data/work/fw/<REPLACE BY YOUR USERNAME>/palm/current_version/JOBS
 %source_path       $base_directory/trunk/SOURCE
-%add_source_path   $base_directory/USER_CODE/$fname
-%depository_path   $base_directory/MAKE_DEPOSITORY
+%add_source_path   $base_directory/user_code/$fname
+%depository_path   $base_directory/make_depository
 %use_makefile      true
 #
@@ -19,25 +21,60 @@
 %host_identifier       cfdh*            lcflow
 %host_identifier       cfdx*            lcflow
-#
+
+################################################################################
+# Replace <YOUR_DESKTOP_HOSTNAME> by the hostname of your desktop
+# an uncomment following line to enable job submission from you local desktop
+################################################################################
+#%host_identifier       <YOUR_DESKTOP_HOSTNAME>           lcfor
+
+################################################################################
+# Configuration for Ubuntu Linux 12.04 LTS with gcc (4.6.3) and OpenMPI (1.4.3)
 #
 # The next block contains all informations for compiling the PALM code
-# and for generating and running the PALM executable using MPI. Replace <user-id>
+# and for generating and running the PALM executable using MPI on a Linux machine 
+# with gcc and OpenMPI. Replace <LOCAL_USERNAME> with your username on your
+# local machine
+#
+# NOTE: - Other hosts may require different settings.
+#       - following packages are required:
+#         openmpi-common, libopenmpi-dev, libopenmpi, libnetcdf, libnetcdf-dev,
+#         gcc
+#
+################################################################################
+%remote_username   <LOCAL_USERNAME>                                          lcfor parallel
+%tmp_user_catalog  /tmp                                                      lcfor parallel
+%tmp_data_catalog  /tmp                                                      lcfor parallel
+%compiler_name     mpif90                                                    lcfor parallel
+%compiler_name_ser gfortran                                                  lcfor parallel
+%cpp_options       -DMPI_REAL=MPI_DOUBLE_PRECISION:-DMPI_2REAL=MPI_2DOUBLE_PRECISION:-D__lc:-D__netcdf:-D__netcdf4:-D__parallel  lcfor parallel
+%netcdf_inc        -I/opt/netcdf/4.2.1.1/include                             lcfor parallel
+%netcdf_lib        -lnetcdff:-lnetcdf                                        lcfor parallel
+%mopts             -j:4                                                      lcfor parallel
+%fopts             -Ofast:-IPA:-mtune=native:-march=native:-cpp:-fdefault-real-8:-fbackslash:-fconvert=little-endian   lcfor parallel
+%lopts             -Ofast:-IPA:-mtune=native:-march=native:-cpp:-fdefault-real-8:-fbackslash                           lcfor parallel
+
+################################################################################
+# Configuration for FLOW
+#
+# The next block contains all informations for compiling the PALM code
+# and for generating and running the PALM executable using MPI. Replace <USERNAME_FLOW>
 # with your username on FLOW and if necessary "/fw/" by "/iwes/".
 # The following 'lcflow parallel' block assumes PALM compilation and execution
 # on host flow. Please note that other hosts may require different settings.
-#
-%remote_username   <replace by your username>                                      lcflow parallel
-%tmp_user_catalog  /data/work/fw/<replace by your username>/tmp                    lcflow parallel
-%tmp_data_catalog  /data/work/fw/<replace by your username>/palm_restart_data      lcflow parallel
-%compiler_name     mpiifort                                                        lcflow parallel
-%compiler_name_ser ifort                                                           lcflow parallel
-%cpp_options       -cpp:-DMPI_REAL=MPI_DOUBLE_PRECISION:-DMPI_2REAL=MPI_2DOUBLE_PRECISION:-D__netcdf:-D__netcdf4:-D__lc:-D__parallel     lcflow parallel
-%netcdf_inc        -I$$NETCDFF_INCLUDE                                             lcflow parallel
-%netcdf_lib        -L$$NETCDFF_DIR:-lnetcdff:-L$$NETCDF_DIR:-lnetcdf               lcflow parallel
-%mopts             -j:4                                                            lcflow parallel
-%fopts             -xSSE4.2:-O3:-r8:-align:all:-ftz:-fno-alias:-no-scalar-rep:-ip:-nbs:-convert:little_endian                lcflow parallel
-%lopts             -xSSE4.2:-O3:-r8:-align:all:-ftz:-fno-alias:-no-scalar-rep:-ip:-nbs:-limf:-lm:-Vaxlib                               lcflow parallel
-%login_init_cmd    .:/cm/local/apps/environment-modules/3.2.6/Modules/3.2.6/init/bash\;:MODULEPATH=/cm/shared/modulefiles/   lcflow parallel
-%modules           netcdf/4.2.1.1/intel/64/2011.0.013:netcdf-fortran/4.2/intel/64/2011.0.013:intel/ics/64/2011.0.013:intel/impi/4.0.1.007/64:hdf5/1.8.9/intel/64/2011.0.013:qt4/4.8.2  lcflow parallel 
+################################################################################
+%remote_username   <USERNAME_FLOW>                                                                                               lcflow parallel
+%tmp_user_catalog  /data/work/fw/$remote_username/tmp                                                                            lcflow parallel
+%tmp_data_catalog  /data/work/fw/$remote_username/palm_restart_data                                                              lcflow parallel
+%compiler_name     mpiifort                                                                                                      lcflow parallel
+%compiler_name_ser ifort                                                                                                         lcflow parallel
+%cpp_options       -DMPI_REAL=MPI_DOUBLE_PRECISION:-DMPI_2REAL=MPI_2DOUBLE_PRECISION:-D__lc:-D__netcdf:-D__netcdf4:-D__parallel  lcflow parallel
+%netcdf_inc        -I/cm/shared/apps/netcdf-fortran/4.2/intel/64/2011.0.013/include                                              lcflow parallel
+%netcdf_lib        -L/cm/shared/apps/netcdf-fortran/4.2/intel/64/2011.0.013/lib:-lnetcdff:-L/cm/shared/apps/netcdf/4.2.1.1/intel/64/2011.0.013/lib:-lnetcdf:-L/cm/shared/apps/hdf5/1.8.9/intel/64/2011.0.013/lib:-Wl,-rpath:/cm/shared/apps/hdf5/1.8.9/intel/64/2011.0.013/lib:-Wl,-rpath:/cm/shared/apps/netcdf/4.2.1.1/intel/64/2011.0.013/lib:-Wl,-rpath:/cm/shared/apps/netcdf-fortran/4.2/intel/64/2011.0.013/lib       lcflow parallel
+%mopts             -j:8                                                                                                          lcflow parallel
+%fopts             -xhost:-O3:-fpp:-r8:-align:all:-ftz:-fno-alias:-no-scalar-rep:-no-prec-sqrt:-ip:-nbs:-convert:little_endian:-static-intel   lcflow parallel
+%lopts             -xhost:-O3:-fpp:-r8:-align:all:-ftz:-fno-alias:-no-scalar-rep:-no-prec-sqrt:-ip:-nbs:-static-intel:-Wl,-rpath:/cm/shared/apps/intel/ics-2011.0.013/composerxe-2011.0.084/compiler/lib/intel64          lcflow parallel
+%login_init_cmd    .:/cm/local/apps/environment-modules/3.2.6/Modules/3.2.6/init/bash\;:MODULEPATH=/cm/shared/modulefiles/                     lcflow parallel
+%modules           sge/6.2u5p2:netcdf/4.2.1.1/intel/64/2011.0.013:netcdf-fortran/4.2/intel/64/2011.0.013:intel/ics/64/2011.0.013:intel/impi/64/4.0.1.007:hdf5/1.8.9/intel/64/2011.0.013:qt4     lcflow parallel 
+%disc_space        50                                                                                                            lcflow parallel 
 #
 #
Index: /palm/trunk/SCRIPTS/.mrun.config.tatara
===================================================================
--- /palm/trunk/SCRIPTS/.mrun.config.tatara	(revision 1098)
+++ /palm/trunk/SCRIPTS/.mrun.config.tatara	(revision 1099)
@@ -25,5 +25,5 @@
 # required paths (given in <>) by the respective paths valid on your host.
 #
-%tmp_user_catalog  /tmp                                          lckyut parallel
+%tmp_user_catalog  <replace by your preferred tmp directory>     lckyut parallel
 %compiler_name     mpifrt                                        lckyut parallel
 %compiler_name_ser frt                                           lckyut parallel
Index: /palm/trunk/SCRIPTS/batch_scp
===================================================================
--- /palm/trunk/SCRIPTS/batch_scp	(revision 1098)
+++ /palm/trunk/SCRIPTS/batch_scp	(revision 1099)
@@ -22,5 +22,5 @@
 # Current revisions:
 # ------------------
-# 
+# LANG variable is unset in some ssh calls to guarantee messages in English
 #
 # Former revisions:
@@ -312,7 +312,7 @@
  if [[ $(echo $local_host | cut -c1-4) = gaia ]]
  then
-    ssh $SSH_PORTOPT $local_user@gaiad "ssh $SSH_PORTOPT $1 -l $remote_user \"cd $3; ls -1; echo '*** list complete'\" "  > $filelist  2>&1
+    ssh $SSH_PORTOPT $local_user@gaiad "ssh $SSH_PORTOPT $1 -l $remote_user \"unset LANG; cd $3; ls -1; echo '*** list complete'\" "  > $filelist  2>&1
  else
-    ssh $SSH_PORTOPT $1 -l $remote_user "cd $3; ls -1; echo '*** list complete'" > $filelist  2>&1
+    ssh $SSH_PORTOPT $1 -l $remote_user "unset LANG; cd $3; ls -1; echo '*** list complete'" > $filelist  2>&1
  fi
  ssh_status=$?
Index: /palm/trunk/SCRIPTS/mbuild
===================================================================
--- /palm/trunk/SCRIPTS/mbuild	(revision 1098)
+++ /palm/trunk/SCRIPTS/mbuild	(revision 1099)
@@ -22,5 +22,5 @@
 # Current revisions:
 # ------------------
-# 
+# adjustments for Forwind cluster (lcflow)
 #
 # Former revisions:
@@ -454,8 +454,9 @@
        # IP-ADRESSE DES REMOTE-RECHNERS BESTIMMEN
     case  $remote_host  in
+        (lcflow)         remote_addres="flow.hpc.uni-oldenburg.de";;
         (lckordi)        remote_adress=210.219.61.8;;
         (lcmuk)          remote_addres=130.75.105.2;;
         (lcrte)          remote_addres=133.5.185.60;;
-        (lcsb)           remote_adress=147.46.30.151;;
+        (lcsb)           remote_addres=147.46.30.151;;
         (lcsgib)         remote_addres=130.73.232.102;;
         (lcsgih)         remote_addres=130.75.4.101;;
@@ -1259,4 +1260,7 @@
           then
              . $modules
+          elif [[ $remote_host = lcflow ]]
+          then
+             eval `$MODULESHOME/bin/modulecmd ksh load ${modules}`
           else
              module load ${modules}
Index: /palm/trunk/SCRIPTS/mrun
===================================================================
--- /palm/trunk/SCRIPTS/mrun	(revision 1098)
+++ /palm/trunk/SCRIPTS/mrun	(revision 1099)
@@ -22,5 +22,7 @@
 # Current revisions:
 # ------------------
-# 
+# adjustments for Kyushu-University computing center (lckyuh - hayaka)
+# and for Forwind cluster (lcflow)
+# small further adjustments for lckyut
 #
 # Former revisions:
@@ -34,5 +36,5 @@
 #
 # 2013-02-02 07:06:13Z raasch
-# adjustments for Kyushu-University computing center (lckyut)
+# adjustments for Kyushu-University computing center (lckyut - tatara)
 #
 # 1083 2013-01-04 10:22:09Z maronga
@@ -514,5 +516,5 @@
     do_remote=true
     case  $host  in
-        (ibm|ibmh|ibmkisti|ibmku|ibms|ibmy|nech|necriam|lckyoto|lcsgib|lcsgih|unics|lcxe6|lcxt5m|lck|lckiaps|lckordi|lckyut|lcsb)  true;;
+        (ibm|ibmh|ibmkisti|ibmku|ibms|ibmy|nech|necriam|lcflow|lckyoto|lcsgib|lcsgih|unics|lcxe6|lcxt5m|lck|lckiaps|lckordi|lckyuh|lckyut|lcsb)  true;;
         (*)  printf "\n"
              printf "\n  +++ sorry: execution of batch jobs on remote host \"$host\""
@@ -600,4 +602,11 @@
  fi
 
+
+    # WERTE VON MRUN-OPTIONEN SICHERN UND DAMIT GEGEBENENFALLS SPAETER DIE
+    # IN DER KONFIGURAIONSDATEI ANGEGEBENEN WERTE UEBERSTEUERN
+ mrun_memory=$memory
+ mrun_group_number=$group_number
+ mrun_cpumax=$cpumax
+ mrun_numprocs=$numprocs
 
 
@@ -678,5 +687,5 @@
                    do_remote=true
                    case  $host  in
-                       (ibm|ibmh|ibmkisti|ibmku|ibms|ibmy|lckyoto|lcsgib|lcsgih|nech|necriam|unics|lcxe6|lcxt5m|lck|lckiaps|lckordi|lckyut|lcsb)  true;;
+                       (ibm|ibmh|ibmkisti|ibmku|ibms|ibmy|lcflow|lckyoto|lcsgib|lcsgih|nech|necriam|unics|lcxe6|lcxt5m|lck|lckiaps|lckordi|lckyuh|lckyut|lcsb)  true;;
                        (*)  printf "\n  +++ sorry: execution of batch jobs on remote host \"$host\""
                             printf "\n      is not available"
@@ -817,11 +826,4 @@
 %%END%%
 
-       # WERTE VON MRUN-OPTIONEN SICHERN UND DAMIT GEGEBENENFALLS SPAETER DIE
-       # IN DER KONFIGURAIONSDATEI ANGEGEBENEN WERTE UEBERSTEUERN
-    mrun_memory=$memory
-    mrun_group_number=$group_number
-    mrun_cpumax=$cpumax
-    mrun_numprocs=$numprocs
-
     if [[ $localhost_realname = "sx-fep" ]]
     then
@@ -866,14 +868,14 @@
     rm  $interpreted_config_file
 
-
-       # OPTIONSWERTE UEBERSTEUERN KONFIGURATIONSDATEI
-    [[ $mrun_memory     != 0   ]]  &&  memory=$mrun_memory
-    [[ "$mrun_group_number" != "none" ]]  &&  group_number=$mrun_group_number
-    [[ $mrun_cpumax     != 0   ]]  &&  cpumax=$mrun_cpumax
-    [[ "$mrun_numprocs" != ""  ]]  &&  numprocs=$mrun_numprocs
-    [[ "$max_par_io_str" != "" ]]  &&  maximum_parallel_io_streams=$max_par_io_str
-    [[ "$mrun_tasks_per_node" != "" ]]  &&  tasks_per_node=$mrun_tasks_per_node
-
- fi
+ fi
+
+
+    # OPTIONSWERTE UEBERSTEUERN KONFIGURATIONSDATEI
+ [[ $mrun_memory     != 0   ]]  &&  memory=$mrun_memory
+ [[ "$mrun_group_number" != "none" ]]  &&  group_number=$mrun_group_number
+ [[ $mrun_cpumax     != 0   ]]  &&  cpumax=$mrun_cpumax
+ [[ "$mrun_numprocs" != ""  ]]  &&  numprocs=$mrun_numprocs
+ [[ "$max_par_io_str" != "" ]]  &&  maximum_parallel_io_streams=$max_par_io_str
+ [[ "$mrun_tasks_per_node" != "" ]]  &&  tasks_per_node=$mrun_tasks_per_node
 
 
@@ -962,5 +964,5 @@
     do_remote=true
     case  $host  in
-        (ibm|ibmh|ibmkisti|ibmku|ibms|ibmy|lckyoto|lcsgib|lcsgih|nech|necriam|unics|lcxe6|lcxt5m|lck|lckiaps|lckordi|lckyut|lcsb)  true;;
+        (ibm|ibmh|ibmkisti|ibmku|ibms|ibmy|lcflow|lckyoto|lcsgib|lcsgih|nech|necriam|unics|lcxe6|lcxt5m|lck|lckiaps|lckordi|lckyuh|lckyut|lcsb)  true;;
         (*)  printf "\n"
              printf "\n  +++ sorry: execution of batch jobs on remote host \"$host\""
@@ -1122,5 +1124,6 @@
         (lckiaps)    queue=normal;;
         (lckyoto)    queue=ph;;
-        (lckyut)     queue=cx-dbg;;
+        (lckyuh)     queue=fx-single;;
+        (lckyut)     queue=cx-single;;
         (lcsgib)     queue=testq;;
         (lcsgih)     queue=testq;;
@@ -1870,5 +1873,5 @@
  lopts="$lopts $netcdf_lib $dvr_lib"
  ROPTS="$ropts"
-# if [[ ( $(echo $host | cut -c1-3) = nec  ||  $(echo $host | cut -c1-3) = ibm  ||  $host = lckyoto  ||  $host = lcsgih  ||  $host = lcsgib  ||  $host = lctit  ||  $host = lcfimm  ||  $host = lcxe6 ||  $host = lcxt5m || $host = lck || $host = lckiaps || $host = lckordi || $host = lcsb || $host )  &&  -n $numprocs ]]
+# if [[ ( $(echo $host | cut -c1-3) = nec  ||  $(echo $host | cut -c1-3) = ibm  ||  $host = lckyoto  ||  $host = lcsgih  ||  $host = lcsgib  ||  $host = lctit  ||  $host = lcfimm  ||  $host = lcflow  ||  $host = lcxe6 ||  $host = lcxt5m || $host = lck || $host = lckiaps || $host = lckordi || $host = lcsb || $host )  &&  -n $numprocs ]]
 # then
     XOPT="-X $numprocs"
@@ -3509,5 +3512,5 @@
                 # COPY HOSTFILE FROM SOURCE DIRECTORY OR CREATE IT, IF IT
                 # DOES NOT EXIST
-             if [[ $host != lcsgih  &&  $host != lcsgib ]]
+             if [[ $host != lcsgih  &&  $host != lcsgib  &&  $host != lckyu* ]]
              then
                 if [[ -f $hostfile ]]
@@ -3630,5 +3633,5 @@
                 elif [[ $host = lckyu* ]]
                 then
-                   mpiexec -n $ii   a.out  <  runfile_atmos  $ROPTS
+                   mpiexec -n $ii  ./a.out  < runfile_atmos  $ROPTS
                 else
                    mpiexec  -machinefile hostfile  -n $ii  a.out  < runfile_atmos  $ROPTS
@@ -4527,5 +4530,5 @@
           then
 
-             if [[ $localhost = lcsgih  ||  $localhost = lcsgib  ||  $localhost = nech  ||  $localhost = ibmh  ||  $localhost = ibmkisti  ||  $localhost = ibmku  ||  $localhost = ibms ]]
+             if [[ $localhost = lcsgih  ||  $localhost = lcsgib  ||  $localhost = nech  ||  $localhost = ibmh  ||  $localhost = ibmkisti  ||  $localhost = ibmku  ||  $localhost = ibms  ||  $localhost = lcflow  ||  $localhost = lckyu* ]]
              then
                 echo "*** ssh will be used to initiate restart-runs!"
@@ -4771,6 +4774,9 @@
           # ABSPEICHERN DER KONFIGURATIONSDATEI
           # ABDECKZEICHEN VERHINDERN, DASS ERSETZUNGEN ERFOLGEN
+          # Lines with #$ coming from the svn keyword substitution are
+          # removed from the config file in order to avoid problems
+          # with the SGE batch system
        echo  "cat > $config_file << \"%END%\""      >>  $jobfile
-       cat   $config_file                           >>  $jobfile
+       sed 's/#$.*//g'   $config_file               >>  $jobfile
        echo  "%END%"                                >>  $jobfile
        echo  " "                                    >>  $jobfile
@@ -4835,4 +4841,8 @@
     then
        echo  "export PALM_BIN=$PALM_BIN"                >>  $jobfile
+    elif [[ $host = lcflow  ||  $localhost = lcflow ]]
+    then
+       echo  "export PALM_BIN=$PALM_BIN" | sed -e 's:'$HOME':$HOME:'   >>  $jobfile
+       echo  "export PATH=\$PATH:\$PALM_BIN"              >>  $jobfile
     fi
 
@@ -4840,4 +4850,7 @@
     echo  "set -x"                                      >>  $jobfile
     echo  "queue=$queue"                                >>  $jobfile
+#    echo  "echo \"*** shell test\" "                    >>  $jobfile
+#    echo  "which ksh"                                   >>  $jobfile
+#    echo  "ls -al /bin"                                 >>  $jobfile
     echo  "[[ \$execute_mrun = true ]]  &&  ./$mrun_com"  >>  $jobfile
 
Index: /palm/trunk/SCRIPTS/subjob
===================================================================
--- /palm/trunk/SCRIPTS/subjob	(revision 1098)
+++ /palm/trunk/SCRIPTS/subjob	(revision 1099)
@@ -23,5 +23,6 @@
 # Current revisions:
 # ------------------
-# 
+# adjustments for Kyushu-Univeristy computing center (lckyuh - hayaka)
+# and for Forwind cluster (lcflow)
 #
 # Former revisions:
@@ -34,5 +35,5 @@
 #
 # 2013-02-02 07:06:13Z raasch
-# adjustments for Kyushu-University computing center (lckyut)
+# adjustments for Kyushu-University computing center (lckyut - tatara)
 # old changelog messages removed
 #
@@ -128,4 +129,6 @@
      (elephanta)             local_addres=130.75.105.6;   local_host=lcmuk;;
      (fimm.bccs.uib.no)      local_addres=172.20.4.2;     local_host=lcfimm;;
+     (flow01)                local_addres=10.141.255.71;  local_host=lcflow;;
+     (flow02)                local_addres=10.141.255.72;  local_host=lcflow;;
      (node*)                 local_addres=165.132.26.61   local_host=lck;;
    #  (node*)                 local_addres=210.219.61.8    local_host=lckordi;;
@@ -135,4 +138,5 @@
      (gregale)               local_addres=130.75.105.109; local_host=lcmuk;;
      (hababai)               local_addres=130.75.105.108; local_host=lcmuk;;
+     (hayaka*)               local_addres=133.5.4.33;     local_host=lckyuh;;
      (hexagon.bccs.uib.no)   local_addres=129.177.20.113; local_host=lcxe6;;
      (hd1)                   local_addres=130.75.4.104;   local_host=lcsgih;;
@@ -150,4 +154,5 @@
      (login*)                local_addres=118.128.66.223; local_host=lckiaps;;
      (maestro)               local_addres=130.75.105.2;   local_host=lcmuk;;
+     (meller)                local_addres=134.106.74.155; local_host=lcfor;;
      (meteo-login*)          local_addres=193.166.211.144;local_host=lcxt5m;;
      (hexagon*)		     local_addres=129.177.20.113; local_host=lcxe6;;
@@ -156,4 +161,5 @@
      (ostria)                local_addres=130.75.105.106; local_host=lcmuk;;
      (paesano)               local_addres=130.75.105.46;  local_host=lcmuk;;
+     (pcj*)                  local_addres=172.31.120.1;   local_host=lckyut;;
      (pingui)                local_addres=134.106.74.118; local_host=lcfor;;
      (quanero)               local_addres=130.75.105.107; local_host=lcmuk;;
@@ -297,4 +303,5 @@
         (ibmy)    queue=parallel; remote_addres=165.132.26.58; submcom=/usr/lpp/LoadL/full/bin/llsubmit;;
 	(lcfimm)  remote_addres=172.20.4.2; submcom=/opt/torque/bin/qsub;;
+        (lcflow)  remote_addres=10.140.1.71; submcom=/cm/shared/apps/sge/6.2u5p2/bin/lx26-amd64/qsub;;
         (lckyoto) remote_addres=133.3.51.11; submcom=/thin/local/bin/qsub;;
         (lcsgib)  queue=smallq; remote_addres=130.73.232.104; submcom=/opt/moab/bin/msub;;
@@ -303,4 +310,5 @@
         (lckiaps) remote_addres=118.128.66.223; submcom=/cm/shared/apps/pbspro/11.0.2.110766/bin/qsub;;
         (lckordi) remote_addres=210.219.61.8; submcom=/usr/torque/bin/qsub;;
+        (lckyuh)  remote_addres=133.5.4.33; submcom=/usr/bin/pjsub;;
         (lckyut)  remote_addres=133.5.4.37; submcom=/usr/bin/pjsub;;
         (lcsb)    remote_addres=147.46.30.151; submcom=/usr/torque/bin/qsub;;
@@ -349,4 +357,8 @@
                      (*)                                     error=true;;
                  esac;;
+        (lcflow) case  $ndq  in
+                     (cfd_lom_long.q|cfd_him_long.q|cfd_lom_serl.q|cfd_lom_shrt.q|cfd_him_shrt.q)  error=false;;
+                     (*)                                     error=true;;
+                 esac;;
         (lckiaps) case  $ndq  in
                      (express|normal)                        error=false;;
@@ -355,4 +367,8 @@
         (lckyoto) case  $ndq  in
                      (eh|ph)                                 error=false;;
+                     (*)                                     error=true;;
+                 esac;;
+        (lckyuh) case  $ndq  in
+                     (fx-dbg|fx-single|fx-small|fx-middle|fx-large)  error=false;;
                      (*)                                     error=true;;
                  esac;;
@@ -753,4 +769,42 @@
     fi
 
+ elif [[ $remote_host = lcflow ]]
+ then
+    if [ $memory -gt 1900 ]; then
+      use_himem=""
+    else
+      use_himem="#"
+    fi
+    if [[ $numprocs != 0 ]]
+    then
+      pe_set="#$ -pe impi $numprocs"
+    else
+      pe_set="#$ -pe impi 1"
+    fi
+    if [[ $queue = default ]]
+    then
+      queue_set=""
+    else
+      queue_set="#$ -q $queue"
+    fi
+    [[ "$disc_space" = "" ]]  &&  disc_space=50
+
+       cat > $job_to_send << %%END%%
+#!/bin/bash
+#$ -S /bin/bash
+#$ -N $job_name
+#$ -cwd
+#$ -l h_rt=$timestring
+#$ -l h_vmem=${memory}M
+#$ -o $remote_dayfile
+#$ -j y
+$pe_set
+#$ -R y
+${use_himem}#$ -l highmem=true
+#$ -l h_fsize=${disc_space}G
+$queue_set
+
+%%END%%
+
  elif [[ $remote_host = lck || $remote_host = lckordi || $remote_host = lcsb ]]
  then
@@ -1029,16 +1083,33 @@
     fi
 
- elif [[ $remote_host = lckyut ]]
+ elif [[ $remote_host = lckyuh ]]
  then
     cat > $job_to_send << %%END%%
 #!/bin/bash
+#PJM -L "rscgrp=$queue"
+#PJM -L "node=$nodes"
+#PJM --mpi "proc=$numprocs"
+#PJM -L "elapse=$timestring"
+#PJM -o $remote_dayfile
+#PJM -j
+#PJM -X
+#PJM --no-stging
+
+export LANG=en_US.UTF-8
+%%END%%
+
+ elif [[ $remote_host = lckyut ]]
+ then
+    cat > $job_to_send << %%END%%
+#!/bin/bash
+#PJM -L "rscgrp=$queue"
 #PJM -L "vnode=$numprocs"
 #PJM -L "vnode-core=1"
-#PJM -L "rscgrp=$queue"
-#PJM --no-stging
 #PJM -L "elapse=$timestring"
 #PJM --mpi proc=$numprocs
 #PJM -o $remote_dayfile
 #PJM -j
+#PJM -X
+#PJM --no-stging
 
 export LANG=en_US.UTF-8
@@ -1162,5 +1233,5 @@
     echo "trap '"                               >>  $job_to_send
     echo "set +vx"                              >>  $job_to_send
-    if [[ $(echo $remote_host | cut -c1-3) = ibm  ||  $(echo $remote_host | cut -c1-5) = lcsgi  ||  $(echo $remote_host | cut -c1-3) = nec  ||  $remote_host = lckiaps  ||  $remote_host = lckyut ]]
+    if [[ $(echo $remote_host | cut -c1-3) = ibm  ||  $(echo $remote_host | cut -c1-5) = lcsgi  ||  $(echo $remote_host | cut -c1-3) = nec  ||  $remote_host = lcflow  ||  $remote_host = lckiaps  ||  $remote_host = lckyu* ]]
     then
        if [[ $remote_host = ibmh ]]
@@ -1188,4 +1259,7 @@
        then
           return_queue=express
+       elif [[ $remote_host = lckyuh ]]
+       then
+          return_queue=cx-single
        elif [[ $remote_host = lckyut ]]
        then
@@ -1255,4 +1329,21 @@
           echo "%%END%%"                           >>  $job_to_send
 
+       elif [[ $remote_host = lckyuh ]]
+       then
+          echo "cat > scpjob.$kennung << %%END%%"  >>  $job_to_send
+          echo "#!/bin/bash"                       >>  $job_to_send
+          echo "#PJM -L \"node=1\""                >>  $job_to_send
+          echo "#PJM -L \"rscgrp=$return_queue\""  >>  $job_to_send
+          echo "#PJM --no-stging"                  >>  $job_to_send
+          echo "#PJM -L \"elapse=30:00\""          >>  $job_to_send
+          echo "#PJM -o \$HOME/job_queue/last_job_transfer_protocol"  >>  $job_to_send
+          echo "#PJM -j"                           >>  $job_to_send
+          echo " "                                 >>  $job_to_send
+          echo "export LANG=en_US.UTF-8"           >>  $job_to_send
+          echo "set -x"                            >>  $job_to_send
+          echo "batch_scp  $PORTOPT  -d  -w 10  -u $local_user $local_addres  $remote_dayfile  \"$job_catalog\"  $local_dayfile"  >>  $job_to_send
+          echo "[[ \"\$for_subjob_to_do\" != \"\" ]]  &&  eval \$for_subjob_to_do"  >>  $job_to_send
+          echo "%%END%%"                           >>  $job_to_send
+
        elif [[ $remote_host = lckyut ]]
        then
@@ -1288,4 +1379,27 @@
           echo "[[ \"\$for_subjob_to_do\" != \"\" ]]  &&  eval \$for_subjob_to_do"  >>  $job_to_send
           echo "%%END%%"                           >>  $job_to_send
+
+       elif [[ $remote_host = lcflow ]]
+       then
+          echo "cat > scpjob.${kennung}.tmp << %%END%%"                  >>  $job_to_send
+          echo "#!/bin/bash"                                             >>  $job_to_send
+          echo "SGEPREFIX -S /bin/bash"                                  >>  $job_to_send
+          echo "SGEPREFIX -N transfer_$job_name"                         >>  $job_to_send
+          echo "SGEPREFIX -cwd"                                          >>  $job_to_send
+          echo "SGEPREFIX -l h_rt=01:00:00"                              >>  $job_to_send
+          echo "SGEPREFIX -l h_vmem=100M"                                >>  $job_to_send
+          echo "SGEPREFIX -j y"                                          >>  $job_to_send
+          echo "SGEPREFIX -o ${local_host}_${job_name}_scpjob_$kennung"  >>  $job_to_send 
+          echo " "                                                       >>  $job_to_send 
+          echo "set -x"                                                  >>  $job_to_send 
+          echo "export PALM_BIN=$PALM_BIN" | sed -e 's:'$HOME':$HOME:'   >>  $job_to_send
+          echo "export PATH=\$PATH:\$PALM_BIN"                           >>  $job_to_send
+          echo ""                                 >>  $job_to_send         
+          echo "batch_scp  $PORTOPT  -d  -w 10  -u $local_user $local_addres  ${job_catalog}/$remote_dayfile  \"$job_catalog\"  $local_dayfile"  >>  $job_to_send
+          echo "[[ \"\$for_subjob_to_do\" != \"\" ]]  &&  eval \$for_subjob_to_do"  >>  $job_to_send
+          echo "rm -f scpjob.${kennung}"                                 >>  $job_to_send         
+          echo "%%END%%"                                                 >>  $job_to_send
+          echo "sed -e 's/SGEPREFIX/#$/g' scpjob.${kennung}.tmp > scpjob.${kennung}" >>  $job_to_send         
+          echo "rm -f scpjob.${kennung}.tmp"                             >>  $job_to_send         
 
        else
@@ -1334,8 +1448,12 @@
           echo "ssh $SSH_PORTOPT ${remote_username}@${remote_addres}  \"$submcom ${job_catalog}/scpjob.$kennung\" "  >>  $job_to_send
           echo "rm  ${job_catalog}/scpjob.$kennung"          >>  $job_to_send
-       elif [[ $remote_host = lckyut ]]
+       elif [[ $remote_host = lckyu* ]]
        then
           echo "scp $PORTOPT scpjob.$kennung  ${remote_username}@${remote_addres}:job_queue"           >>  $job_to_send
           echo "ssh $SSH_PORTOPT ${remote_username}@${remote_addres}  \"cd job_queue; $submcom scpjob.$kennung; rm scpjob.$kennung\" "  >>  $job_to_send
+       elif [[ $remote_host = lcflow ]]
+       then
+          echo "mv  scpjob.$kennung  $job_catalog"           >>  $job_to_send
+          echo "ssh ${remote_username}@${remote_addres}  \"$init_cmds $module_calls cd $job_catalog; $submcom scpjob.$kennung\" "  >>  $job_to_send
        else
           echo "$submcom  scpjob.$kennung"      >>  $job_to_send
@@ -1370,5 +1488,5 @@
 
     # remove job file
- if [[ $remote_host = lctit  ||  $remote_host = ibmku ]]
+ if [[ $remote_host = lctit  ||  $remote_host = ibmku  ||  $remote_host = lcflow ]]
  then
     echo " "                               >>  $job_to_send
@@ -1440,4 +1558,7 @@
        then
           ssh  $SSH_PORTOPT $remote_addres  -l $remote_user  "cd $job_catalog; $submcom $job_on_remhost"
+       elif [[ $remote_host = lcflow ]]
+       then
+          ssh  $SSH_PORTOPT $remote_addres  -l $remote_user  "$init_cmds $module_calls cd $job_catalog; $submcom $job_on_remhost"
        else
           ssh  $SSH_PORTOPT $remote_addres  -l $remote_user  "cd $job_catalog; $submcom $job_on_remhost; rm $job_on_remhost"
@@ -1450,5 +1571,5 @@
        then
           eval  $submcom  $job_on_remhost
-       elif [[  $local_host = lcfimm  ||  $local_host = lctit  ||  $localhost = lcxe6  ||  $localhost = lck  || $localhost = lckordi ||  $localhost = lcyon || $localhost = lcsb  ||  $localhost = lckyut ]]
+       elif [[  $local_host = lcfimm  ||  $local_host = lctit  ||  $localhost = lcxe6  ||  $localhost = lck  || $localhost = lckordi ||  $localhost = lcyon || $localhost = lcsb  ||  $localhost = lckyu* ]]
        then
           chmod  u+x  $job_on_remhost
@@ -1469,5 +1590,5 @@
           # Jobfile must not be deleted on lctit/ibmku!! This will be done
           # only at the end of the job.
-       if [[ $local_host != lctit  &&  $local_host != ibmku ]]
+       if [[ $local_host != lctit  &&  $local_host != ibmku  &&  $local_host != lcflow ]]
        then
           rm  $job_on_remhost
@@ -1483,5 +1604,5 @@
  if [[ $no_submit = false ]]
  then
-    rm  $job_to_send
+    rm  -f $job_to_send
  fi
  [[ $verify = true ]]  &&  printf "\n\n *** SUBJOB finished \n\n"
