[Getdp] $X and X[]

Michael Grant m.grant at ee.wits.ac.za
Tue Jul 12 19:54:38 CEST 2011


Hi folks,

I was just wondering what the difference is between $X and X[] (Y, and Z also)?

I see that $X is the current x co-ordinate, and $XS is the source x
co-ordinate.  X[] is just described as the x co-ordinate.

If I set up a perfectly symmetrical problem, then $X works fine... I'm
evaluating prob[] = exp(-1*( ($X - X0)^2 + ($Y - Y0)^2)) and integrating
within an area.  So in this case, if I set X0 = +- 1; Y0 = +- 1 , and
integrate within a unit square centred at the origin then all is well.

However as soon as any asymmetry is introduced it all goes to pot.  There is
no such problem with X[].

What's the difference between the variables?

Kind regards,

Mike Grant.
<html><p><font face = "verdana" size = "0.8" color = "navy">This communication is intended for the addressee only. It is confidential. If you have received this communication in error, please notify us immediately and destroy the original message. You may not copy or disseminate this communication without the permission of the University. Only authorized signatories are competent to enter into agreements on behalf of the University and recipients are thus advised that the content of this message may not be legally binding on the University and may contain the personal views and opinions of the author, which are not necessarily the views and opinions of The University of the Witwatersrand, Johannesburg. All agreements between the University and outsiders are subject to South African Law unless the University agrees in writing to the contrary.</font></p></html>