You're forgetting that
({1.53}[1][17]).elemno
is an average.
You are using array methods, so add ".all" to those:
print ({1.53}[1][17]).element.all.add("\t").add(({1.53}[1][17]).elemno.all
).add("\t").add(({1.53}[1][17]).x.all).add("\t").add(({1.53}[1][17]).y.all
).add("\t").add(({1.53}[1][17]).z.all)
but it might be simpler to use:
print {1.53}[1][17].label("%[element]\t%[elemno]\t%x\t%y\t%z")
in which case the formatting could be nicer:
print {1.53}[1][17].label("%[element]\t%[elemno]\t%5.3x\t%5.3y\t%5.3z")
or even
print {1.53}[1][17].label("%-3[element]%4.0[elemno]%10.3[xyz]")
Bob
On Wed, Dec 18, 2013 at 10:32 AM, Whitwell, George <[email protected]>wrote:
> when I use a command like:
>
>
>
> print
> ({1.53}[1][17]).element.add("\t").add(({1.53}[1][17]).elemno).add("\t").add(({1.53}[1][17]).x).add("\t").add(({1.53}[1][17]).y).add("\t").add(({1.53}[1][17]).z)
>
>
>
> result:
>
> C 2.4705882 -0.08696627 -0.8534151 1.8308194
> C 2.4705882 -0.08696627 -0.8534151 1.8308194
> C 2.4705882 -0.08696627 -0.8534151 1.8308194
> C 2.4705882 -0.08696627 -0.8534151 1.8308194
> C 2.4705882 -0.08696627 -0.8534151 1.8308194
> H 2.4705882 -0.08696627 -0.8534151 1.8308194
> H 2.4705882 -0.08696627 -0.8534151 1.8308194
> H 2.4705882 -0.08696627 -0.8534151 1.8308194
> H 2.4705882 -0.08696627 -0.8534151 1.8308194
> H 2.4705882 -0.08696627 -0.8534151 1.8308194
> H 2.4705882 -0.08696627 -0.8534151 1.8308194
> H 2.4705882 -0.08696627 -0.8534151 1.8308194
> H 2.4705882 -0.08696627 -0.8534151 1.8308194
> H 2.4705882 -0.08696627 -0.8534151 1.8308194
> H 2.4705882 -0.08696627 -0.8534151 1.8308194
> H 2.4705882 -0.08696627 -0.8534151 1.8308194
> H 2.4705882 -0.08696627 -0.8534151 1.8308194
>
>
>
> the atoms really are different, evidenced by C and H in the output or as
> produced by:
>
> print
> ({1.53}[1]).element.add("\t").add(({1.53}[1]).elemno).add("\t").add(({1.53}[1]).x).add("\t").add(({1.53}[1]).y).add("\t").add(({1.53}[1]).z)
>
>
>
> result:
> C 6 0.5630599 -1.1161811 1.47227
>
>
>
> or:
>
> print data({1.53},"xyz")
>
>
>
> result:
> 17
>
> C 0.56306 -1.11618 1.47227
> C 0.57693 -2.34639 2.38065
> C -0.82581 -0.78767 0.89831
> C 1.22154 0.08281 2.15912
> C -1.84993 -0.20657 1.87432
> H 1.18245 -1.36436 0.61213
> H 1.59096 -2.59017 2.67957
> H 0.16333 -3.21266 1.87410
> H 0.00023 -2.18628 3.28660
> H 1.22370 0.95445 1.51206
> H 2.25210 -0.14288 2.41288
> H 0.71077 0.35029 3.07788
> H -1.23407 -1.69083 0.45199
> H -0.69344 -0.08274 0.08138
> H -2.79985 -0.05883 1.37170
> H -1.53391 0.75503 2.26115
> H -2.02649 -0.86507 2.71782
>
>
>
> I've tried other approaches to producing data with the "symbol, atno, x,
> y, z" format, such as:
>
> modnum = 15
>
> atnum = 17
>
> for (var i=0;i<atnum;i++) {
>
> thisatom = "({1."+@modnum+"}["+@i+"])"
>
> print
> @thisatom.element.add("\t").add(thisatom.elemno).add("\t").add(thisatom.x).add("\t").add(thisatom.y).add("\t").add(thisatom.z)}
>
>
>
> with and w/o @ on thisatom, with no joy; however:
>
>
>
> print thisatom
>
>
>
> in the for loop does return a series of 17 ({1.53}[i]) style atom
> expressions.
>
>
>
> Hoping for new insight,
>
>
>
> George Whitwell
>
> NCWC Chemistry
>
>
> ------------------------------------------------------------------------------
> Rapidly troubleshoot problems before they affect your business. Most IT
> organizations don't have a clear picture of how application performance
> affects their revenue. With AppDynamics, you get 100% visibility into your
> Java,.NET, & PHP application. Start your 15-day FREE TRIAL of AppDynamics
> Pro!
> http://pubads.g.doubleclick.net/gampad/clk?id=84349831&iu=/4140/ostg.clktrk
> _______________________________________________
> Jmol-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/jmol-users
>
>
--
Robert M. Hanson
Larson-Anderson Professor of Chemistry
St. Olaf College
Northfield, MN
http://www.stolaf.edu/people/hansonr
If nature does not answer first what we want,
it is better to take what answer we get.
-- Josiah Willard Gibbs, Lecture XXX, Monday, February 5, 1900
------------------------------------------------------------------------------
Rapidly troubleshoot problems before they affect your business. Most IT
organizations don't have a clear picture of how application performance
affects their revenue. With AppDynamics, you get 100% visibility into your
Java,.NET, & PHP application. Start your 15-day FREE TRIAL of AppDynamics Pro!
http://pubads.g.doubleclick.net/gampad/clk?id=84349831&iu=/4140/ostg.clktrk
_______________________________________________
Jmol-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jmol-users