Mathf.TAU should be included

Hi all,

There is this number that is the olde brother of PI, called TAU.
TAU is exactly equal to 2PI.

Although not nearly as popular, there are arguments that it should be brought forward and used more than PI, given the amount of formulas that use 2PI moreso than PI alone.

(Although outside the scope of the forum, there would be didactical advantages to teach trigonometry using TAU rather than PI, for a greater clarity of concepts. )

It would be a relatively simple matter to add TAU as a constant to projects, but as a matter of convenience, ubiquity, and as a core mathematical value, it should be made available in Mathf, just like PI.

Mathf.TAU

It could also save newbies that don’t create a TAU const from a multiplication 2 * PI , which may improve a little bit of performance.

I agree it should be included for consistency, but unless there is usage of it all over the program very very regularly, even not doing a const causes very little perf issues.

I dont really think anybody is going to benefit or lose out greatly because of this…

This, join the TAU army

To be honest, I never heard before about tau as 2*pi. There are lots of values which are useful. As well as 180, 360, 90 degrees, which corresponding to PI, 2PI, 1/2PI. Then we have angle vectors for each axis. And similar quaternions.

There is just so many potentially nice constants, we all could find useful.

While I am not against TAU, or whatever symbol it represents, there is plenty other potential useful constants.
However not everyone need them. But for my own purpose, I simply create own constants. Creating PI2 constant is trivial for example. Or if you like call it TAU. I don’t think TAU is intuitive for any average Joe.

And epsilon, abs, acos, asin, atan, cos, log, sign, sin, and tan are?

Tau’s pretty standard in the level of math you need to approach any of those.

You describe from the point of purely mathematical symbolic. My point, is very easy to achieve same result, with existing components. I never called 2PI a Tau, as with my background, Tau has completely different meaning.
While cross disciplinary PI is always PI.

Tau advantage is that it makes you understand the practical definition of pi, as in it’s half a circle, now you rewrite equation and replace all pi by tau then all tau by circle, and they make so much more sense intuitively …

Also much easier to explain, and much easier to get people why they don’t need degree and stay in radian, and much more easy to realize why there is a pi in a given equation … I felt so dumb when I realize that, like all my life was a lie…

1 Like

Even if it’s easy to achieve the same results, the fact that it isn’t in the default mathf library means something is wrong.

I agree that Tau is so common in geometry that it should certainly be a constant.

When I went to school I learned all of the things in your first sentence, and never heard of Tau. It was always 2Pi. According to Wikipedia it was only suggested to adopt Tau as the standard in 2001.

And unless there’s some kind of shenanigans going on with it’s wikipedia article, it hardly seems to be in standard use:

… and …

I mean, it seems like an improvement, and its presence is going to change precisely nothing for people who don’t want to use it, so I’ve no argument at all about including it. I’m just not at all convinced by the pretense that it should be included based on already being common. :wink:

It’s been called tau since I was in highschool in the 90s.

I forgot that the whole world went to your high school.

The world is a big place. :wink:

1 Like

the world is a big enough place that the OP also had this issue

You say tomato I say

potato :smile:

That sounds rational . . . wait is it irrational?

1 Like

Sound transcendental to me,

You mean 2potato, right?

1 Like

Seems pointless, since there’s rarely a reason to use even Math.PI. Built-ins, mostly in Quaternion, are easier.

I’m never talking to you about pi again!

It’ll go on forever.

1 Like

Just go ahead and create the constants that you want. There isn’t really a need to add every single constant that might be useful to the Mathf class. I’d prefer not to have my autocomplete polluted by duplication and obscure constants.

There are just as many that use 1/2 Pi, 4/3 Pi and a whole bunch of other fractions of Pi. Would you like them added as well?

Its not really a core mathematical value though. Pi is the generally accepted method for representing the ratio of the circumference of a circle to its diameter. Tau has never really caught on in mathematical or scientific circles. For me, this is the first time I’ve even heard of it. And I’ve spent a lot of time in mathematical and scientific contexts. (Obligatory “games are just my hobby, in real life I’m a chemical engineer”).

The only real contexts where Tau seems to be used are in a few programming languages, and in early education. Early education is notorious for trying to simplify things and make it “easier” at the primary/high school level, at the cost of complicating education later on.

You are kidding me, right? This is such a minuscule performance increase as to be completely irrelevant to your argument. If a single multiplication is killing your performance, you have other problems.

Also I can’t help but think that the implementation if it does get added will simply be:

public static float tau {
    get {
        return 2 * PI;
    }
}
3 Likes

Which is why I specifically said I had nothing against including it. :wink: