CCL:G: Gausian 09 Easiest way to subtract structures/coordinates
- From: "Kanters, Rene"
<rkanters(a)richmond.edu>
- Subject: CCL:G: Gausian 09 Easiest way to subtract
structures/coordinates
- Date: Thu, 9 May 2013 10:30:26 +0000
Dear Anjan,
Here is a perl script I wrote some time ago to do that.
Cheers,
René
#! /usr/bin/perl
###############################################
# script to take a gaussian log file output and generate structure
# information (cartesian) for a new structure with a displacement
# along a frequency coordinate in the direction along the '-v' vibration
# for a displacement of '-d' times the vibrational vector
#
# command line arguments:
#
# -h : prints help and quits.
# -d float : displacement along vibrational mode default 0.1
# -v int : vibration number to use default 1
# required : filename (only sees last one)
################################################
#
$test = 0; # for debugging purposes (prints out extra stuff)
# set up the defaults
$vibration = 1;
$displacement = 0.1;
$file = "";
# 'constants' not using the 'use constant NAME => value;' method.
$C_STRUCTURE = "Standard orientation:";
$C_ENDSTRUCTURE = "---------";
$C_FREQUENCY = "Frequencies --";
while ($#ARGV >= 0) {
if ($ARGV[0] eq "-d") { $displacement = $ARGV[1]; shift /a\ARGV;
}
elsif ($ARGV[0] eq "-v") { $vibration = $ARGV[1]; shift /a\ARGV; }
elsif ($ARGV[0] eq "-h") { &usage(); exit;}
else { $file = $ARGV[0];}
shift /a\ARGV;
}
if ($file eq "") { &usage(); exit;}
open(IN,$file) || die "Could not open file '$file'.\n";
while (1) {
# read until I get a structure (should happen first) or a frequency
until ($_ = <IN>, $_ =~ /$C_STRUCTURE/ or $_ =~ /$C_FREQUENCY/ or eof) {
}
if ($_ =~ /$C_STRUCTURE/) { # READ THE STRUCTURE
$nat = -1; # reset the atom index counter : only need last structure
$at = (); # clear out the arrays of atomnumber, x, y and z
$x = ();
$y = ();
$z = ();
skiplines(4); # position read line to first atom in the list
while ($_ = <IN> and not $_ =~ /$C_ENDSTRUCTURE/ ) {
/a\tokens = split(' ', $_);
$nat++;
$at[$nat] = $tokens[1];
$xind = $#tokens - 2; # needed if the atomic type is missing (happens
sometimes).
$x[$nat] = $tokens[$xind];
$y[$nat] = $tokens[$xind+1];
$z[$nat] = $tokens[$xind+2];
}
} elsif ($_ =~ /$C_FREQUENCY/) { # READ THE FREQUENCY INFORMATION
# since there are three vibrations per line, I can determine how
# many of these I need to skip before I can read the frequency I need.
$skipsize = 4 + ($nat+1) + 3; # skip rest header, vibrations and start
header
for ($i=0; $i<int($vibration/3); $i++) { skiplines($skipsize); }
skiplines(4);
$xind = 2 + (($vibration-1) % 3) * 3; # position in the tokens of vib vector
if ($test eq 1) { print "vibration = $vibration, xind = $xind\n";
}
for ($i=0;$i<=$nat;$i++) {
$_ = <IN>;
/a\tokens = split(' ',$_);
if ($test eq 1 ) {
print "input $_";
print "($x[$i],$y[$i],$z[$i]) + $displacement x
($tokens[$xind],$tokens[$xind+1],$tokens[$xind+2])\n";
}
printf "%4d % .6f % .6f % .6f\n",$at[$i],
$x[$i]+$displacement*$tokens[$xind], $y[$i]+$displacement*$tokens[$xind+1],
$z[$i]+$displacement*$tokens[$xind+2];
}
exit; # AND WE ARE DONE!!!!
} elsif (eof) { close IN; exit; }
}
##################################################
# skiplines : argument n: number of lines to skip
##################################################
sub skiplines {
local $n, $i;
$n = shift(/a\_);
for ($i=0;$i<$n;$i++) { <IN> || die "skiplines encountered
EOF."; }
}
##################################################
# usage prints a message about how to use sp2g03
##################################################
sub usage {
print <<ENDUSAGE;
Usage: nfreq [-h] [-d displacement] [-v vibrationnnumber] filename
-d : displacement step along vibrational mode default 0.1
-v : index of vibrational mode to follow default 1
-h : prints this help
Will create the structure '-d' along the '-v'th vibrational mode of the
stucture.
ENDUSAGE
}
On May 8, 2013, at 3:58 PM, Anjan Roy aroy6|,|uic.edu wrote:
Sent to CCL by: "Anjan Roy" [aroy6!^!uic.edu]
Hello,
My Gaussian 09 opimization returns a negative frequency, one solution suggested
was to distort the molecule in the direction if the negative freq motion. Could
someone kindly suggest how I can do this by subtracting structures in the
command line or by way of a GUI.
thank you
Anjan
-= This is automatically added to each message by the mailing script =-E-mail to
subscribers: CHEMISTRY/a\ccl.net<mailto:CHEMISTRY/a\ccl.net> or use:E-mail to administrators:
CHEMISTRY-REQUEST/a\ccl.net<mailto:CHEMISTRY-REQUEST/a\ccl.net> or usehttp://www.ccl.net/chemistry/sub_unsub.shtmlhttp-:-//www.ccl.net/spammers.txt--_000_A526E77202134A69BCAE22C6E72F66BDrichmondedu_
Content-Type: text/html; charset="iso-8859-1"
Content-ID: <277B10532EB38B4F9EA0BEACC3051E88/a\exchange.richmond.edu>
Content-Transfer-Encoding: quoted-printable
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;
charset=iso-8859-1">
</head>
<body style="word-wrap: break-word; -webkit-nbsp-mode: space;
-webkit-line-break: after-white-space; ">
Dear Anjan,
<div><br>
</div>
<div>Here is a perl script I wrote some time ago to do that.</div>
<div><br>
</div>
<div>Cheers,</div>
<div>René</div>
<div><br>
<div><span class="Apple-style-span" style="orphans: 2;
text-indent: 0px; widows: 2; -webkit-text-decorations-in-effect: none;
"><span class="Apple-style-span" style="orphans: 2;
text-indent: 0px; widows: 2; -webkit-text-decorations-in-effect: none;
">
<div style="word-wrap: break-word; -webkit-nbsp-mode: space;
-webkit-line-break: after-white-space; ">
<div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<div style="border-collapse: separate; color: rgb(0, 0, 0); font-family:
Helvetica; font-size: 12px; font-style: normal; font-variant: normal;
font-weight: normal; letter-spacing: normal; line-height: normal;
text-transform: none; white-space: normal; word-spacing: 0px;
-webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px;
-webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; margin-top: 0px;
margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">
<br>
</div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">#! /usr/bin/perl</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">###############################################</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"># script to take a gaussian log file output and generate
structure</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"># information (cartesian) for a new structure with a
displacement</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"># along a frequency coordinate in the direction along the
'-v' vibration</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"># for a displacement of '-d' times the vibrational
vector</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">#</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"># command line arguments:</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">#</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"># -h : prints
help and quits.</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"># -d float : displacement along vibrational mode
default 0.1</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"># -v int : vibration number to use
default 1</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"># required : filename (only sees last
one)</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">################################################</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"><br>
</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">#</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">$test = 0; # for debugging purposes (prints out
extra stuff)</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"><br>
</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"># set up the defaults</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">$vibration = 1;</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">$displacement = 0.1;</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">$file = "";</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"><br>
</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"># 'constants' not using the 'use constant NAME =>
value;' method.</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">$C_STRUCTURE = "Standard
orientation:";</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">$C_ENDSTRUCTURE =
"---------";</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">$C_FREQUENCY = "Frequencies
--";</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"><br>
</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">while ($#ARGV >= 0) {</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> if ($ARGV[0] eq "-d")
{ $displacement = $ARGV[1]; shift /a\ARGV;
}</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> elsif ($ARGV[0] eq "-v") {
$vibration = $ARGV[1]; shift /a\ARGV; }</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> elsif ($ARGV[0] eq "-h") {
&usage(); exit;}</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> else { $file =
$ARGV[0];}</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> shift /a\ARGV;</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">}</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"><br>
</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">if ($file eq "") { &usage();
exit;}</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"><br>
</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">open(IN,$file) || die "Could not open file
'$file'.\n";</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"><br>
</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">while (1) {</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> # read until I get a structure (should happen
first) or a frequency</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> until ($_ = <IN>, $_ =~
/$C_STRUCTURE/ or $_ =~ /$C_FREQUENCY/ or eof) { }</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> if ($_ =~ /$C_STRUCTURE/) { # READ
THE STRUCTURE</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> $nat = -1; # reset the
atom index counter : only need last structure</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> $at = (); #
clear out the arrays of atomnumber, x, y and z</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> $x = ();</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> $y = ();</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> $z = ();</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> skiplines(4); # position read line
to first atom in the list</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> while ($_ = <IN> and
not $_ =~ /$C_ENDSTRUCTURE/ ) {</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> /a\tokens = split(' ',
$_);</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">
$nat++;</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> $at[$nat] =
$tokens[1];</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> $xind = $#tokens - 2; #
needed if the atomic type is missing (happens
sometimes).</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> $x[$nat] =
$tokens[$xind];</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> $y[$nat] =
$tokens[$xind+1];</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> $z[$nat] =
$tokens[$xind+2];</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> }</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> } elsif ($_ =~ /$C_FREQUENCY/) { # READ THE
FREQUENCY INFORMATION</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> # since there are three vibrations
per line, I can determine how</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> # many of these I need to skip
before I can read the frequency I need.</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> $skipsize = 4 +
($nat+1) + 3; # skip rest header, vibrations and start
header</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> for ($i=0;
$i<int($vibration/3); $i++) { skiplines($skipsize);
}</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> </font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">
skiplines(4);</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> $xind = 2 + (($vibration-1)
% 3) * 3; # position in the tokens of vib vector</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> if ($test eq 1) { print
"vibration = $vibration, xind = $xind\n";
}</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> for
($i=0;$i<=$nat;$i++) {</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> $_ =
<IN>;</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> /a\tokens = split('
',$_);</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> if ($test eq 1 )
{</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> print
"input $_";</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> print
"($x[$i],$y[$i],$z[$i]) + $displacement x
($tokens[$xind],$tokens[$xind+1],$tokens[$xind+2])\n";</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">
}</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> printf "%4d
% .6f % .6f % .6f\n",$at[$i],
$x[$i]+$displacement*$tokens[$xind],
$y[$i]+$displacement*$tokens[$xind+1],
$z[$i]+$displacement*$tokens[$xind+2];</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> }</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> exit; # AND WE ARE
DONE!!!!</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> } elsif (eof) { close IN; exit;
}</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">}</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"><br>
</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">##################################################</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"># skiplines : argument n: number of lines to
skip</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">##################################################</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">sub skiplines {</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> local $n, $i;</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> $n = shift(/a\_);</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"> for ($i=0;$i<$n;$i++) {
<IN> || die "skiplines encountered EOF.";
}</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">}</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"><br>
</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"><br>
</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">##################################################</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"># usage prints a message about how to use
sp2g03</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">##################################################</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">sub usage {</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">print <<ENDUSAGE;</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">Usage: nfreq [-h] [-d displacement] [-v vibrationnnumber]
filename</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"><br>
</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">-d : displacement step along vibrational mode default
0.1</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">-v : index of vibrational mode to follow default
1</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">-h : prints this help</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2"><br>
</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">Will create the structure '-d' along the '-v'th
vibrational mode of the stucture.</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">ENDUSAGE</font></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px;
margin-left: 0px; ">
<font class="Apple-style-span" face="Monaco"
size="2">}</font></div>
<div style="border-collapse: separate; color: rgb(0, 0, 0); font-family:
Helvetica; font-size: 12px; font-style: normal; font-variant: normal;
font-weight: normal; letter-spacing: normal; line-height: normal;
text-transform: none; white-space: normal; word-spacing: 0px;
-webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px;
-webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; ">
<br>
</div>
</div>
<div style="border-collapse: separate; color: rgb(0, 0, 0); font-family:
Helvetica; font-size: 12px; font-style: normal; font-variant: normal;
font-weight: normal; letter-spacing: normal; line-height: normal;
text-transform: none; white-space: normal; word-spacing: 0px;
-webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px;
-webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; margin-top: 0px;
margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">
<br>
</div>
</div>
</div>
</div>
</span></span></div>
<div>
<div>On May 8, 2013, at 3:58 PM, Anjan Roy aroy6|,|uic.edu
wrote:</div>
<br class="Apple-interchange-newline">
<blockquote type="cite">
<div><br>
Sent to CCL by: "Anjan Roy"
[aroy6!^!uic.edu]<br>
Hello, <br>
<br>
My Gaussian 09 opimization returns a negative frequency, one solution suggested
<br>
was to distort the molecule in the direction if the negative freq motion. Could
<br>
someone kindly suggest how I can do this by subtracting structures in the
<br>
command line or by way of a GUI.<br>
<br>
thank you<br>
<br>
Anjan<br>
<br>
<br>
<br>
-= This is automatically added to each message by the mailing script
=-<br<br=<br<br>
<br>
E-mail to subscribers: <a href="mailto:CHEMISTRY/a\ccl.net">CHEMISTRY/a\ccl.net</a> or
use:<br>
<a href="http://www.ccl.net/cgi-bin/ccl/send_ccl_message">http://www.ccl.net/cgi-bin/ccl/send_ccl_message</a><br>
<br>
E-mail to administrators: <a href="mailto:CHEMISTRY-REQUEST/a\ccl.net">CHEMISTRY-REQUEST/a\ccl.net</a>
or use<br>
<a href="http://www.ccl.net/cgi-bin/ccl/send_ccl_message">http://www.ccl.net/cgi-bin/ccl/send_ccl_message</a><br>
<br<br>
<a href="http://www.ccl.net/chemistry/sub_unsub.shtml">http://www.ccl.net/chemistry/sub_unsub.shtml</a><br>
<br>
Before posting, check wait time at: <a href="http://www.ccl.net">http://www.ccl.net</a><br>
<br>
Job: <a href="http://www.ccl.net/jobs">http://www.ccl.net/jobs</a> <br>
Conferences: <a href="http://server.ccl.net/chemistry/announcements/conferences/">
http://server.ccl.net/chemistry/announcements/conferences/</a><br>
<br>
Search Messages: <a href="http://www.ccl.net/chemistry/searchccl/index.shtml">http://www.ccl.net/chemistry/searchccl/index.shtml</a><br>
<br<br>
<a href="http://www.ccl.net/spammers.txt">http://www.ccl.net/spammers.txt</a><br>
<br>
RTFI: <a href="http://www.ccl.net/chemistry/aboutccl/instructions/">http://www.ccl.net/chemistry/aboutccl/instructions/</a><br>
<br>
<br>
</div>
</blockquote>
</div>
<br>
</div>
</body>
</html>