#!/bin/bash for i in {0..110} do cat_g_f -f m001\_$i\_sot.xtc m002\_$i\_sot.xtc m003\_$i\_sot.xtc m004\_$i\_sot.xtc m005\_$i\_sot.xtc m006\_$i\_sot.xtc m007\_$i\_sot.xtc m008\_$i\_sot.xtc m009\_$i\_sot.xtc m010\_$i\_sot.xtc m011\_$i\_sot.xtc m012\_$i\_sot.xtc m013\_$i\_sot.xtc -cat -o m\_$i.xtc -nice 0 (anyone has some suggestions about how to optimize above one, it may reach to m100, here I only type to 13, ) done Thanks with best regards.