Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
Plumed AlphaFold
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Package registry
Model registry
Operate
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Martin Kurečka
Plumed AlphaFold
Commits
b5e45b36
There was an error fetching the commit references. Please try again later.
Commit
b5e45b36
authored
11 years ago
by
Giovanni Bussi
Browse files
Options
Downloads
Patches
Plain Diff
Clarified usage of dot in regexp
parent
da3dfd82
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
regtest/basic/rt60-cregex/plumed.dat
+6
-5
6 additions, 5 deletions
regtest/basic/rt60-cregex/plumed.dat
user-doc/Regex.txt
+15
-3
15 additions, 3 deletions
user-doc/Regex.txt
with
21 additions
and
8 deletions
regtest/basic/rt60-cregex/plumed.dat
+
6
−
5
View file @
b5e45b36
t1: TORSION ATOMS=5,7,9,15
t1: TORSION ATOMS=5,7,9,15
t2: TORSION ATOMS=7,9,15,17
t2: TORSION ATOMS=7,9,15,17
d1: DISTANCE ATOMS=7,17 COMPONENTS
d1: DISTANCE ATOMS=7,17 COMPONENTS
PRINT ARG=(d1.[xy]),(pino) STRIDE=100 FILE=colvar FMT=%8.4f
d1ox: TORSION ATOMS=7,9,15,17
#PRINT ARG=(d1.[xy]),(t[0-9]) STRIDE=100 FILE=colvar FMT=%8.4f
PRINT ARG=(d1\.[xy]),(pino) STRIDE=100 FILE=colvar FMT=%8.4f
#PRINT ARG=(d1.[xy]|t[0-9]) STRIDE=100 FILE=colvar FMT=%8.4f
PRINT ARG=(d1\.[xy]),(t[0-9]) STRIDE=100 FILE=colvar1 FMT=%8.4f
#PRINT ARG=(d1.[xy]),(d1.[xy]) STRIDE=100 FILE=colvar FMT=%8.4f
PRINT ARG=(d1\.[xy]|t[0-9]) STRIDE=100 FILE=colvar2 FMT=%8.4f
#PRINT ARG=d1.x,d1.y STRIDE=100 FILE=colvar FMT=%8.4f
PRINT ARG=(d1\.[xy]),(d1.[xy]) STRIDE=100 FILE=colvar3 FMT=%8.4f
PRINT ARG=(d1.[xy]) STRIDE=100 FILE=colvar4 FMT=%8.4f
This diff is collapsed.
Click to expand it.
user-doc/Regex.txt
+
15
−
3
View file @
b5e45b36
...
@@ -14,10 +14,22 @@ name have no spaces indeed, so why using them?).
...
@@ -14,10 +14,22 @@ name have no spaces indeed, so why using them?).
As an example
As an example
\verbatim
\verbatim
d1: DISTANCE ATOMS=1,2 COMPONENTS
d1: DISTANCE ATOMS=1,2 COMPONENTS
PRINT ARG=(d1.[xy]) STRIDE=100 FILE=colvar FMT=%8.4f
PRINT ARG=(d1
\
.[xy]) STRIDE=100 FILE=colvar FMT=%8.4f
\endverbatim
\endverbatim
selects for printout both d1.x and d1.y components which are generated through distance in the order they are created by plumed.
selects for printout both d1.x and d1.y components which are generated through distance in the order they are created by plumed.
Notice that the "." character should be escaped if one wants to interpret it as a literal ".". Unescaped dots will match any character,
according to regular expression syntax. E.g.
\verbatim
d1: DISTANCE ATOMS=1,2 COMPONENTS
dxy: DISTANCE ATOMS=1,3
# this will match d1.x,d1.y,dxy
PRINT ARG=(d1.[xy]) STRIDE=100 FILE=colvar FMT=%8.4f
# this will match d1.x,d1.y only
PRINT ARG=(d1\.[xy]) STRIDE=100 FILE=colvar FMT=%8.4f
\endverbatim
You can also include more by using comma separated regular expressions
You can also include more by using comma separated regular expressions
...
@@ -25,7 +37,7 @@ You can also include more by using comma separated regular expressions
...
@@ -25,7 +37,7 @@ You can also include more by using comma separated regular expressions
t1: TORSION ATOMS=5,7,9,15
t1: TORSION ATOMS=5,7,9,15
t2: TORSION ATOMS=7,9,15,17
t2: TORSION ATOMS=7,9,15,17
d1: DISTANCE ATOMS=7,17 COMPONENTS
d1: DISTANCE ATOMS=7,17 COMPONENTS
PRINT ARG=(d1.[xy]),(t[0-9]) STRIDE=100 FILE=colvar FMT=%8.4f
PRINT ARG=(d1
\
.[xy]),(t[0-9]) STRIDE=100 FILE=colvar FMT=%8.4f
\endverbatim
\endverbatim
(this selects t1,t2,d1.x and d2.x) Beware if you have overlapping selection they will be duplicated.
(this selects t1,t2,d1.x and d2.x) Beware if you have overlapping selection they will be duplicated.
...
@@ -36,7 +48,7 @@ You can equivalently use (recommended) regexp themself with the "or" operator.
...
@@ -36,7 +48,7 @@ You can equivalently use (recommended) regexp themself with the "or" operator.
t1: TORSION ATOMS=5,7,9,15
t1: TORSION ATOMS=5,7,9,15
t2: TORSION ATOMS=7,9,15,17
t2: TORSION ATOMS=7,9,15,17
d1: DISTANCE ATOMS=7,17 COMPONENTS
d1: DISTANCE ATOMS=7,17 COMPONENTS
PRINT ARG=(d1.[xy]|t[0-9]) STRIDE=100 FILE=colvar FMT=%8.4f
PRINT ARG=(d1
\
.[xy]|t[0-9]) STRIDE=100 FILE=colvar FMT=%8.4f
\endverbatim
\endverbatim
that selects the same arguments.
that selects the same arguments.
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment