<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
<META NAME="Generator" CONTENT="MS Exchange Server version 6.5.7653.19">
<TITLE>complex expressions</TITLE>
</HEAD>
<BODY>
<!-- Converted from text/plain format -->
<BR>
<P><FONT SIZE=2>Dear Molpro users,<BR>
<BR>
I am trying to enter a complex expression as a geometrical parameter in my input for the CH3F system. It is well known that the angles of a C3V symmetric top are related by cos(b) = 1 - 3/2 sin^2(a), where in this case b is the HCH angle and a is the FCH angle.<BR>
My z-matrix is as follows:<BR>
<BR>
----------------------------------------------------------------<BR>
<BR>
***,<BR>
memory,100,m<BR>
angstrom<BR>
<BR>
geometry={<BR>
c1,<BR>
h1, c1, rch;<BR>
f1, c1, rcf, h1, acf;<BR>
h2, c1, rch, h1, acos(1-1.5*(sin(acf))^2), f1, 120.000;<BR>
h3, c1, rch, h1, acos(1-1.5*(sin(acf))^2), f1, 240.000}<BR>
<BR>
rch = 1.087<BR>
!!!! ach = 110.2 --> acos(1-1.5*(sin(108.73))^2) evaluates to 110.20<BR>
rcf = 1.383<BR>
acf = 108.73<BR>
<BR>
rhf<BR>
<BR>
----------------------------------------------------------------<BR>
<BR>
Molpro outputs the following<BR>
<BR>
----------------------------------------------------------------<BR>
***,<BR>
memory,100,m<BR>
angstrom<BR>
<BR>
geometry={<BR>
c1,<BR>
h1, c1, rch;<BR>
f1, c1, rcf, h1, acf;<BR>
h2, c1, rch, h1, acos(1-1.5*(sin(acf))^2), f1, 120.000;<BR>
h3, c1, rch, h1, acos(1-1.5*(sin(acf))^2), f1, 240.000}<BR>
<BR>
rch = 1.087<BR>
!!!! ach = 110.2 ZUNIT=ANG<BR>
<BR>
SETTING RCH = 1.08700000<BR>
SETTING RCF = 1.38300000<BR>
SETTING ACF = 108.73000000<BR>
<BR>
Variable memory set to 100000000 words, buffer space 230000 words<BR>
<BR>
<BR>
<BR>
Recomputing integrals since basis changed<BR>
<BR>
<BR>
Using spherical harmonics<BR>
<BR>
? Possible error in Z matrix<BR>
Line 4 connection 2 expr=<BR>
ACOS(1-1.5*(SIN(ACF))^2)<BR>
? Apparently depends on a variable, but not one that is yet defined<BR>
<BR>
Z matrix Current Z-matrix<BR>
========<BR>
<BR>
Records: 700.0 700.0<BR>
Maximum, total, and current numbers of geometry points 100 0 0<BR>
Orientation using atomic masses <BR>
Rotational constants: 0.0000000 0.0000000 0.0000000 GHz (calculated with average atomic masses)<BR>
Unique atoms/degeneracy:<BR>
<BR>
# Tag N1 Distance N2 Angle N3 Angle J<BR>
Grp Chg Distance Angle Angle x y z<BR>
<BR>
1 1 C1 <BR>
1 6.0 0.0000000 0.0000000 0.0000000 0.0000000 0.0000000 0.0000000<BR>
2 2 H1 1 RCH <BR>
2 1.0 1.0870000 0.0000000 0.0000000 0.0000000 0.0000000 0.0000000<BR>
3 3 F1 1 RCF 2 ACF <BR>
3 9.0 1.3830000 108.7300000 0.0000000 0.0000000 0.0000000 0.0000000<BR>
4 4 H2 1 RCH 2 ACOS(1-1 3 120.000 0<BR>
2 1.0 1.0870000 110.2021617 120.0000000 0.0000000 0.0000000 0.0000000<BR>
5 5 H3 1 RCH 2 ACOS(1-1 3 240.000 0<BR>
2 1.0 1.0870000 110.2021617 240.0000000 0.0000000 0.0000000 0.0000000<BR>
<BR>
Variables on which Z-matrix depends:<BR>
Name: RCH RCF ACF RCH RCF ACF<BR>
Value: 0.0000000 A 0.0000000 A 0.0000000 D 0.0000000 A 0.0000000 0.0000000 0.0000000 A 0.0000000 D<BR>
Name: ACF RCH RCH <BR>
Value: 0.0000000 D 0.0000000 A 0.0000000 0.0000000 0.0000000 A 0.0000000 0.0000000<BR>
? Error<BR>
? Error in Z matrix<BR>
? The problem occurs in zmatrix.f:zmat_evaluate<BR>
<BR>
ERROR EXIT<BR>
CURRENT STACK: MAIN<BR>
<BR>
----------------------------------------------------------------------------------------<BR>
<BR>
When I run the job I get four command line errors:<BR>
<BR>
ERROR in 'sin(expr)' operand type mismatch<BR>
ERROR in 'sin(expr)' operand type mismatch<BR>
ERROR in 'sin(expr)' operand type mismatch<BR>
ERROR in 'sin(expr)' operand type mismatch<BR>
<BR>
However, it can be read from the z-matrix output above (the output, not the echo of the input) that Molpro evaluates the complex expression correctly. It seems to complain about the complex expression entry, but then evaluates it correctly! I have no idea what could be the source of the error causing the program to abort.<BR>
<BR>
Can anyone offer a suggestion so I can proceed?</FONT>
</P>
</BODY>
</HTML>