juan_gandhi: (Default)
2020-08-05 09:56 pm
Entry tags:

one of the funniest things I encountered lately

is "theory of objects

One data type. Equational theory with no operations and axioms.

Просто теория штук. Теория множеств ее моделирует, понятное дело.
juan_gandhi: (Default)
2020-07-31 10:37 am

Algebraic Data Types, categorically (a draft)

https://github.com/vpatryshev/wowiki/wiki/Algebraic-Data-Types-Categorically



Critique welcome; it's just a draft. I'll be glad to expand it, to fix it, to polish it. But the idea is there already. I believe, I got the puzzle behind GADT formalized.
juan_gandhi: (Default)
2020-06-03 09:54 pm
Entry tags:

have I forgotten everything?

So, take an algebraic theory; we can build algebras - models of that theory, and a free algebra is a free model (e.g. free monoid); then we can also look at Kleisli category, and there we have a terminal object, and it's supposed to be as easily buildable as free algebras (if they exist).

That kindergarten should be translated back to a proper categorical language. Maybe even better, into toposes, because it's a pretty old story. 
juan_gandhi: (Default)
2019-03-10 08:12 am

a bunch of links

 Geometric Model Theory - hard reading, manifolds, algebraic geometry
Model Theory and Category Theory - high level, but easy reading

Solving the mystery behind Abstract Algorithm’s magical optimizations - here the author implements, in lambda, algorithms with unusually fast performance. Explanations follow (links inside)


A link to the author's github project





juan_gandhi: (Default)
2019-01-21 07:40 pm
Entry tags:

ok, it does not seem to be doable

Basically, I have two, e.g. GraphMorphisms, and I want to compare them. This theory is supposed to be equational, right? Is it?
In short, I could not figure out.

So I decide, let me take a look, how do they compare two typed sets in Scala? Here's how:

  override def equals(that: Any): Boolean = that match {
    case that: GenSet[_] =>
      (this eq that) ||
      (that canEqual this) &&
      (this.size == that.size) &&
      (try this subsetOf that.asInstanceOf[GenSet[A]]
       catch { case ex: ClassCastException => false })
    case _ =>
      false
  }


So there. Maybe it's not equational, after all. I mean, in my case.

How do they do it in Haskell then? This is how:


instance Eq1 Set where
    liftEq eq m n =
        size m == size n && liftEq eq (toList m) (toList n)


Typeclasses seem to beat classes. Fuck...
juan_gandhi: (Default)
2017-08-10 03:02 pm

something to boast about

Yesterday I described the essence of model theory in one tweet. I'm proud of it. 
juan_gandhi: (VP)
2016-11-03 11:42 am

Theory of Objects

on one page

1. Idea

The theory of objects is the logical theory whose models in a category 𝒞 are precisely the objects of 𝒞.

2. Definition

The theory of objects 𝕆 is the theory with no axioms over the signature with a single type and no primitive symbols except equality.


===================

The classifying topos 𝒮[𝕆] for the theory of objects 𝕆, or the object classifier, as it is also called, is the presheaf topos [FinSet,Set] on the opposite category of FinSet.

What motivates the terminology, is that for any topos E, geometric morphisms E→𝒮[𝕆] correspond to objects of E.