News for hackers. Stuff that matters.
Re:Type Systems (2004) [pdf] by adamnemecek on Thursday August 31, 2017 @12:29PM (#15141438)
Most mathematics isn't constructive (https://en.m.wikipedia.org/wiki/Constructivism_(mathematics)) so it doesn't really come up I think. E.g. you know how matrices need to have a certain shape to be multiplied? People don't really talk about what happens if they don't.

Physics on the other hand very much has types, the unit to type correspondence is dopetastic.

Re:Type Systems (2004) [pdf] by kruhft on Thursday August 31, 2017 @12:36PM (#15141505)
But what about Russel's type system(s)? Were they just an addition he proposed that never went anywhere, or are they used much like certain programming languages have types and others don't, depending upon the preference of the user? Or are types just 'too hard/restricting' for general mathematics?
Re:Type Systems (2004) [pdf] by danharaj on Thursday August 31, 2017 @12:59PM (#15141749)
Russel and Whitehead's type system never gained significant traction. It's primarily of historical interest. Once mathematicians became convinced that ZF set theory over first order logic was plausibly consistent and expressive enough, such foundational issues became less important to the typical mathematician.

Lately there's been a resurgence in foundations because of what new foundations like Homotopy Type Theory bring to the table. Funny how something as basic as equality can be revisited time and time again for thousands of years!

Re:Type Systems (2004) [pdf] by pmoriarty on Thursday August 31, 2017 @03:13PM (#15142960)
"Once mathematicians became convinced that ZF set theory over first order logic was plausibly consistent and expressive enough, such foundational issues became less important to the typical mathematician."

Was this decision ever explicitly expressed and agreed on by mathematicians at the time, or was it just implicitly adopted?

Re:Type Systems (2004) [pdf] by danharaj on Thursday August 31, 2017 @07:56PM (#15145041)
A bit of both over the years.
Re:Type Systems (2004) [pdf] by AnimalMuppet on Thursday August 31, 2017 @01:31PM (#15142033)
ELI5: Why would constructive math be more typed than non-constructive math?
Re:Type Systems (2004) [pdf] by adamnemecek on Thursday August 31, 2017 @02:05PM (#15142373)
Constructive mathematics is based on intuitionistic logic (i.e. classical logic without law of the excluded middle, meaning you don't have proof by contradiction, to demonstrate the existence of something you have to "construct" it). Intuitionistic logic is very close to type theory.
Re:Type Systems (2004) [pdf] by AnimalMuppet on Thursday August 31, 2017 @03:05PM (#15142874)
OK, ELI10: Why or how is intuitionistic logic very close to type theory? Is it based on type theory? Or is it just similar? In either case, how and why?
Re:Type Systems (2004) [pdf] by rraval on Thursday August 31, 2017 @04:01PM (#15143405)
See https://codewords.recurse.com/issues/one/type-systems-and-lo... for a pretty elaborate response to this question.

tl;dr: types are propositions and values are proofs of those propositions. Constructive logic is not concerned with (true xor false), but rather "I can prove A" or "I can prove not-A". There's also the middle ground of "I don't know how to prove anything about A".

Re:Type Systems (2004) [pdf] by adamnemecek on Thursday August 31, 2017 @03:31PM (#15143153)
Good ol' Curry-Howard isomorphism.

https://en.wikipedia.org/wiki/Curry%E2%80%93Howard_correspon...

But the connections don't really end there.

Re:Type Systems (2004) [pdf] by Retra on Thursday August 31, 2017 @08:58PM (#15145335)
They are models of each other. You can translate statements in one to statements in the other by using some relatively simple rules.
Re:Type Systems (2004) [pdf] by catnaroek on Thursday August 31, 2017 @09:41PM (#15145499)
No particular technical reason.
Re:Type Systems (2004) [pdf] by marcosdumay on Thursday August 31, 2017 @02:02PM (#15142350)
Physicists just love to work on natural unities, where they throw their types and conversion functions out of the window and calculate in a unityped framework.
Re:Type Systems (2004) [pdf] by adrianratnapala on Thursday August 31, 2017 @08:48PM (#15145294)
Checking your units is a basic sanity check that we teach students. But as we advance, physicists throw away that wisdom. Theorists especially have an annoying habit of doing this, because all the repetitions of "c", "hbar" etc "k_B" etc clutter up their equations.

But I preffer to keep that stuff in, even when doing pretty abstract stuff. Essentially because I wanted the type annotations. For example my favorite convention for the Minkowski metric is:

     [c^2  0   0   0]
     [ 0  -1   0   0]  
     [ 0   0  -1   0]
     [ 0   0   0  -1]

That way your vectors are just $(t, x, y, z)$, where $t$ has units of time and the rest of space. Your covectors do come out oddly as $(c^2t, -x, -y, -z)$, but that's what makes them covectors.
Re:Type Systems (2004) [pdf] by catnaroek on Thursday August 31, 2017 @09:40PM (#15145496)
Alternatively, you can work with x^0 = ct instead of x^0 = t.
Re:Type Systems (2004) [pdf] by adrianratnapala on Friday September 01, 2017 @12:01AM (#15146023)
Yes, and and that a much more common convention than the one I favour. They do it partly because it keeps the factors of c out of the visible equations -- but I like my those cs.

Another reason is that people instinctively feel that the elements of the coordinate tuple all have to have the same units. But that's not necessary when you have a metric around. Indeed keeping irregular units is helpful because it prevents you from accidentally forgetting to multiply through by the metric.

Re:Type Systems (2004) [pdf] by catnaroek on Friday September 01, 2017 @08:35AM (#15147822)
The c factor doesn't really go away. It just gets shifted into 4-vectors.