Can you tell me about the difference between two the following codes?

My code:

\pssavebezier[plotpoints=1000,linecolor=DOrange, arrows=->]{A}%
\psintersect[name=C, showpoints]{A}{B}

the first code ( I will choose it):


the second code (I won't choose it):

\uput[150](!\psGetIsectCenter{C}{A}{1} I-C1.x I-C1.y){1}
\uput[85](!\psGetIsectCenter{C}{A}{2} I-C2.x I-C2.y){2}
\uput[-20](!\psGetIsectCenter{C}{A}{3} I-C3.x I-C3.y){3}
\uput[90](!\psGetIsectCenter{C}{A}{4} I-C4.x I-C4.y){4}

The result of two above codes as the same.

  • \uput[150](C1){1} is like going to US from Europe through the North pole.

  • \uput[150](!\psGetIsectCenter{C}{A}{1} I-C1.x I-C1.y){1} is like going to US from Europe through the South pole.

Both are correct but the former is more compact and the latter is unnecessarily complicated. You need the latter if you want to do some calculation with, for example, the abscissa of an intersection point.

For example, adding 1 to I-C1.x as follows.

\uput[150](!\psGetIsectCenter{C}{A}{1} I-C1.x 1 add I-C1.y){1}
  • "Upvoting" and "accepting" are independent events that are not mutually exclusive. – Money Oriented Programmer Nov 24 '18 at 7:51
  • 1
    Wry smile :-))) – user173875 Nov 24 '18 at 11:20

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy