Compiling the following MWE:



\draw[help lines] (0,0) grid[step=0.25] (1,1);
\draw[very thick,red!85!black] 
to[curve through={(0.15,0.35) .. 
                  (0.5,0.5)   .. 

with TikZ version 3.0.0 gives:

enter image description here

The same MWE, with TikZ 2.10 leads to something more expected:

enter image description here

Why this difference?

  • 1
    Since TikZ 3.0 is not generally available, this question is on the verge of being off topic. It's quite clear that version 3 broke the working of hobby. :( – egreg Jan 17 '14 at 16:36
  • From the in and out angles, I think ThreekZ has an additional angle setting after hobby computes the angles. Can you try with explicit angles for in and out? And use units just to be safe in the troubleshooting :P – percusse Jan 17 '14 at 16:41
  • @egreg: perhaps the why is too generic. Two ideas came in my mind (one concerning the parser, the second one about computations), but they could be completely wrong. Hence, behind the why there's also an implicit where besides a hopefully how to solve it. Indeed according to where are the causes, they may affect or not other packages. However, I think the question is on topic; for two reasons: according to this thread the new version should have been already on CTAN. [next] – Claudio Fiandrino Jan 17 '14 at 18:16
  • Second, we had in the past some questions on packages not generally available (pgfpie for example). – Claudio Fiandrino Jan 17 '14 at 18:17
  • @ClaudioFiandrino I didn't know that and heard instead that a couple of months were expected. I didn't vote for closing either, it was a way for asking you to improve the question. – egreg Jan 17 '14 at 18:19

Works for me:

Hobby with TikZ3.0

A major change from TikZ2.10 to TikZ3.0 is that they've reimplemented the atan2 function correctly. In old TikZ, the arguments were the wrong way around. Putting the arguments in incorrectly leads to the behaviour that you see.

The version of hobby on TeX-SX launchpad fixes this in two ways:

  1. The core hobby algorithm now uses the version of atan2 from l3fp.
  2. The quick algorithm (which is implemented in PGF) uses PGF's atan2 but includes a test to see which version of the atan2 function is present and chooses its arguments accordingly.

(I'm pretty sure that this change was in response to a question on this site but I can't find it now.)

Now that TikZ3.0 is released, I should push this change to CTAN. But I need to update the documentation and do a bit more testing first.

  • 1
    Great!! Thank you very much for your efforts. – Claudio Fiandrino Jan 18 '14 at 13:46
  • 2
    I've just uploaded this version to CTAN. Should propagate through in a day or so. – Andrew Stacey Jan 20 '14 at 13:50

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.