Readit News logoReadit News
viewfromafar commented on How not to teach recursion (2021)   parentheticallyspeaking.o... · Posted by u/tosh
edflsafoiewq · 4 years ago
> (not always)

Doesn't this work: consider the call graph of all possible argument lists (with an edge A->B if f(A) calls f(B)). If the function terminates, there are no cycles, so this is a DAG, which puts a partial order on the set of argument lists which strictly decreases with each call.

viewfromafar · 4 years ago
(I need sleep, Ackermann is actually very easy to show as decreasing using lexicographic order).

Yeah, if you know that the recursive function always terminates, then you know that each recursive call makes the set of remaining steps strictly smaller.

When you want to prove termination, then it is exactly what you need to show (that the remaining work does get smaller, no cycles).

viewfromafar commented on How not to teach recursion (2021)   parentheticallyspeaking.o... · Posted by u/tosh
markisus · 4 years ago
What does smaller caller mean in this case?
viewfromafar · 4 years ago
This probably is supposed to hint at a termination order. If a call to a recursive function terminates, then it it often (not always) possible to identify an ordering relation among the arguments of the call and the argument of the recursive call(s) within.

Though, there is also the Ackermann function... so for some recursive functions it is not be as easily seen why they would terminate.

viewfromafar commented on Java record pattern matching in JDK 19   openjdk.java.net/jeps/405... · Posted by u/SemanticStrengh
SemanticStrengh · 4 years ago
Don't be mistaken, Typescript do not has proper pattern matching support, The proposal is far from being adopted https://github.com/tc39/proposal-pattern-matching

> Related, Typescript is the only language I know of that through flow analysis does not require you to redefine the variable. E.g. you can do something like

This is called smart casting and is widely used in Kotlin

viewfromafar · 4 years ago
The PL crowd calls that type system feature "occurrence typing."
viewfromafar commented on The λ-Cube   en.wikiversity.org/wiki/F... · Posted by u/todsacerdoti
neilkakkar · 4 years ago
Asking because I see something that's a lot of mappings with zero context: Why/ for what is the Lambda-Cube useful?
viewfromafar · 4 years ago
Type theories are formal logic languages. People use formal logic for all sorts of things but mathematics has the longest history. This is where people first defined formal languages and assigned meaning (mathematical meaning.)

Starting from simply typed lambda calculus ("simple type theory", also "higher order logic"), one can make various extensions that make the logic language more expressive. The lambda cube is a way to systematically organize the space of type theories.

Interestingly, the theory has become very relevant for type systems of normal programming languages. Milner invented ML as "meta language" for helping with logic and theorem proving, but it was used widely and today everyone expects generics to work more or less as in System F polymorphic lambda calculus.

viewfromafar commented on The λ-Cube   en.wikiversity.org/wiki/F... · Posted by u/todsacerdoti
viewfromafar · 4 years ago
For anyone who wants to dive deeper, this a good series of short video lectures pulled together by students of TU Berlin that introduces this topic: https://youtube.com/playlist?list=PLNwzBl6BGLwOKBFVbvp-GFjAA...
viewfromafar commented on My First Impressions of Web3   moxie.org/2022/01/07/web3... · Posted by u/natdempk
Uptrenda · 4 years ago
Thin clients that verify transactions are possible though. For something like Bitcoin you have SPV-proofs that prove chains of headers. You can prove that a transaction was included in the longest chain without having to run a node yourself just by checking proof-of-work merkle trees; Even if the vast majority of users end up running clients that don't verify the whole chain -- cryptographic trust would still be ensured by checking headers. This requires no centralization.

Satoshi wrote about this architecture early on in scaling the blockchain. Ethereum also allows light clients and I think it even has checkpoints that make downloading headers faster. Cryptographic protocols that verify smart contract results could be included in Metamask. I feel like not mentioning this in the essay shows a lack of familiarity with the literature even if he was extremely opened minded (enough to create dapps himself.)

He did make valid observations about third-party trust: OpenSeas and Infura. But in both cases: these protocols can be implemented without centralized architecture. A decentralized alternative to Infura (that provides reliable results to users and easy-to-check attestations) is possible to build. One should also note that in blockchain land the lack of incentives to run a full node is a problem people are working to address. It's actually a perfect illustration of how the blockchain can lead to emergent systems. Some ledgers already have rewards for running full nodes. So yes -- people do want to run full nodes -- they just want to be paid for it.

viewfromafar · 4 years ago
I understand the criticism to be targeted at the "web3" idea, which is assumed to be about the infrastructure for decentralized applications. What is possible to implement is less relevant than what is likely to get implemented: here the clients (read: the app on the mobile) and their means of accessing the decentralized goodness matters. The argument as I understand it is: if access/usage to whatever decentralized goods is always mediated by the old centralized approach (you have to ask the server whether the transaction is valid) then you trust the operators of the servers and those folks have the option of making "everything" (access to those services/goods) faster & better. It is like the "last mile" problem where a company may well operate a global network but have no setup to act as ISP for end consumers, which is left to mediator. This is compatible with "web2" (https vpns etc) but the "web3" answer seems to be missing.

The problem is that benefits of well-thought out incentive systems evaporate when access is mediated. If every dapp comes with its own mobile client and app-specific servers to address this, there is nothing decentralized about it.

viewfromafar commented on SciRate: An open source website to browse, save, and comment ArXiv articles   scirate.com/... · Posted by u/physicsgraph
viewfromafar · 4 years ago
If this is to appeal to a community, there has to be some kind of incentive for that community to add their comments (content) to this site. What is it? Reputation?

In general, it could be appealing to have an open, established process for gathering public feedback on articles. It seems a scientific community would rather have their own version set up, where they could also curate content (rather than browse by category).

viewfromafar commented on The business of extracting knowledge from academic publications   markusstrasser.org/extrac... · Posted by u/kevin_hu
Al-Khwarizmi · 4 years ago
I can't speak for biomedicine, but speaking as an academic in CS the claim that "close to nothing of what makes science actually work is published as text on the web" looks like a huge hyperbole to me.

It's true that the so-called "folk knowledge", knowledge that exists in the community but no one bothers to publish in the form of papers, is a real problem, but at least in my field, it's by no means the majority of knowledge.

As someone from a peripheral university where you can't just drive a few miles and talk to the best in your field, I have successfully started in new subfields of study (getting to the level of writing research papers in top-tier venues) by reading the literature.

While this essay provides a very interesting point of view, I suspect it's heavily colored by the authors' failure to monetize the technology (which is related to the fact that people doing most of the grunt research work, who would benefit the most for this, are PhD students and postdocs who have no money to pay for it - in the text, the author hints at this). I wouldn't take it as an accurate description of academia.

viewfromafar · 4 years ago
Also CS, my interpretation of "what makes science work" is a little different and I would argue that - despite a lot of foundations and techniques being shared in research papers - this field more than any other is constraining the free circulation and application of knowledge.

The equivalent to those biomedical industry players are the big tech who develop closed source and push the edge in some area. They will publish but that does not mean you can replicate any of it.

Software is also fragmented, crippled by IP lawsuits, patent trolls and so on. This does inhibit ability of society to benefit from software since it depends on the private sector to sort things out. The PhDs go and build businesses to "make the science work" in that sense.

The ideal of detached pursuit of knowledge is not a complete fiction (despite the hyperbole), but it does remain an ideal that can only be approximated.

viewfromafar commented on The business of extracting knowledge from academic publications   markusstrasser.org/extrac... · Posted by u/kevin_hu
anonymousDan · 4 years ago
I mean honestly this is just total bullshit. There is plenty of value in academic papers. It's just that there is very little money to be made in developing tools such as those mentioned by the OP as there is very little money in academia.
viewfromafar · 4 years ago
I understood the criticism directed at the value of papers as instruments of knowledge sharing. The argument is not that papers are completely useless in terms of knowledge sharing but that this pure purpose of dissemination is largely overshadowed by considerations of carreer, prestige, funding or any interest other than knowledge sharing.

This is the world we live in. A scientist is a person that needs to make a living and is subject to various constraints.

The reason that there is little money to be made is that society hasn't found a way to set up the scientific process in such a way that the constraints would value the increase in public domain knowledge higher than the incentives to hold some knowledge back.

Part of this may stem from leaving specialized knowledge to academia while letting only companies reap the monetary rewards of putting the knowledge to use. Society benefits only indirectly (better drugs, machines, etc) but industry players will rather shield knowledge and adapt its representation to their own needs.

u/viewfromafar

KarmaCake day19November 5, 2021View Original