Comments on Liens vers quelques fils Twitter

Ruxor (2022-04-15T16:56:04Z)

@jonas: I agree with what you say if the labels were compared lexicographically by letting 0 < (nothing) < 1 (so, up to length 2: 00 < 0 < 01 < (empty string) < 10 < 1 < 11). But the standard lexicographic order is asymmetrically balanced: we have (empty string) < 0 < 00 < 01 < 1 < 10 < 11. I think this means that we need to avoid giving short strings away too readily: you can't insert anything before the empty string (or even, if you forbid the empty string, before 0).

That being said, in the case of binary, there's a simple change that gives reasonable labels: simply add ‘1’ at the end of everything, i.e., take the shortest 1-terminated label that's at the correct place. This is equivalent to labeling the binary tree with the path from the root and a ‘1’ at the end.

But if the digits are {0,…,9}, say, it's less clear what should be done: terminate everything with a ‘5’? (It's even less clear if the “digits” are are arbitrary natural numbers, separated by hyphens, say. But then even the question is unclear because obviously you could start with a gazillion and then pretty much always use a single “digit”.)

jonas (2022-04-15T12:37:52Z)

Re <URL: https://twitter.com/gro_tsen/status/1512411668965466114 > labeling items with strings if you get them incrementally and the labels have to be in a given order.

If you get the items in a random order, then there's a simple method. Label each object with the shortest 0-1 string that keeps the order. There will always be exactly one such string. You find this by looking up the neighboring elements in the order, one of which will necessarily be a prefix of the other, then append a 0 or 1 to the end of the longer label depending on whether the longer one corresponds to an item that's greater than or less than your newly inserted item. This is equivalent to building a binary search tree and labeling the items with the path in that tree from its root to the node with that item, 0 meaning go to the left child and 1 meaning go to the right child. TAOCP 6.2.2 gives detailed information on the average length of the labels, which is 2*log(n) for n items if you average over both the nodes and the possible permutations the items can be given to you. This is clearly the best you can do for the average length of labels up to a constant factor, but I don't know if it's the best for the maximum length among the items averaged over the permutations.

I conjecture that even if you get the items in an adversarial order, you can follow some clever randomized strategy that will give you all short labels in average, at least if you know the number of items in advance.

Ruxor (2021-08-19T22:12:39Z)

@Ilia: C'est une bonne question, je me la suis aussi posée, et je n'ai pas de réponse ; mais quelques éléments de réponse quand même :

‣ Il faut se rappeler que le diagramme (x,y) n'a pas de métrique naturelle (c'est plus ou moins juste un plan projectif réel ; on a pris l'espace tridimensionnel des sensations lumineuses, on l'a projectivisé et on a mis des coordonnées assez arbitraires dessus). Je me suis beaucoup demandé si on pouvait inventer quelque chose d'au moins un peu naturel (par exemple en faisant des trois cônes les sommets d'un triangle équilatéral et en mettant le blanc au centre ?), mais en tout état de cause, (x,y) sont assez arbitraires, et le fait que tel bout semble « loin » ne signifie sans doute rien. Je ne suis pas sûr que ces teintes turquoise manquantes soient tellement « grandes » en un sens pertinent. (Mais c'est vrai que toutes les photos qu'on montre des turquoises des mers tropicales doivent manquer de saturation.)

‣ Si on ne permet que 256 niveaux de chaque photophore, alors ce qu'on gagne en étendue on perd en précision. La sensibilité à la variation de couleur semble (je n'ai pas de version précise de cette affirmation à fournir, mais peut-être que l'espace CIE-Lab en fournit une) se structurer autour d'axes rouge-vert et jaune-bleu, donc peut-être que le choix d'un vert pas trop « turquoise » permet un rendu plus précis des couleurs qui sont dans l'espace effectivement réalisable.

‣ Je crois me souvenir qu'un fabricant de pellicules argentiques (Kodak ?), avant que celles-ci ne disparaissent presque totalement, avait fait une pub sur le fait d'introduire une quatrième couleur, justement pour les teintes turquoise. Il doit être possible de retrouver de quoi il s'agissait au juste, et comment ça a été reçu. En tout cas je suis certain que l'idée a été tentée.

Ilia (2021-08-19T11:14:54Z)

Une question que je me pose par rapport à la vision des couleurs (cf. http://www.madore.org/~david/misc/color/ . Je me permets de la poser ici, faute de meilleur endroit ; la logique est que tu viens d'en parler sur Twitter, mais je n'ai pas de compte Twitter…) :

On constate que le triangle RGB est pas mal plus petit que l'espace complet de toutes les couleurs visibles (en forme de fer à cheval) : c'est surtout le sommet "vert" qui est assez éloigné de la "vraie" pointe du fer à cheval (qui correspondrait à une lumière spectrale pure de 515nm environ). Bien sûr il existe en réalité plein d'espaces RGB différents, mais ils semblent à peu près tous souffrir de ce défaut (cf. https://en.wikipedia.org/wiki/RGB_color_space#/media/File:CIE1931xy_gamut_comparison.svg ). La grande question, donc, c'est : POURQUOI ?

Plus précisément :
- Y a-t-il des limitations techniques qui font que c'est difficile de produire une couleur proche du sommet du fer à cheval ? Si oui, lesquelles : qu'est-ce que la longueur d'onde de 515nm a de spécialement difficile à produire ?
- Le cas échéant, ce problème est-il toujours d'actualité ? Concerne-t-il autant les tubes cathodiques, les cristaux liquides et les LED ? D'ailleurs, à quoi ressemblent les spectres des couleurs effectivement affichées par ces différents types d'écran ? (Je suppose que, quand bien même on aurait réussi à résoudre le problème technique, il reste un gros problème de rétrocompatibilité : que faire de l'énorme patrimoine de médias basés sur ces espaces RGB incomplets ?)
- Il y a peut-être aussi une explication psycho-physiologique : si ça se trouve, ce n'est pas un si gros défaut que ça. Des gens ont-ils déjà essayé des écrans capables d'afficher ces couleurs ? Si oui, à quel point ont-ils trouvé la différence frappante ?

Ilia (2021-02-08T21:25:18Z)

> https://twitter.com/gro_tsen/status/1356604468989734914

"Une bizarrerie de la conjugaison française: à la 3e p. singulier du subjonctif présent, la conjugaison de TOUS les verbes se termine par -e («qu'il mange», «qu'il finisse», «qu'il voie», «qu'il prenne», «qu'il aille»…) SAUF DEUX: être («qu'il soit») et avoir («qu'il ait»)."

Pour continuer dans la même idée, "être" et "avoir" sont aussi les seuls verbes où 1pl et 2pl du subjonctif présent ne prennent pas de "i" : "que nous ayons", "que nous soyons" ; "que vous ayez", "que vous soyez". (Comparer : "que nous voyions", "que nous essayions", "que nous criions".)

Mais bon, là, au moins, il y a une vague logique : ce "i" purement orthographique sert normalement à distinguer l'indicatif présent du subjonctif et de l'imparfait ; et "être" et "avoir" sont les seuls verbes dont le radical (pour les formes concernées) finit par "i" ou "y" pour lesquels cette homophonie n'existe pas.

jonas (2020-10-09T00:12:05Z)

Re <URL: https://twitter.com/gro_tsen/status/1313855722984222727 > a unit prefix for 10^0. Some mathematicians sometimes use ε for the multiplicative unit. Even you, who generally use well thought out notations, use it in your 2017 lecture notes <URL: http://perso.enst.fr/~madore/inf105/notes-inf105.pdf >. I think you now have to eat your cake and use ε for the prefix.

Ruxor (2020-10-04T18:38:11Z)

@jonas: In this case, the page <URL: https://www.ixsystems.com/community/resources/list-of-known-smr-drives.141/ > will probably interest you as well: sadly, it seems that Western Digital's WD40EZAZ are SMR, unlike the WD40EZRZ (for some reason I was lucky and I received the second, but I'm not sure I could have known when ordering!).

jonas (2020-10-04T04:08:20Z)

Re <URL: https://twitter.com/gro_tsen/status/1311247085405196294 >: thank you for the link. When I bought four 4TB hard disks for my new computer, with the intention that two will be internal for daily use and two external for backups, alternating so one is always off-site, I knew the risk that some hard disk models are shingled but the manufacturers don't admit this. I bought three different models of hard disks, from the three manufacturers, not really because of the shingled issue, but to avoid all hard disks having the same hidden problem. Now I know that of the four hard disks, the Seagate Barracuda ST4000DM004 is definitely shingled, the two cheap Toshiba HDWD240UZSVA P300 are definitely shingled, and Western Digital WD40EZAZ is either not shingled or WD just haven't admitted it yet. This state of affairs is sad because system administrators could make much better choices if they knew how the hard disks work, eg. in my case shingled hard disks would work well for the external backup drives; and operating systems could optimize the use of shingled drives better than the firmware that keeps everything secret can.

jonas (2020-09-08T12:36:38Z)

Re <URL: https://twitter.com/gro_tsen/status/1302599590944870400 > on non-breaking spaces. I believe that CharlotteBuff's reply <URL: https://twitter.com/CharlotteBuff/status/1302600064305631239 > is correct. The relevant reference documentation is <URL: https://www.unicode.org/reports/tr14/tr14-45.html >, it's quite complicated and I don't understand most of it.

jonas (2020-08-28T01:59:31Z)

Re <URL: https://twitter.com/gro_tsen/status/1293490063918202880 > “What killed MathML”, my opinion differs. What killed MathML is that it was designed without a backwards compatible upgrade path. There's no reasonable way to put both MathML and fallback HTML into the same webpage such that MathML-capable browser would display the MathML, whereas other browsers display the HMTL. As a consequence, no webpage author wants to start using MathML, because then the majority viewing their page with an old browser will get a worse experience than if they don't use MathML, and no browser maintainer wants to add MathML, because too few webpages are using it.

jonas (2020-02-19T15:42:58Z)

Re <URL: https://twitter.com/gro_tsen/status/1229804567375831047 > pixel coordinates. I generally prefer convention (C), which puts the boundaries between pixels to nice grid points. I have met both software libraries that use (C) (eg. cairo) and ones that use (A). I've seen (B) used in only one case. You want to describe a 3D scene in software, and you want to define the color (or any other property that is a function of the location) of a surface using a raster image. In that case, it is important to be able to control the color at the very edges of the surface.

Re <URL: https://twitter.com/gro_tsen/status/1229460023312551936 >: finally a question I'm competent in. Please ask more such questions. I admit this one did turn out quite difficult. Try the following command.

convert input.png -background transparent -fill "#880000" -font "Helvetica-Bold" -pointsize 24 \( label:ORIGIN +distort affine "%[fx:w/2],%[fx:h/2] 0,0" \) \( label:MARK +distort affine "%[fx:w/2],%[fx:h/2] 400,100" \) -layers flatten output.png

This writes "ORIGIN" centered on the point (0,0), and "MARK" centered on the point (400,100). The output will be cropped the same as the input image, so you will see only a quarter of the "ORIGIN" label in the output – I used this as an example to show you that the text is centered. The captions are centered based on their bounding box, which would give you ugly results if you wrote several captions in lowercase letters and tried to align them. Normally you could use the -repage operator to shift the captions to a given position, but that would make it difficult to center the texts, which is why I use +distort. I tested the above with ImageMagick 6; it may work with ImageMagick 7 but I can't guarantee.

jonas (2020-01-06T12:28:46Z)

Re your Star Wars question <URL: https://twitter.com/gro_tsen/status/1213156032240902144 >. For how we learned the name "Palpatine" out of universe, see <URL: https://scifi.stackexchange.com/q/71843/ > that question on Sci Fi Stack Exchange.

jonas (2019-11-21T23:11:40Z)

Re <URL: https://twitter.com/gro_tsen/status/1196502777763188736 >. The lang attributes in HTML are useful for few things other than quotation marks.

(1) They decide whether italic cyrillic letters should appear as of they are Serbian or Russian letters, since they're encoded as the same one cyrillic script in Unicode. Testcase: <i lang="ru">т</i> <i lang="sr">т</i>. Similarly, certain kanji characters should look different in Japanese, simplified Chinese, and traditional Chinese, and the lang attribute can decide how to render them.

(2) They decide to uppercase "i" the Turkish way. Testcase: <span style="text-transform: uppercase" lang="en">i</span> <span style="text-transform: uppercase" lang="tr">i</span>. There are a few more related language dependencies mentioned at <URL: https://developer.mozilla.org/en-US/docs/Web/CSS/text-transform >.

jonas (2019-09-19T19:28:19Z)

In <URL: https://twitter.com/gro_tsen/status/1174392654660067328 >, you ask about the altitudes of a spherical or hyperbolic triangle. You say in later tweets that the three altitudes intersect (possibly in the projective plane only). Let me add an alternate proof though.

Consider a triangle ABC on the hyperbolic plane. The Reiman book [1] gives the following proof that its three altitudes intersect in the projective extension. Take such a Caley-Klein model of this plane where the fundamental conic is a circle and the center of the circle maps to A. If a line is incident to A, then the same lines are orthogonal to it in the model as in the hyperbolic plane. Thus the three altitudes of the triangle ABC in the model map to altitudes in the hyperbolic triangle. You already know that the altitudes of a Euclidean triangle intersect, thus the altitudes of a hyperbolic triangle intersect too.

[1]: Reiman István, ''A geometria és határterületei''. (1986) Gondolat, Budapest. The extended edition ''Geometria és határterületei'', (1999), Szalay, Kisújszállás is more available.

jonas (2019-09-13T18:21:10Z)

Re <URL: https://twitter.com/gro_tsen/status/1172139013400084480 >, Szathmári Sándor's novel <i>Kazohinia</i> is somewhat similar to that idea. The novel is available in Hungarian, Esperanto, and English; and either the Esperanto version is a translation from Hungarian by the author, or both the Hungarian and Esperanto versions are original.

Let me summarize the relevant parts of the story. The protagonist Gulliver arrives to an undiscovered island called Kazohinia. The society of humans on the island is strange in a way that I will not describe here. The island has an autonomous enclave (reservation), populated by humans who are deemed as permanently unfit to the majority society. Gulliver visits this enclave in the middle section of the book. The enclave has its own society very different from that of the rest of the island. Its habits match some of what you are asking for. People, including children, eat in enclosed spaces where nobody else can see them. They talk about food in euphemisms, and they do not like to admit that eating is an essential requirement of life. If it is found out that a person has fed another and they aren't spouses, then they will be identified as low status as if they were a prostitute and a client for a prostitute. People often urinate in public view. The book does not mention sex anywhere, because the protagonist is married in his homeland so it doesn't come up, so we never learn the people's attitudes about it.

jonas (2019-09-06T11:24:52Z)

Re <URL: https://twitter.com/gro_tsen/status/1169753912695492608 > migrating phone numbers from one mobile phone to the other. Yes, I also noticed that every phone uses subtly different formats for the address book. I tell about my experiences with converting them at <URL: https://www.perlmonks.com/?node_id=1225327 >.

jonas (2019-08-29T21:20:09Z)

<URL: https://twitter.com/gro_tsen/status/1097145127791939587 > recommends the book Jürgen Richter-Gebert, "Perspectives on Projective Geometry", Springer (2011). I've since bought a copy of this book, and I'm very satisfied it. I learned a lot from it. It is on the bookshelf close to my desk, next to the other three geometry reference books that I own.

alcidenikopol (2019-08-22T18:18:31Z)

Concernant la théorie homotopique des types, Vladimir Voevodsky soutient dans cette conférence que l'entreprise du groupe Bourbaki, très remarquable et intéressante à ses débuts - du fait du sérieux et du talent de ses membres - s'est toutefois quelque peu enlisée à moment donné. Et il lui semble que cela s'explique en grande partie par l'insuffisance de la théorie des ensembles (ZFC, plus particulièrement) sur laquelle elle s'appuie.

C'est pour dépasser ce problème qu'il s'est intéressé à d'autres fondations possibles des maths, en premier lieu à la théorie des catégories (il estime avoir fait un grand progrès en comprenant que les catégories ne sont pas, à l'en croire, des "ensembles en dimension supérieure", comme c'est généralement soutenu, mais plus exactement des "ensembles partiellement ordonnés en dimension supérieure", les simples "ensembles en dimension supérieure" étant plutôt les groupoïdes, dans le même ordre d'idées). Quoi qu'il en soit, la théorie homotopique des types (avec axiome d'univalence) se présente comme un système fondationnel complet - à l'instar de ZFC, de ce point de vue - contrairement à la théorie des catégories (trop peu ambitieuse, faut-il comprendre).

Bon, n'étant moi même qu'un profane, je serais bien incapable de savoir si cet élément (glané parmi diverses vidéos de vulgarisation) peut faire évoluer le débat entre personnes éclairées, mais, à toutes fins utiles, "je pose ça là", comme on dit maintenant. :-)

https://www.youtube.com/watch?v=E9RiR9AcXeE

JML (2019-08-21T08:49:18Z)

Concernant le médicament au durian, il faut voir qu'il y a des variations individuelles d'origine génétique (plus tout ce qui se rajoute par-dessus) dans la perception des odeurs (et du “goût” donc).
Quand j'étais petit on me faisait avaler un médicament (antibiotique ?) au goût d'orange vomie. Il paraît clair que je devais être un des rares enfants à percevoir l'arôme d'orange utilisé comme ayant un très net arrière-goût de vomi…

Qu'est-ce que ça t'apporte de twitter sur twitter plutôt que sur ton blog ? (à part que tu ne supportes pas un message de blog de 3 lignes.) As-tu plus d'audience, de réponses ?

Vicnent (2019-08-19T15:32:50Z)

@Ruxor : oui, là dessus, je te rejoins complétement, il manque clairement un outil de tri qui pourrait également représenter les branches de commentaires du fil initial voire même des commentaires eux mêmes…

Ruxor (2019-08-19T12:29:13Z)

@Vicnent: Le problème c'est surtout que des bouts intéressants du fil peuvent être cachés dans les réponses d'autres personnes (et les réponses à ces réponses), c'est surtout ça que je reproche à Twitter de ne pas montrer de façon intelligente, et si le threader est utile pour compiler en une seule page toute une série de tweets d'une seule personne, il n'a pas de fonction pour rassembler aussi les réponses d'autres personnes (ce qui demande forcément une sélection manuelle, ou, au moins, manuellement assistée).

Vicnent (2019-08-19T12:12:14Z)

tu peux aussi ajouter à la fin du thread un tweet avec le texte exact de la ligne suivante :
@threader_app compile
ce qui va déclencher un process de compilation

Exemple sur ce thread de à propos de NP <URL:https://twitter.com/gro_tsen/status/1158451493801988107 />
qui va donc donner <URL:https://threader.app/thread/1158451493801988107 />
le thread est numéroté via le n° du tweet par ailleurs ;
J'imagine que tu n'es pas fan de laisser les objets ainsi déportés sans maitrise mais tu devrais pouvoir bidouiller rapidement un petit CRON qui va regarder parmi tes derniers tweets, ceux qui sont liés entre eux par au moins une série de 4 par exemple. Et ensuite, tu peux faire un petit encart automatique qui renvoie vers l'index de ces thread, chez toi ou sur tweeter si les gens veulent commenter / ajouter / etc…


You can post a comment using the following fields:
Name or nick (mandatory):
Web site URL (optional):
Email address (optional, will not appear):
Identifier phrase (optional, see below):
Attempt to remember the values above?
The comment itself (mandatory):

Optional message for moderator (hidden to others):

Spam protection: please enter below the following signs in reverse order: 5f2679


Recent comments