HNHacker News
TopNewBestAskShowJobs

adrianratnapala

3,270 karma · joined March 14, 2016

submissionscomments
adrianratnapala··on The Saddest Thing I Know about the Integers
Yep.

Though admittedly it belongs to the category: names I'd have thought were exclusively women's except I heard of just this one dude. My list is:

* Evelyn Waugh

* Vivian Richards

* Marion Barry

adrianratnapala··on Mathematicians Discover the Perfect Way to Multiply
Discrete fourier transforms have always been a way of doing fast polynomial multiplication -- which is also called convolution. That is we can do

     (a0 + a1^z + a2*z^2...) * (b0 + b1^z + b2*z^2...)
As

    fa = DFT([a0, a1, a2...])   # O(N log N)
    fa = DFT([b0, b1, b2...])   # O(N log N)
    fab = element-by-element multiply fa by fb # O(N)
    return InverseDFT(fab) # O(N log N)
Now this is well established if we are literally doing a convolution of two sequences of complex numbers. But this is different from integer quite multiplication because:

1. Polynomial multiplication doesn't have carries.

2. It does inexact arithmetic on complex-numbers, we want exact results on integer digits.

I am guessing (2) is solved by getting modulo-arithmetic do the same algebraic gymnastics that make the FFT work.

Also I didn't think any of this was new -- I vaguely remember reading about fast convolutions using discrete algebras in old textbooks from the '70s. Maybe the hard thing was to do it in a way that leaves enough information left over to do the carries.

adrianratnapala··on Time protection: the missing OS abstraction
> One issue I see here is that time protection would need to extend to anything shared,

We might see this issue as an opportunity. That is, by thinking about a concept called "time protection" we expose all these things subsystems are doing and make them easy to argue about. We can now say "Oh good, XYZ improves best-case speed, but sadly it also compromises time protection".

Having such a language means the industry can slowly start improving these things rather than sweeping them under the rug. It will not stop the improvement from being slow and difficult.

adrianratnapala··on Why Concatenative Programming Matters (2012)
I went through a similar journey a while ago, except I haf a semi-practical result to get at.

I wanted to draw an fairly detailed energy-level diagram for a particular atom and I wanted the it done to scale -- except for certain fudges made for clarity.

The amount of repetitive calculation and not-quite-trivial logic meant it made sense to use a a programming language rather than a "simple" document format. I chose hand-written PostScript mostly for fun.

But PS actually quite a nice language for the task -- no worse than the various Python libraries which would have been my main alternative.

adrianratnapala··on What Is a Manifold?
> Basically, a manifold means something that takes the flow of gases from a one-to-many or a many-to-one.

A perfectly sensible meaning given the construction of the word. There is something about mathematics and linguistics (and to some extent CS) that encourages the creation of confusing, meaningless names like "accusative (case)", "(algebraic) ideal" and "(geometric) manifold".

adrianratnapala··on New human species found in Philippines
> "Merged" conjures an image of living peacefully side by side and interbreeding for many generations.

Even when this did happen[1], the record seems to show trickles of gene-flow from these populations entering a much larger stream of genes from a more recently out-of-Africa population.

[1] And in a big complex world, it certainly would have happened sometimes.

adrianratnapala··on EU Agencies Falsely Report More Than 550 Archive.org URLs as Terrorist Content
As dsfyu404ed@ points out, the UK no longer has good track-record of due process and fundamental-rights compared to the continent.

In 18th and even 19th century, Britain's unwritten constitution and notions of "English liberty" did indeed stand out -- and inspired the American to crystalise the ideas into written constitutions.

But 20th century ideologies, and the modern administrative state have "obsoleted" all that. Needless to say Britain coped with the change better than lots of pre-war countries (Germany!).

But post-war, Europeans have put in place formal human rights protections that a working imperfectly, but better than the British non-constitution. British citizens have their basic rights protected in large part because the UK now shares these formal rules with Europe.

adrianratnapala··on Fast Directory Listing on Linux
> There's lots more optimizations possible with this technique, e.g. counting-sort style bucketing.

:) I was going to say that since you are half re-inventing bucket-sort anyway, why not go the whole hog.

Is the code three-part quicksort simpler and easier to understand than a bucket sort?

adrianratnapala··on All of Toyota’s electric vehicle patents are now royalty-free
Perhaps they believe they have enough of a head-start that they has more to gain from a more or less patent free industry than they have from having patents, but then also having to deal with every ankle-biter who claims to have a relevant patent.
adrianratnapala··on Less Pizza, More Yoga: E-Sports Embraces Traditional Training Methods
I thought chess players have been doing physical fitness training since the '70s.

If so, I suspect that a lot of eSports players have been doing the same for a long time without making the newspaper.

adrianratnapala··on Why GNU grep is fast (2010)
>... but it turns out that a guess works pretty well most of time since most things you search have a similar frequency distribution.)

This kind of thing is an pattern unless the benefit over Boyer-Moore huge.

A small performance gain in the common-case is not worth the pain of introducing pathological cases that only bite you once you are deeply committed.

Presumably this is not too bad for ripgrep itself, as long as it falls back to something sensible when the assumption fails.

adrianratnapala··on Why Is Silicon Valley So Obsessed with the Virtue of Suffering?
The claim is not that Roman ethics was spread through popularity with the rich. The claim is that one particular strand of ethics within Roman culture did so.

That said, I am not sure that Stoicism was particularly rich-friendly, nor that it was necessarily more successful than its competitors.

adrianratnapala··on Dataforge UUCP
Cat pictures?
adrianratnapala··on Fyne: Cross-Platform GUI in Go Based on Material Design
> Instead, what we need is a simple API with opaque handles and C function calls. No fancy OOP or macro preprocessors. Simple OpenGL style.

Something like the enlightenment foundation libraries might be what you want[1]. I haven't tried it out properly, but I liked the look of it from the docs, it's a C api and moderately minimalistic.

However, even with C APIs, all these things end up with something like "fancy OOP" (after all, even Gtk is a C Api). That's because GUI widgets seem to be one of the few places really well suited to OO ideas like inheritance and non-trivial getter-setters.

[1]: https://docs.enlightenment.org/efl/current/

adrianratnapala··on Students don't seem to be getting much out of higher education (2018)
That's his point.

The advantage of getting through the fourth and final year is the signal that it shows you are not one of those who did worse.

adrianratnapala··on Students don't seem to be getting much out of higher education (2018)
> The problem is we do not have enough licensed escalator mechanics to do the work. Money isn't the problem.

So is the problem that there aren't enough mechanics, or not enough licenses?

adrianratnapala··on A world of message-oriented programming languages (2018)
But named-args in Python are also syntactic sugar for passing dictionaries around. Object-unpacking of the the kind described here is another one.
adrianratnapala··on Patreon ups its revenue cut, but grandfathers in old creators
While that's all pretty shocking -- it's really a variation on the same kind of problems we see with patreon et. al. cutting people of. The reactions might not be as harsh yet, because there are fewer regulators and policemen breathing down their necks -- but that will come.
adrianratnapala··on Patreon ups its revenue cut, but grandfathers in old creators
Another way of looking at this this is that society has lost sight of the forest for the trees in its desire to impede criminals.
adrianratnapala··on Patreon ups its revenue cut, but grandfathers in old creators
You are right that they have some network effect, but are also right that it's not zero.

Recently the one "creator" that I funded on the platform moved to allowing direct bank transfers. I was glad to make the change: my bank is a platform that I really am already familiar with, way more than Patreon.

And the creator did not have to belong to the same bank as me.

adrianratnapala··on Firefox 66.0 Aims to Reduce Online Annoyances
`ssh -X` generally disagrees with you.
adrianratnapala··on Firefox 66.0 Aims to Reduce Online Annoyances
> Latency matters because of all of those round-trip requests.

Well then, since it's a physical impossibility to do away with them, we'd better start working on improving the speed of light.

adrianratnapala··on Firefox 66.0 Aims to Reduce Online Annoyances
Everything that is standard recommended practice in modern web design is Very Bad From, whether or not it is sloth.
adrianratnapala··on Firefox 66.0 Aims to Reduce Online Annoyances
I have about 30 open on my phone.
adrianratnapala··on Barcelona Fines Landlords Who Let Buildings Sit Empty
So all the landlords in Bercelona conspired to do this somehow?
adrianratnapala··on The rise and fall of scientific authority, and how to bring it back
Point #3 is actually a sign of increasing authoritarianism.

You can make an argument that as older forms of authority (family, church) have weakened, we have been placed at the mercy of the remaining forms (governments, employers). But in this mixed picture how do we know whether science goes in the winners or losers column?

adrianratnapala··on The rise and fall of scientific authority, and how to bring it back
> The victors of WW2 were countries that invested heavily in science and technology

So were the losers. But you are right, both sides were forced to concentrate on developing new technologies by the mutual struggle. The more capable side won.

adrianratnapala··on Atlas observes light scattering off light
Those rays are unlikely to be photons, so EM-self interaction is not likely to stop them. The articles linked in this sub-thread all speculate/assume that the cosmic rays were protons.
adrianratnapala··on Facebook, Axios and NBC Paid to Whitewash Wikipedia Pages
And Wikipedia makes it relatively easy to do tricks like compare the different language versions.
adrianratnapala··on Facebook, Axios and NBC Paid to Whitewash Wikipedia Pages
Sadly, there is no substitute for careful reading. History books will always be subtly representing the historians biases, even as the present a lot of detailed facts.

The Wikipedia is no different. But it still allows the interested-amateur to do a breadth-first study of a topic without drilling down into a whole book. In both cases, the reader can't assume that she has seen an unbiased (whatever that means) story. But she can glean enough facts to be less ignorant about the topic than before.

← PreviousPage 3 of 34Next →