4
$\begingroup$

I am trying to write the analysis using gmx energy in a bash script. When this is usually passed on a command line, it asks for an input from keyboard to choose the energy term from a list of terms.

This can be automated in a bash script using the keyword echo as follows:

echo Temperature | gmx energy -f md.edr

Or

echo "11 0" | gmx energy -f md.edr

However the problem comes when the energy term is "1/Viscosity" . It recognises only the number 1 and outputs the first energy term. I have tried placing it in quotes, as well as preceding it with a $ sign. None of them work. How to overcome this problem when the energy term doesn't start with a letter?

$\endgroup$

0

You must log in to answer this question.

Browse other questions tagged .