Accelerating Photosynthesis - <AUTHOR> http://rubyplants.com/ <comment><USER2> This is not correct: "Food is created by taking CO2, keeping the C and releasing the O2."

The resulting O2 actually comes from a pair of H2O.

Consider the reaction performed by purple sulfur bacteria, which are related by evolution but have a slightly different reaction. It is this:

CO2 + 2 H2S gives [CH2O] + H2O + 2 S

There, carbon dioxide reacts with hydrogen sulfide to give water, sulfur, and part of a carbohydrate.

Photosynthesis in plants is the same sort of reaction, but the situation is less obvious because there is H2O on both sides of the reaction. We've proven what happens by experiments with radioisotopes.

The entire photosynthesis reaction consumes 6 CO2 and 12 H2O to produce 6 H2O, 6 O2, and a sugar.

From the 12 H2O, half of the H goes to the sugar and the other half goes to producing new H2O.

From the 12 H2O, all of the O goes to producing O2.

From the 6 CO2, half of the O goes to the sugar and the other half goes to producing new H2O.

From the 6 CO2, all of the C goes to producing sugar.

</comment><comment><USER3> Photosynthesis is a strange beast...

You know the cliché that something designed by evolution, or "natural", is usually pretty efficient, sort-of "in sync" with its surroundings, etc. For many things this subjectively holds true, with things like Spider silk, flight of large birds, a diving penguin, etc.

Photosynthesis, and the core protein, Rubisco, is anything but! It's _the_ central protein of live on earth, and yet... it's a totally ridiculous machine.

You ever wonder what the inside of a typical cell sounds? In a cartoon it would be a high-pitched whining, because that correlates well with the typical speed at which some protein does its business when busy.

Rubisco is the fat guy lazily picking up the hammer every once in a while, balancing it in the air, slamming it down and...missing 2/3 the time.

So this idea does have potential. Unfortunately, the plant biophysics have been well understood for a few decades, and the idea isn't new or anything.

I'd say the even-odds of doubling the CO_2 fixation of some plant we can grow on a large scale is about 20%.

It is completely irresponsible to let this, and other such schemes, inform policy wrt climate change right now. Invest in research, yes. But using it to put of necessary changes is just motivated reasoning an will end with nothern russia looking like Florida, and Florida looking like what's 30km east of Florida now.

<comment><USER4> Maybe its inefficiency is necessary. After all earth is a global eco system, it's all about balance, everything is inter connected. What if Rubisco stopped missing 2/3 and never missed instead ? What about the global CO2 levels ? Oxygen ? More plants = more food for some animals &c.

This sounds like the typical junior developer starting working on a 20 years old project saying 'Wait a minute, I can rewrite these 50k lines in 500 lines of _insert tech of the day_' while ignoring 20 years of side effects, special cases, well thought decisions, &c.

<comment><USER5> > After all earth is a global eco system, it's all about balance, everything > is inter connected.

Unfortunately, evolution doesn't do balance, but rather local gradient descent. Species reliant on one prey or one plant can and do over-consume their food into extinction and then go extinct themselves. Even the oxygen we breathe was a toxic waste product when the earth was young, and while evolution found a pathway to consuming it, there's never any guarantee of that.

Evolution has had a long time to find solutions, so it shouldn't be ignored, but it's also not a particularly smart system and it definitely isn't directed with long-term goals in mind — evolution can create birds, but not birds which grow their own hypersonic ramjets.

<comment><USER6> Conversely, after the millions of years of evolution, it's not unreasonable to think that creating a more efficient Rubisco could have happened spontaneously in nature by mutation. Our logic suggests this would almost certainly provide some benefit; and yet, nearly all Rubisco enzymes show roughly the same level of efficiency.

To me, this implies some other limiting factor that we don't understand.

<comment><USER7> Highly multivariate random walks are excellent at finding local optima, and poor at descending from those hills to find a higher one.

If something requires, say, five individually-deleterious mutations, each of low probability, it's quite plausible that these will never align in a single organism.

<comment><USER8> A localized entity responsible for the inefficiency doesn't sound like a local minimum, though. It sound like a place where you should (eventually through mutation) find the more efficient path.

There may be a more esoteric explanation... Imagine higher efficiency has a price : plant lives a shorter life, and reproduces less. Then you want to fine tune for the right amount of efficiency in your environment. Then it's advantageous to have a single efficiency lever, instead of a dozen systems to fine tune jointly... Just a guess - I know nothing about bio. :)

<comment><USER7> That is approximately why C4 photosynthesis hasn't swept the field and replaced C3 entirely: it's an advantage in high-light, dry conditions, whereas in wet, dark conditions, the more efficient use of ATP in C3 fixation provides a comparative advantage.

FWIW I'm quite bullish on the type of research in the Fine Article; humans have the ability to provide choice conditions to our crops, and so we can maximize yield without (much) concern for the tradeoffs experienced in the state of nature.

I'd predict, for example, that we'll have a C4 rice crop out of the lab and in the field in ten years or less.

</comment></comment></comment></comment></comment></comment></comment><comment><USER9> The lack of authorship attribution or institutional affiliation is quite strange in this piece. Apparently a lot of effort was undertaken to write the software or at least to write the article. "We" and "our" appear in nearly every sentence. Who are "we"?

The ideas in there are quite interesting to think about. I'm glad I read it, but questions like this are unsettling given the lack of expressed ownership:

"Why bother with environmental control and especially environmental optimization when the goal is accelerating photosynthesis genomically?"

<comment><USER6> Ruby Plants (seemingly formerly known as Plants for Thought) were originally a storefront for succulents. I found an interview with people involved here [1].

[1] [https://www.sublimesucculents.com/plant-for-thought- online-n...](https://www.sublimesucculents.com/plant-for-thought-online- nursery-interview/)

<comment><USER10> Very interesting. That's quite a turn-around for a company like that. Although it sounds like they've spent a long time figuring out how to grow individual plants faster. And seemingly all without needing shady Epstein money and faking results, like a recent infamous MIT lab...

If they're getting more serious, though, I think they might be better served by an editor's rewrite of their 15 pages of Khan Academy-like scribbled slides.

</comment></comment></comment><comment><USER11> Plants have had billions of years to evolve on Earth, if there were a more efficient way to photosynthesize, wouldn't it have emerged by now through natural selection?

For instance, I would imagine that competition in the Amazon amongst plants is high enough to have driven a photosynthesis efficiency arms race. Do different plants differ significantly in their photosynthesis efficiency? If so I would study the genomes of plants in the Amazon, or similarly competitive environments.

<comment><USER12> There already exist plants adapted for optimal yields at lower CO2 levels. They are classified as C4 plants and hit optimal photosynthesis at about modern levels. These include corn and sugarcane, but only make up a small fraction of overall plant species (about 5%).

C3 plants hit optimal levels at higher concentrations, usually 1100-1300 ppm (90% of plants fit this category). See link below for more details:

[https://rclutz.wordpress.com/2020/01/08/heres-looking-at- you...](https://rclutz.wordpress.com/2020/01/08/heres-looking-at-you-co2/)

Now I don't know how the mechanics work. I don't know if you could genetically engineer a C3 plant to work as well as a C4 plant. I reckon there are significant tradeoffs there that nature already factored for.

<comment><USER13> I think that people tend to forget that CO2 levels have varied massively throughout Earth's history and that they were quite higher than they are now for a long time over plants' evolution, which might explain C3 v. C4 plants.

</comment></comment></comment><comment><USER14> Something I haven't seen mentioned much is the recent progress in single atom catalysts[1], which is a really cool idea. These seem able to convert CO2 to CO in high yield. This could be one way to start pulling a lot of CO2 out of the air efficiently. CO can then be used fro many chemical processes whether just sequestering carbon or otherwise.

[1] [https://www.sciencedaily.com/releases/2018/03/180301094857.h...](https://www.sciencedaily.com/releases/2018/03/180301094857.htm)

</comment><comment><USER15> Neat site, but it would be good to have some information on who created it, who did this research, and who (if anyone) funded it.

<comment><USER16> Team's [http://rubyplants.com/ruby-team.html](http://rubyplants.com/ruby- team.html)

There's a map at the bottom of [http://rubyplants.com/autonomous- chambers-2.html](http://rubyplants.com/autonomous-chambers-2.html)

Seems to be a cute pivot from an online plant nursery??? [https://www.sublimesucculents.com/plant-for-thought- online-n...](https://www.sublimesucculents.com/plant-for-thought-online- nursery-interview/)

Faster iteration does seem like it could give useful results, though unsure why they'd target plants not algae. Maybe plants are easier to contain?

</comment></comment><comment><USER17> Very clear explanation, love the diagrams.

To me this is a more sensible way than carbon tax, or even better use carbon tax to fund research like this.

I don't think that economic incentives alone might fix the situation, and maybe not even slow it down sufficiently. We need political focus, and high investment in research.

<comment><USER18> The benefit of a carbon tax is that you can introduce it immediately, provided that there's enough political will. If the carbon tax is sufficiently high I'm convinced there can be a very big net benefit.

The approach from the article will take many years to provide any benefits, assuming

1) they get the efficiency increase they're aiming for

2) they can roll out these new & better plants on a large enough scale to make a difference

3) that the mass-introduction of these new plants doesn't have any unforeseen side-effects

<comment><USER19> I wonder if carbon tax revenues should be ring-fenced, and spent solely on endeavours just like the onein the article?

<comment><USER20> A large part of the carbon tax should be paid out as a dividend. Otherwise poor people can't afford to live anymore. Political acceptance is important for any climate policies.

<comment> barry-cotter This is why I have no hope for anything other than a technological solution to climate change. Anything else would require either a very large decrease in the standard of living in the developed world, contributed poverty in the developing world or both.

<comment><USER20> Replacing fossil fuels with renewables doesn't require a very large decrease in the standard of living. So we already have a technological solution for 80% or so of the problem. Steel, cement, and long distance flying seem to be tricky without releasing CO2, but we should probably only seriously worry about those once we're well on our way with the things that can be replaced without changing quality of life at all.

<comment><USER21> But that a) is only happening because technology lowers costs, changing the economics of renewables so that it makes short-term, self-interest sense to install them, and b) alone it still doesn't solve the problem.

</comment></comment></comment></comment></comment></comment></comment><comment><USER22> Can't wait for a superplant to take over all ecosystems on earth! Hoping it's tasty at least.

<comment><USER23> There was a Stargate episode based on this particular threat. It had Richard Dean Anderson going around shouting "It's a plant!"

</comment></comment><comment><USER24> Aren't phytoplankton the biggest producers of oxygen? They also reproduce a lot faster than land based plants and would be easier to work with and iterate on. Why aren't they mentioned in this article?

<comment><USER25> If your goal is merely to pull CO2 out of the air, that would be the way to go. But that is not their goal; they want to increase agricultural yields to reduce the need for expansion of agricultural land. Pulling CO2 out of the atmosphere is a side-benefit.

</comment></comment><comment><USER26> I've always wondered if humans could create synthetic photosynthesis factories. Skip all the biological steps of creating cell walls and an immune system and just create sugars from light and CO2. I would imagine this technology would be especially valuable for space exploration. The whole plot of The Martian would disappear if Mark Watney had a carbohydrate machine.

</comment><comment><USER27> Beautiful work in automating the experiments and increasing the throughput, very innovative approach.

</comment><comment><USER28> "Add Green & Infrared Antennae Proteins" => Nature will become sad to watch

</comment><comment><USER29> [https://en.wikipedia.org/wiki/Food_forest](https://en.wikipedia.org/wiki/Food_forest)

> Forest gardening is a low-maintenance, sustainable, plant-based food > production and agroforestry system based on woodland ecosystems, > incorporating fruit and nut trees, shrubs, herbs, vines and perennial > vegetables which have yields directly useful to humans. Making use of > companion planting, these can be intermixed to grow in a succession of > layers to build a woodland habitat.

</comment><comment><USER30> > We are building a pipeline from FASTA files of genomes to deployment in our > customer's facilities.

This statement and the remainder of that paragraph is simply nonsense. The same can be said for much of the rest of the text. They are trying to resuscitate an old idea with pure hype.

</comment><comment><USER31> I like the totally novel angle of attack on the CO2 problem!

<comment><USER32> Attempts to improve photosynthetic efficiency is not exactly novel, for example there is the IRRI C4 rice project[0] or various research on RuBisCO efficiency[1][2]. Speeding up the development process and trying to bring all the different improvements under one umbrella might be.

[0] [http://photosynthome.irri.org/C4rice/index.php/component/con...](http://photosynthome.irri.org/C4rice/index.php/component/content/article/19-about/56-what- is-c4-rice) [1] [https://science.sciencemag.org/content/358/6368/1272](https://science.sciencemag.org/content/358/6368/1272) [2] [https://science.sciencemag.org/content/363/6422/eaat9077](https://science.sciencemag.org/content/363/6422/eaat9077)

</comment></comment><comment><USER33> Why forest can't be farms? They should not be opposite but complement each other.

</comment><comment><USER34> why do i feel like i'm in the first part of a scifi movie that ends up in the destruction of all life on the planet due to "clever" science

<comment><USER35> Not sure if you read the news much, but we're not in the first part any more.

</comment></comment><comment><USER36> Still no photosynthesis for humans... :(</comment>


Amazon2csv: Amazon products scraper to CSV (no API token required) - <AUTHOR> https://github.com/tducret/amazon-scraper-python <comment><USER2> Why not use the API? Disclaimer: I'm the author of python-amazon-simple- product-api [1]

[1] [https://github.com/yoavaviram/python-amazon-simple- product-a...](https://github.com/yoavaviram/python-amazon-simple-product-api)

<comment><USER3> Are you referring to the Product Advertising API?

Doesnt that require you to have a quota of affiliate sales to keep using it? I can't find where they state this requirement but I remembered they were very sneaky about disclosing this. If you dont have any affiliate sales after X months, your API key will stop working.

<comment><USER4> Currently you have to be a member of their affiliate program to get API access. To become a full "member" you have to be a prospect who generates three referral sales (iirc) within a 30 day period. So once in you have the API, but getting in isn't as easy as filling out a form. From there you can get your API rate limits increased from the default 1x call per second up to 10 based on your prior 30 day affiliate sales.

<comment><USER5> Last I looked that limit was per IP address.

</comment></comment></comment></comment><comment><USER6> Scraping Amazon is fun and all, but when you start overdoing it they rate- limit your IP and show you my worst nightmare: the Dogs of Amazon (a 500 page with pictures)

Why do I know this? Because I'm the CTO at Nazdeeq.com where we let users buy Amazon products from countries where they don't ship easily, like Pakistan.

Edit: totally open to partnerships in more countries

<comment><USER7> Hi Amin, your platform seems nice. Just wanted to give you a heads-up that your website is being classified as ["phishing" by Avast]([https://i.imgur.com/SmuuRfD.png](https://i.imgur.com/SmuuRfD.png)). I think if you replace "Amazon" in the url with something else it should work fine. Best of luck!

<comment><USER8> Reminds me of how nobody could see one of my user's avatars because the url (a hash) had started with an "ad" segment (for bucketing), as in "/avatars/ad/ad3adb33f". So adblockers blocked it.

My protest against such a ridiculous heuristic was to not fix it.

<comment><USER6> It makes sense why you would choose to do that and I can certainly empathize, but in the interest of user experience I try to fix these problems because my customers deserve a good user experience.

</comment></comment></comment></comment><comment><USER9> The issue with those tools is that Amazon changes the product layout very often and heavily conducts A/B tests. I've once even heard that computer vision is the most stable way to scrape Amazon. I guess this library will stop working rather soon.

<comment><USER10> >I've once even heard that computer vision is the most stable way to scrape Amazon

At a former employer we scraped Amazon many millions of times per day with very simple old tools that rarely needed updating.

<comment><USER11> Are you able to share some details? How often did you have to get new IP addresses? What about user agent? Were the scapers "straight to the point" like amazon2csv (ie: make a request directly to the search page) or did they have randomized behavior (eg: re-use sessions from time to time; click a random link on the page; start from the homepage...)? Did the scrapers ever went against amz's robots.txt directives (eg: interacting with the cart page)? Ever heard from amz itself about your employer's activities on their site?

<comment><USER12> There are services dedicated to scrapping which can take care of proxy-ing your requests so you don't have to worry about IP bans.

For example, Scrapinghub's Crawlera (the guys behind the Scrapy python lib)

</comment></comment></comment></comment><comment><USER13> I remember trying to build a scraper for Amazon. I quickly discovered that there are many types of item pages, and they change over time too. A/B testing probably. Just to get the price of the product out of their HTML markup reliably was a nightmare, I had to build a huge tree of if-this-then-maybe- that logic.

</comment><comment><USER14> The company I work for (zinc.io) has this: [https://zincapi.com/](https://zincapi.com/)

We brand it as an ordering API, but we also offer retrieving the product data (item details/pricing.) We put a LOT of engineering resources into data quality and maintenance, as the API is core to our flagship product, PriceYak. If you have questions or want a token, email email@example.com and mention this post.

</comment><comment><USER15> If you're using this for anything serious, it's probably better to sign up for the keepa API at about $50/month and they scrape Amazon for you. Worth it to not need to deal with the complexities.

</comment><comment><USER16> Nice. From my experience I've found Parsel [1] (used by scrapy) to be an easier to use HTML parsing library than Beautiful Soup. That's just imo.

[1] [https://github.com/scrapy/parsel](https://github.com/scrapy/parsel)

</comment><comment><USER17> Hm, another no-API option (at least if you are on WordPress) is: [https://wpcommission.com](https://wpcommission.com)

</comment><comment><USER18> So how many calls is one allowed before getting banned? Any guidelines on how to use this without breaching T&Cs?

</comment><comment><USER19> Am I the only one who thinks this is rather weird, or at least unconventional code for a scraper in Python?

<comment><USER20> I just took a glance, but nothing seemed too off. Do you care to elaborate?

<comment><USER19> Sure. I'm not really trying to criticize the code, it's just that a lot of this looks foreign and unconventional to me.

1\. requests.Session() is a class. IDK what request.session() invokes (see [https://github.com/tducret/amazon-scraper- python/blob/master...](https://github.com/tducret/amazon-scraper- python/blob/master/amazonscraper/client.py#L39)).

2\. Isn't one of the points of using Session() that it'll persist stuff like cookies and headers? So why is it re-defining the headers multiple times? (e.g. both GET and POST in the same session have their own respective but identical headers).

3\. Is the use of `arg=""` idiomatic? For example in [https://github.com/tducret/amazon-scraper- python/blob/master...](https://github.com/tducret/amazon-scraper- python/blob/master/amazonscraper/client.py#L70)

4\. Using raw list indices without some kind of helper function to catch index and other errors when parsing is not really a good idea in scraping (e.g. `selection[0].text.strip()`.

<comment><USER21> Its a good thing its open source, submit a PR!

<comment><USER19> I know this is HN and all but I am not even entirely confident about my own remarks. I asked "Am I the only one..." earnestly, not as a way of softening criticism. I'm a self-taught amateur and have never submitted a PR before.

</comment></comment></comment></comment></comment><comment><USER22> It is also illegal to scrape AZ, since if you scrape it , it means you don't own this content and you are just stilling products data added to the site by produsts proper owners.

<comment><USER23> why aren't Larry and Sergey behind bars, then? Scraping publicly available information is far from illegal.

Also, Interestingly only Alibaba's bots are completely blocked from crawling: [https://www.amazon.com/robots.txt](https://www.amazon.com/robots.txt)

<comment><USER22> Check amazon api T&C, also try to do the same with Craigslist and see how long you they will let you do it. scraping data is always a shady business if you do it without a permission of content owner

<comment><USER23> It is anything but shady. They can send you a C&D or file a suit and seek injunction but there is no way they can get you in trouble with the law for scraping publicly available data.</comment></comment></comment></comment>


Fit text of any length into image of fixed dimensions - <AUTHOR> http://coding.pressbin.com/133/PHP-Fitting-text-to-image-size-with-ImageMagick/

<comment><USER2> It's interesting: fitting text like this is one of those problems which I've found beginner programmers often struggle with when they come up against it. It really doesn't seem like it should be as hard as it is. Latin characters - go figure.

</comment><comment><USER3> > _$command = 'convert -page +5+5 -background "#'.$bgcolor.'" -fill "#000000" > -font '.$font.' -size 310x680 caption:"'.$text.'" -page +0+695 -background > "#000000" -fill "#000000" -size 320x60 caption:"-" -page +3+708 -background > "#000000" -fill "#FFFFFF" -font '.$font.' -size 310x44 > caption:"www.CORRELATED.org /'.$blog_id.'" -background "#'.$bgcolor.'" > -layers mosaic pinterest_'.$blog_id.'.jpg_

There should be a whole bunch of escapeshellarg() in there. Who knows what the text contains? Code like this is exactly why PHP devs get a bad rep. Please don't post PHP code online unless you've made it reasonably secure, because somebody somewhere is going to copy that and get pwned.

Also, why not use PHP's own imagick extension? It exposes a neat object- oriented interface, it will be much easier for people to read and tweak, and you won't have to escape anything.

<comment><USER4> The article/blog author does have a disclaimer at: [http://coding.pressbin.com/61/Caveat-coder-About-the-code- sn...](http://coding.pressbin.com/61/Caveat-coder-About-the-code-snippets-on- this-blog/)

but I fear that those most likely to just grab this code and run with it, are the least likely to even notice that page, let alone heed its (nonspecific) advice.

<comment><USER3> You're right, a 17-month-old disclaimer is useless unless there's a link to it within a hundred pixels or so of the actual code sample.

If I ever start a technical blog, I'm going to style the <code> element so that every code sample automatically gets a link to a disclaimer about security, copyright, etc. Also throw in class="insecure" (background-color: reddish) to any sample which I know should never be used in production.</comment></comment></comment>


A Simple Guide to Five Normal Forms in Relational Database Theory (1982) - <AUTHOR> http://www.bkent.net/Doc/simple5.htm <comment><USER2> My biggest pet peeve in the world of data storage is that the most powerful ideas from relational data theory are still mostly locked up in books and papers, and most programmers who think they know what "relational" means aren't aware of the full picture.

The people who did all the pioneering work on the subject (mostly E.F. Codd and Chris Date) seem to have made several blunders in trying to popularize their ideas. For example, one of Date's later books ("Go Faster: The Transrelational(tm) Approach to DBMS Implementation") contains some very useful ideas. But it was written in 2001 and not published until 2011, because he was working with a now-failed startup that was trying to keep it all a trade secret.

Most of their writing is not available online. You have to buy their books. Which is an author's prerogative, but seriously limits the reach of the ideas.

The world thinks it already has relational databases that are good enough. Convincing it otherwise requires a web-savvy marketing approach that has so far been lacking.

<comment><USER3> I just checked out that book. The results are presented as some kind of revolution but:

1\. The system presented is simply an inefficient way of doing a single column index on each column.

2\. The book contains NO benchmark results. It only claims that it's efficient because of X, Y and Z without any numbers to back that up. Meanwhile the method involves a lot of pointer chasing which is extremely slow, especially on disk. Queries that require multi-column indices will also be extremely inefficient of course, because they will require scans.

I wouldn't go so far as saying that the book is worthless, but its claims are certainly dubious at best.

<comment><USER4> "Queries that require multi-column indices will also be extremely inefficient of course, because they will require scans."

If a query uses just the columns that are in a multi-column index, and doesn't sort in any order other than the index order, then the query may be much more efficient than a with a single-column index - since all the data may be retrieved from the index, rather than seeking to the row.

I think you left something out.

<comment><USER3> We can decide which indices we have, you know.

The conditions that you state are not by far the only conditions when a multi column index helps you. Even if you do not sort by the index order, and you do not have all the data in the index, the index may still be way more efficient. For example if you have SELECT A WHERE X=3 AND Y=5 ORDER BY B with an index (X,Y).

</comment></comment></comment></comment><comment><USER5> I actually got a chance to chat about nosql with one of the people who coined the term "nosql" (here on hn, no less). It sounds like it was a term that got away from them a bit. I don't think anyone really intended to suggest that sql should be completely abandoned. notalwayssql, or maybeconsidersomethingotherthansql might have been better terms (well, not _better_ , but more specific to what was actually intended).

Relational databases and sql are an exceptionally sound approach to a lot of data storage and retrieval problems. Some of the "nosql" technologies emerged from new problems that emerged (such as full text indexing, networks).

Progress is an interesting thing, and doesn't always happen on an even keel. These days, I think you're far less likely to encounter knee-jerk resistance to an rdbms or sql. The dust is settling a bit, and in this case, that's a good thing.

</comment><comment><USER3> Can't you summarise all of that simply: "a database schema should be able to represent only valid data".

e.g. employee, department, location is not good because that schema can represent invalid data: a single department can't be in 2 locations but the schema can represent that.

The same rule of thumb applies to types in programming: a data type should be able to represent only valid values. This is why sum types are superior to error codes: a function can return a result AND an error code, when what we usually want is that the function returns a result OR an error code. When invalid values are unrepresentable that makes a lot of errors impossible. Though sometimes your type system can't deal with all the constraints that you have, e.g. an array should be sorted (an unsorted array is representable but not valid => bad).

<comment><USER6> The various normal forms are named for the kinds of invalid data they reject, so they can be used as a design process to ensure the higher level goal (that "a database schema should be able to represent only valid data")

</comment></comment><comment><USER7> I thought that the main explanation of normals forms was that "the rows be a function of key, the whole key, and nothing but the key".

</comment><comment><USER8> _First normal form excludes variable repeating fields and groups_

What are the definitions of "variable repeating fields" and "groups?"

What would violating records look like?

<comment><USER9> A text column with a list of {comma, space, ...}-delimited values representing a set, e.g. of tags, is something you occasionally see.

</comment></comment><comment><USER10> If you find it hard to read, set the body style e.g. width:600px; margin:auto; font: 18px/24px Calibri,Arial,Helvetica; color:#333; background:#F3F3F3;

</comment><comment><USER11> OT, but: the guy retired in 2000. and died in 2005. That's sad :(

<comment><AUTHOR> From Amazon page for _Data and Reality_ :

       About the Author

       William Kent (1936-2005) was a renowned researcher
       in the field of data modeling. Author of Data and
       Reality, he wrote scores of papers and spoke at
       conferences worldwide, posing questions about
       database design and the management of information
       that remain unanswered today. Though he earned a
       bachelor's degree in chemical engineering and a
       master's in mathematics, he had no formal training
       in computer science. Kent worked at IBM and later
       at Hewlett-Packard Laboratories, where he helped
       develop prototype database systems. He also served
       on or chaired several international standards
       committees. Kent lived in New York City and later
       Menlo Park, Calif., before retiring to Moab, Utah,
       to pursue his passions of outdoor photography and
       protecting the environment.

While 69 is fairly young, his death does not appear to be tragic in the sense of unfulfilled ambitions.

<comment><USER11> > While 69 is fairly young, his death does not appear to be tragic in the > sense of unfulfilled ambitions.

My comment was from the perspective of course of life. After retirement, he had only 5 years to pursue "his passions of outdoor photography and protecting the environment". (Note that he did not continue working on his research.)

He was under pressure to deliver results (school, working, etc.) for the majority of his life, and he had only 5 years of total and independent (within financial constraints) freedom. _That_ is sad.

</comment></comment></comment><comment><USER12> It's worth noting that this model works quite well for the vast majority of client facing applications out there.

I.E. Things categorized by tags or groups where 1-to-n relationships are necessary. Of course, the extreme of this is EAV (Entity Attribute Value) which I would limit to meta/taxonomy data for performance reasons.

But for information where the labels (or quantity) aren't known before input are easier to deal with in normalized databases.

E.G. Getting metadata on a specific entry with no prior knowlege of said data except parent id:

      SELECT id, label, content FROM meta WHERE id IN (
        SELECT meta_id FROM posts_meta WHERE post_id = :id
      );

Or if you're using Postgres, you can return the metadata as an associative array. E.G. [http://stackoverflow.com/a/11942726](http://stackoverflow.com/a/11942726)

The following is an excerpt from the actual schema I used on a very simple forum that ran on SQLite for years before switching to Postgres fairly recently. The normalization (varying forms) afforded a lot of flexibility. Maybe someone will find it useful.

      CREATE TABLE posts (
      	id INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL,
      	created_at DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
      	updated_at DATETIME DEFAULT NULL,
      	title VARCHAR NULL,
      	summary TEXT NOT NULL,
      	body TEXT NOT NULL,
      	plain TEXT NOT NULL,
      	quality FLOAT NOT NULL DEFAULT 0,
      	status INTEGER NOT NULL DEFAULT 0,
      	reply_count INTEGER NOT NULL DEFAULT 0,
      	auth_key VARCHAR NOT NULL
      );

      CREATE INDEX idx_posts_on_status ON posts ( status );
      CREATE INDEX idx_posts_on_created_at ON posts ( created_at );

      CREATE VIRTUAL TABLE posts_search USING fts4 ( search_data );

      CREATE TABLE posts_family (
      	parent_id INTEGER NOT NULL,
      	child_id INTEGER NOT NULL,
      	PRIMARY KEY ( child_id, parent_id )
      );

      CREATE TABLE taxonomy (
      	id INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL,
      	label VARCHAR NOT NULL,
      	term VARCHAR NOT NULL,
      	created_at DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
      	updated_at DATETIME DEFAULT NULL,
      	status INTEGER NOT NULL DEFAULT 0
      );

      CREATE TABLE posts_taxonomy (
      	post_id INTEGER NOT NULL,
      	taxonomy_id INTEGER NOT NULL,
      	PRIMARY KEY ( post_id, taxonomy_id )
      );

      CREATE TABLE taxonomy_family (
      	parent_id INTEGER NOT NULL,
      	child_id INTEGER NOT NULL,
      	PRIMARY KEY ( child_id, parent_id )
      );

      CREATE TABLE meta (
      	id INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL,
      	label VARCHAR NOT NULL,
      	parse_as VARCHAR NOT NULL DEFAULT "text",
      	content TEXT NOT NULL
      );

      CREATE TABLE posts_meta (
      	post_id INTEGER NOT NULL,
      	meta_id INTEGER NOT NULL,
      	PRIMARY KEY ( post_id, meta_id )
      );

      CREATE UNIQUE INDEX idx_taxonomy_on_terms ON taxonomy ( label ASC, term ASC );
      CREATE INDEX idx_taxonomy_on_status ON taxonomy ( status );

      -- Triggers

      -- Post create procedures
      CREATE TRIGGER post_after_insert AFTER INSERT ON posts FOR EACH ROW
      BEGIN
      	INSERT INTO posts_search ( docid, search_data )
      		VALUES ( NEW.rowid, NEW.plain );
      	UPDATE posts SET updated_at = CURRENT_TIMESTAMP WHERE id = NEW.rowid;
      END;

      -- Post update procedures
      CREATE TRIGGER post_before_update BEFORE UPDATE ON posts FOR EACH ROW
      BEGIN
      	DELETE FROM posts_search WHERE docid = OLD.rowid;
      END;

      CREATE TRIGGER post_after_update AFTER UPDATE ON posts FOR EACH ROW
      BEGIN
      	INSERT INTO posts_search ( docid, search_data )
      		VALUES ( NEW.rowid, NEW.plain );
      	UPDATE posts SET updated_at = CURRENT_TIMESTAMP WHERE id = NEW.rowid;
      END;

      -- Post deletion procedure
      CREATE TRIGGER post_before_delete BEFORE DELETE ON posts FOR EACH ROW
      BEGIN
      	UPDATE posts SET reply_count = ( reply_count - 1 )
      		WHERE id != OLD.rowid AND id IN (
      			SELECT parent_id FROM posts_family WHERE child_id = OLD.rowid
      		);
      	DELETE FROM posts_family WHERE parent_id = OLD.rowid OR child_id = OLD.rowid;
      	DELETE FROM posts_search WHERE docid = OLD.rowid;
      	DELETE FROM posts_taxonomy WHERE post_id = OLD.rowid;

      	DELETE FROM meta WHERE id IN (
      		SELECT meta_id FROM posts_meta WHERE post_id = OLD.rowid
      	);
      	DELETE FROM posts_meta WHERE post_id = OLD.rowid;
      END;

      -- Post parent insert procedures
      CREATE TRIGGER posts_family_after_insert AFTER INSERT ON posts_family FOR EACH ROW
      BEGIN
      	UPDATE posts SET reply_count = ( reply_count + 1 ) WHERE id IN (
      		SELECT parent_id FROM posts_family WHERE child_id = NEW.rowid
      	);
      END;

      -- Taxonomy procedures
      CREATE TRIGGER taxonomy_after_insert AFTER INSERT ON taxonomy FOR EACH ROW
      BEGIN
      	UPDATE taxonomy SET updated_at = CURRENT_TIMESTAMP WHERE id = NEW.rowid;
      END;

      CREATE TRIGGER taxonomy_after_update AFTER UPDATE ON taxonomy FOR EACH ROW
      BEGIN
      	UPDATE taxonomy SET updated_at = CURRENT_TIMESTAMP WHERE id = NEW.rowid;
      END;

      CREATE TRIGGER taxonomy_before_delete BEFORE DELETE ON taxonomy FOR EACH ROW
      BEGIN
      	DELETE FROM posts_taxonomy WHERE taxonomy_id = OLD.rowid;
      	DELETE FROM taxonomy_family WHERE parent_id = OLD.rowid OR child_id = OLD.rowid;
      END;

<comment><USER9> > Or if you're using Postgres, you can return the metadata as an associative > array. E.G. > [http://stackoverflow.com/a/11942726](http://stackoverflow.com/a/11942726)

That's not an associative array, it's just an array of a composite type. The hstore type is probably the closest you'd get to an associate array in PostgreSQL, but the keys and values are always strings.

<comment><USER13> > The hstore type is probably the closest you'd get to an associate array in > PostgreSQL

No, a table (possibly a temp table with the results of a particular query) with an appropriately defined primary key (or other unique index) would be the closest you can get to an associative array -- since a relation with _n_ candidate keys is exactly identical to _n_ different associative arrays with the same data but different key/value splits.

But an array of a composite type drawn in such a way that some set of columns is guaranteed unique is pretty much the same thing from a data perspective, even though you may need to do work on the client side to load it into a structure that supports associative array operations (e.g., efficient key/value lookups).

<comment><USER9> I meant as a self-contained type. PostgreSQL doesn't support nested tables.

The "associative" in associative array implies association is a property of the data structure, not the way you happen to be using it.

</comment></comment></comment></comment><comment><USER14> Keep in mind that preserving space was of the utmost of importance in 1982. Eliminating data redundancy was considered the utmost of design, eschewing maintainability, intelligibility, and real application behaviors.

Please do not allow your data model designs to be artificially constrained by the requirements of the past.

<comment><USER15> Normalization might actually take up more space, e.g. if you have to break out a column into a separate table and introduce a new primary key.

The reason for normalization is to preserve integrity of the data. If the same information occurs multiple times, it is possible to change it in one place and not the other, thereby introducing inconsistent data. This might have disastrous results depending on the application.

As far as I know, data integrity is still pretty important even today.

Redundancy should be a cause for concern regardless of the amount of storage available. Redundancy might be used deliberately eg. for caching or robustness, but even the you usually want to have one canonical version of the data.

<comment><USER16> >As far as I know, data integrity is still pretty important even today.

Tell that to the NoSQL hipsters.

<comment><USER17> For the love of (insert small thing here). NoSQL is not necessarily about throwing data integrity out the window. It's about re-organizing your data so that the things you care to be integrated are, such as a document with a sub- document or list. Pretty much every data store promotes some kind of data integrity.

It might not be ACID data integrity. It might not care to enforce referential integrity outside of the document, or value, or whatever the modeling paradigm is. There is still integrity. If you don't like that, fine. Fair enough. Some might be okay with such a system. Name calling is of little benefit. It is a form of violence. "Violence is the last refuge of the incompetent" \- Isaac Asimov.

If you would like to learn more about the new data stores, see my short book, New Data: a Field Guide. [https://leanpub.com/NewDataAFieldGuide](https://leanpub.com/NewDataAFieldGuide). It's target at managers and other with little time to get a good idea.

<comment><USER18> >> Name calling is of little benefit. It is a form of violence. "Violence is the last refuge of the incompetent" \- Isaac Asimov.

I hope you saw the irony in that.

<comment><USER17> It's ironic in the Alanis Morissette way.

However, it was more apt against the parent's comment. It did not say why NoSQL users are problematic, or even wrong. It just flat out lambasts anyone who walks away from the orthodoxy of ACID-SQL with an epithet. It truly was an incompetent comment.

I'm using ArangoDB on my project. My reason is that honestly what I'm doing really is document-y. I could use MySQL or PostGRE, but I'm opting for something different for the sake something different. I do want to have integrity, though. Arango has integrity at the document level as well as distributed transactions. It doesn't enforce references though. I'm fine with that.

What annoys me is when Internet commentator attack something new without at least a cursory show of reasoning.

<comment><AUTHOR> When the internet annoys me, I try to hit the back button. Though sometimes, I just have to turn it off.

[Disclaimer: this was written instead of dumping gasoline on the fire with the first version.]</comment></comment></comment></comment></comment></comment></comment>


Open Source Calculator Teaches Us about Quality Documentation - <AUTHOR> https://hackaday.com/2018/05/18/open-source-calculator-teaches-us-about-quality-documentation/ <comment><USER2> I had not heard of this project before and I ordered one after reading this article and I have to say that everything about their web UI/UX experience is world class. Possibly some of the best I've ever seen. Their simulator[1] is accurate AND responsive to even weird mobile form factors.

The web site is snappy and has zero cruft. I feel like their design was inspired by or comes from the same school as Teenage Engineering, who made the OP-1 synthesizer.

These cats are doing amazing work. This is a masterpiece.

[1] [https://www.numworks.com/simulator/](https://www.numworks.com/simulator/)

[2] [https://www.teenageengineering.com/products/op-1](https://www.teenageengineering.com/products/op-1)

<comment><USER3> Also an excellent example of how a site can (and should) be functional without javascript enabled, incidentally.

<comment><USER4> For those without noscript etc. this [1] is how it looks without JS. Absolutely amazing.

[1] [https://i.imgur.com/gTXPXrx.png](https://i.imgur.com/gTXPXrx.png)

</comment></comment></comment><comment><USER5> I've got two of these and I love them. One if for development and has the 10 pin debug connector soldered in, the other is in its "standard" form for the most part except that it exfiltrates the UART because part of my plan is a make it the visual output of an VNA.

The only complaint I have (and its minor) is that the contrast on the case is poor. A black case with white, light blue, and orange labels would have been stellar, with the white case things fade into the background.

<comment><USER6> This is actually one of the biggest reasons I've not bought one already. The colour selection is deeply flawed in my opinion. I say opinion but it's my opinion based on years of paying attention to user experience and ergonomics. It has a low contrast and low contrast is bad on items intended for swift and decisive use. Sure, too high of a contrast will be bad, but that's partly dependent on font and other aspects of the design as to when it becomes "too high contrast", regardless of that, this colour scheme is far too low contrast.

<comment><USER7> Since nothing but the logo is printed on the case (the button membrane has all the symbols directly printed on it), unlike say the swiss micros, you could very, very easily take it apart and spray it another color.

</comment></comment></comment><comment><USER8> Played a bit with the online simulator and immediately ordered one for my son (high school). Great UI, I could immediately print a function, realize that it was showing sin() in degrees and immediately found how to change it in radians and to cap the graph to x between -5 and 5. Trivial things but usually I don't find my way easily in a calculator that I do not know because most UIs suck.

</comment><comment><USER9> I very much like the idea of this calculator, particularly since it has a python implementation. However, there are a couple of caveats - it uses binary arithmetic, though since release it seems they've improved the accuracy, and also I'm not sure how free this license is[1]. For something that isn't open- source, but uses RPN and has quad-precision binary-encoded decimal precision the DM42 looks really nice[2].

[1] [https://github.com/numworks/epsilon/blob/master/LICENSE](https://github.com/numworks/epsilon/blob/master/LICENSE) [2] [https://www.swissmicros.com/dm42.php](https://www.swissmicros.com/dm42.php)

<comment><USER10> >I'm not sure how free this license is.

There is an ongoing discussion about what license to use for what part of the project, and what is the rational behind such and such choice. See this Github issue: [https://github.com/numworks/epsilon/issues/38](https://github.com/numworks/epsilon/issues/38)

</comment></comment><comment><USER11> If anyone from the project reads this, your website is unreadable due to abysmal contrast. Please see [https://www.w3.org/TR/UNDERSTANDING- WCAG20/visual-audio-cont...](https://www.w3.org/TR/UNDERSTANDING- WCAG20/visual-audio-contrast-contrast.html)

<comment><USER12> +1. The site is beautiful, but isn't good for older eyes. Too many sites seem to do this nowadays. I applaud them for their creativity, but they need an older person to test-drive it.

</comment></comment><comment><USER13> How is this "Open Source"[1] when everything is licensed CC BY-NC-ND? What was the point of releasing anything if changes can't be made or shared? One might as well get a TI-84 since there are FOSS firmware replacements [2] and it would be much more free than this.

I would have bought one of these if the license was not so restrictive.

[1] [https://opensource.org/osd-annotated](https://opensource.org/osd- annotated)

[2] Knight OS [http://www.knightos.org/](http://www.knightos.org/)

</comment><comment><USER14> It looks like an underpowered copy of the HP Prime.

Why should I own one, because it is open source?

<comment><USER15> Who owns a calculator outside of schools?

Everything can be done better and faster in a cas on a laptop.

<comment><USER16> > Everything can be done better and faster in a cas on a laptop.

Everything except actually typing in the problem. A good specialized keyboard and input method (RPN) will always beat QWERTY, especially one that doesn't even have a number pad.

<comment><USER15> Unless you need to do real calculations, in which case qwerty beats the pants off RPN because you are just programming.

Calculators are a relic from a bygone era, kept in use only by regulations and a captured market.

<comment><USER17> > Calculators are a relic from a bygone era, kept in use only by regulations > and a captured market.

Uh, no. I often find myself picking up a calculator rather than opening up Mathematica to do a lot of calculations.

<comment><USER15> Might I suggest Jupiter notebooks?

They are like mathematica, but don't suck.

</comment></comment></comment></comment></comment></comment><comment><USER18> I hate to be a naysayer here (because I actually like the idea of this calculator) but I use R for virtually every mathematical and statistical problem I encounter. It's always open on my computer while I'm working and I'm comfortable enough with the program that most of the syntax requires little thought on my part.

If I'm in the field and need to perform some calculations, I either use my phone (for simple calculations) or my $17 Casio statistics calculator.

As a risk assessor and environmental scientist, I have NEVER needed anything more than these.

<comment><USER19> I have a TI-89 emulator in my android phone. I use it all the time from simple calculations to graphing. I think I might have used the calculus functions a couple of times. Anyway, it's really convenient and now I wouldn't even think about carrying around another device that only does what a calculator does.

</comment></comment><comment><USER20> Would this be a good calculator to get for actual engineering work, or is it too limited by its testing restrictions? If not, what is a good engineering calculator these days?

<comment><USER16> This calculator is made for high school math, not science. Its main concession to exam rules is a special mode that you don't have to engage. Outside of that mode, the big feature that's still missing is a Computer Algebra System.

But what's usually not even on people's radar is whether the calculator can handle units. The line of HP calculators that ended with the HP 50g had the most useful system I've seen for computation on quantities with units. It serves both as a type checking safety feature and provides automatic conversion. TI's top graphing calculators have had similar functionality since at least the TI-89/92 generation, but (as usual) without a good user interface to make it worth using. The NumWorks calculator does not appear to have any capability for unit conversions, let alone carrying units throughout calculations.

</comment></comment><comment><USER17> Looks great, but there are a couple things that I think they could work on:

> $99.99

This is in-line with, or slightly above, other players in the market (e.g. TI, Casio). I'd love to see someone challenge them in this space with something that's like $25. I can get a cheap $10 scientific calculator that does 60% of the same things for $10, so it really seems like there is a spot here for a lower price point. Especially since the hardware is so "old".

> 20+ hours of use on a single charge

A couple hundred hours would be nice. The benefit of a normal calculator is that it works without charging really being a thing that most people have to worry about.

<comment><USER21> > A couple hundred hours would be nice. The benefit of a normal calculator is > that it works without charging really being a thing that most people have to > worry about.

This is almost certainly due to using what looks like either a transmissive LCD or an OLED display, which require a lot of power.

<comment><USER17> Yeah, I'd love to see something like an E-ink display that holds its charge much longer.

<comment><USER22> How would an E-ink display work for a calculator? I haven't used them for more than about 20 minutes in my life, but as long as there isn't a lot of lag while typing, it seems line it'd be a good choice.

Much of the time a calculator is glanced at while doing math on paper or sitting idle while waiting for the next input. A 0-energy display would be ideal for this. It'd be interesting to see a breakdown of energy and energy consumption by part on a calculator.

<comment><USER21> A solar-powered scientific calculator consumes less than one mW.</comment></comment></comment></comment></comment>


Underwater caves in Mexico preserve one of the world's oldest ochre mines - <AUTHOR> https://www.sciencemag.org/news/2020/07/underwater-caves-mexico-preserve-one-world-s-oldest-ochre-mines <comment><USER2> HN July 4th thread _Scuba diver accidentally discovers prehistoric industrial complex in Mexico_ [1], the original paper [2], and the spectacular underwater footage included in a CBC News video [3] via joachimma [4].

[1] [https://news.ycombinator.com/item?id=23730884](https://news.ycombinator.com/item?id=23730884)

[2] [https://advances.sciencemag.org/content/6/27/eaba1219.full](https://advances.sciencemag.org/content/6/27/eaba1219.full)

[3] [https://www.cbc.ca/player/play/1760020035814/](https://www.cbc.ca/player/play/1760020035814/)

[4] [https://news.ycombinator.com/item?id=23731910](https://news.ycombinator.com/item?id=23731910)

</comment><comment><USER3> Would be great if mining industry kept his hands off this place

<comment><USER4> Thank god global warming flooded it 7000 years ago.

<comment><USER5> _During deglaciation since the Last Glacial Maximum, between about 20,000 to 7,000 years ago (20–7 ka), the sea level rose by a total of about 100 m, at times at extremely high rates, due to the rapid melting of the British-Irish Sea, Fennoscandian, Laurentide, Barents-Kara, Patagonian, Innuitian and parts of the Antarctic ice sheets._

[[https://en.wikipedia.org/wiki/Early_Holocene_sea_level_rise](https://en.wikipedia.org/wiki/Early_Holocene_sea_level_rise)]

Setting the sea surface to -100m on [https://www.floodmap.net/](https://www.floodmap.net/) shows a very different world: walking dry-shod from Ireland to Helsinki.

<comment><USER6> Very cool website. I had no idea so much of the ocean was so deep. I'd like to see a chart of sea level vs sea area.

<comment><USER7> There's an xkcd what if that made me realize how deep/shallow the oceans are in various places. [https://what-if.xkcd.com/53/](https://what- if.xkcd.com/53/)

Bonus - what happens to Mars if you dump all the water there: [https://what- if.xkcd.com/54/](https://what-if.xkcd.com/54/)</comment></comment></comment></comment></comment>


Physiological impact of N95 mask on healthcare workers - <AUTHOR> https://pubmed.ncbi.nlm.nih.gov/20420727/ <comment><USER2> > Two subjects had peak P(CO2) > or = 50 mm Hg. The FFR with exhalation valve > offered no benefit in physiological burden over the FFR without valve. The > FFR dead-space oxygen and carbon dioxide levels did not meet the > Occupational Safety and Health Administration's ambient workplace standards.

While the rest of the study said 1hr of typical healthcare worker activity was not a problem for functioning, this part is somewhat alarming.

<comment><USER3> The fact that the dead space air doesn't meet OSHA standards for ambient air is a red herring. When you breathe out, you're filling up the mask with your exhaled breath. When you breathe in, you'll breathe in most all of the dead space air, and then fresh, filtered air. They measured tidal volumes of about 900ml, and the average N95 mask dead space is 125ml. Therefore, about 15% of the inhaled air will be air that was previously exhaled.

What they found was that the dead space CO2 was about 3000ppm. Suppose they're indoors and CO2 is 700ppm. The mask increases CO2 to 1045, which is still well within an acceptable range.</comment></comment>


Updating the Language of SPI Pin Labels to Remove Casual References to Slavery - <AUTHOR> https://hackaday.com/2020/06/29/updating-the-language-of-spi-pin-labels-to-remove-casual-references-to-slavery/ <comment><USER2> As a black person, I find this to be pretty racist. The idea that this will appease blacks or is wanted by us is deeply insulting.

How disconnected from black experience can you be that you think this is important or desirable?

It trivializes our very important concerns about police brutality and systematic racism. Do you want to fight against slavery? Then lets campaign to abolish the exception in the 13th amendment.

<comment> kube-system I get your point, but the Open Source Hardware Association probably does not have much influence over more important issues.

I don't think this is so much of them saying "look at us we fixed it!" as much as it is them saying "we're taking responsibility for the domain over which we have power".

<comment><USER3> Seems more like a cheap, public religious exorcism; "thoughts and prayers"

"Would you like to save the world from the degradation and destruction it seems destined for? Then step away from shallow mass movements and quietly go to work on your own self-awareness. If you want to awaken all of humanity, then awaken all of yourself. If you want to eliminate the suffering in the world, then eliminate all that is dark and negative in yourself. Truly, the greatest gift you have to give is that of your own self-transformation."

-Lao Tzu

</comment></comment></comment><comment><USER4> These are people who will do anything to destroy you. Question whether an SPI pin name is oppressive and risk having your career destroyed. It's not a matter of social progress, it's about seizing power and using _any_ tool to do it.

I think that's the breakthrough I had in realizing whether it's worth arguing against the woke-mob. They don't care about arguments, they don't even have one.

<comment> kube-system What power exactly do you think is being seized through the renaming of a pin on a chip? And by who?

<comment><USER4> Renaming a pin isn't seizing power - it's exercising power that's already been taken or at least trying to be established, i.e. calling anyone who dares to question actions, movements, etc. a racist and destroying their livelihood. The power is through co-opting race issues, and other marginalized identities to silence debate and free thought. Oddly enough it's usually done by the managerial, urbane, upper-middle class white crowd.

<comment> kube-system It only destroys the livelihood of people who decide to die on some mountain of political thought exercise that doesn't belong in a professional workplace to begin with.

There's no transfer of power happening. Professionalism is and always has been inherently incompatible with unfettered "debate and free thought".

</comment></comment></comment></comment><comment><USER5> If we spent our time changing specs every time someone somewhere gets offended by something that didn't even happen to their generation, we will be spending all our time doing only this.

<comment><USER6> [https://en.m.wikipedia.org/wiki/Slavery_in_the_21st_century](https://en.m.wikipedia.org/wiki/Slavery_in_the_21st_century)

<comment><USER5> So ? I know there is still slavery. There are still people who die, should I stop using the phrase "the server is dead" because I might offend you since you lost your grandma ?

</comment></comment></comment><comment><USER3> While there has been so many pushes like this to remove the words of slavery from our consciousness, it's important to be conscious of the fact that there are more people living in slavery right now than ever before in history.

<comment><USER7> Well that's interesting, but could easily be do to an explosion of population. Anyone have historical per capita numbers? They seem to be hard to find.

<comment><USER3> Difficult to find such data, but population explosion surely helped scale up the absolute numbers.

Nevertheless, a lower rate of slavery per capita should still not suffice as a satisfactory excuse for us to ignore the uncomfortable present realities of the tens of millions of people currently living as slaves.

<comment><USER7> Completely agree, my issue is only with the presentation of data while not providing context for it which I feel is disingenuous in an argument that has no need to be disingenuous.

</comment></comment></comment></comment><comment><USER8> How amusing.

As a thought experiment, if using the term "slave" is prohibitively offensive in a computer program (even if the reference is only conceptual and doesn't have anything to do with human slavery--as anyone with half a brain knows), what is supposed to happen in the event that a program, or some "casual" text actually does need to refer to actual human slavery? Is it a topic that can no longer be put to words, because the words are offensive? For example, what if I wrote a computer program to do some sort of analysis on historical slavery data. Is it acceptable or not to name a variable "slaves?" Do I have to rename it "disadvantagedPersonsThanksBLM" ?

Would the reasoning be "conceptual slavery cannot be expressed in such a way, but real slavery is permissible to express" ?

What's next, "leader?" Maybe red-black trees have to be renamed? Integration tests? Maybe we have to switch default terminal colors to pink-purple to satisfy the definitely-not-fascists?

<comment><USER9> It's easier to try and remove words to show everyone you're "doing something" than to actually make a real change.

</comment></comment><comment><AUTHOR> Open hardware associasion's post

[https://www.oshwa.org/a-resolution-to-redefine-spi-signal- na...](https://www.oshwa.org/a-resolution-to-redefine-spi-signal-names)

<comment><USER9> "our community has gone this long without acknowledging the need to treat all humans with respect."

Wait is that what we weren't doing by using the terms "slave" in a different context than anything resembling the actual slave trade? Come on now, we're all adults here. Have some respect for our own autonomy of thought.

Also, great job calling out all those companies who haven't given in to your ludicrous demands. That'll get the PR people there so scared they won't have a choice but to do what you say.

</comment></comment><comment><USER10> I was doing this in my SCH's years ago. Before I plug in any wire, I first ask permission to touch it and what it's preferred pronoun is

</comment><comment><USER11> I would like to know if those who effectively are slaves now, would approve of this. It looks like doing something to feel good without checking whether it actually does any good.

</comment><comment><USER12> Continuing to use obsolete terms like MISO is double-plus-ungood.

</comment><comment><USER13> The only problem I have with this extremist campaign is that it's about controlling other people. Disagreeing with their narrative publicly means risking their attempt at cancelling your livelihood. You couldn't even disagree within an organization safely.

They're not asking nicely. They're not actually _asking_ at all. You either agree with the change or you are branded an Enemy of Progress.

Imagine an employee at a Big Tech Company publicly disagreeing with the change solely for the fact that they don't wish to succumb to bullying. Many nerds have a visceral reaction to bullies.

Paradoxically, these people are forcing others to take actions against their will. They're making themselves masters and making slaves of others.

<comment><USER4> This isn't about racism anymore (and I doubt it ever was).

It's about imposing draconian penalties on anyone that doesn't yield.

They're interested in power - it's a naked power grab, and they shield it with their claims of vulnerability and powerlessness.</comment></comment>


A Hierarchical Approach for Generating Descriptive Image Paragraphs - <AUTHOR> https://arxiv.org/abs/1611.06607 <comment><USER2> From the title I thought someone had a system that could generate decent paragraph length image descriptions. First I thought 'surely not', then clicked through and saw the authors (Esp. Fei Fei Li) and thought 'oh shit, maybe?', then glanced at the results and realised it is mostly about establishing a baseline system.

We are still 3 years off this, and 5 years wouldn't surprise me. Text is hard.

<comment><USER3> I believe you misread the article. It is indeed about a software generating paragraph length description. The article gives a few example outputs. It's not yet human like but getting there.

<comment><USER2> Yeah. They are pretty clearly baseline systems, designed to set a benchmark for whatever comes next.</comment></comment></comment>


The Mach Loop Experience - <AUTHOR> http://blog.planeimages.net/the-mach-loop-experience/ <comment><USER2> Truly gorgeous imagery and formatting. Kind of sad to think many will experience this on a mobile device. These images really same alive on my big old monitor : )</comment>


Cybersecurity Skills: Vital Role in These 10 Tech Jobs - <AUTHOR> https://insights.dice.com/2019/12/16/cybersecurity-skills-vital-role-in-these-10-tech-jobs/ <comment><USER2> When are we gonna do away with the mag stripe?

I would think enough people have the chip that those who refuse to get a card with a chip should accept their consequences.</comment>


Your programming language is probably unproductive - <AUTHOR> http://bart-sokol.info/blog/2016/09-18-your-programming-language-is-probably-unproductive/index.html <comment><USER3> > The introduction of braces in the code was a trigger for a number of > religious wars, and it made us, developers, focus on the design of the > language instead of focusing on the most important thing in our work - > solving real problems.

How can you correctly solve problems without being able to look at your code and reason, instantly, about what is grouped together. Let alone tracing through your code but just seeing what statements are grouped with what.

One such suggestion, as provided by the author, is whitespace.

I can't tell you how bad of an idea this is. Just from a teaching perspective. I help tutor for CS100 at my university and a large part of the errors I have to deal with are whitespace errors. People don't understand where a block starts and ends. It's less key strokes but that doesn't mean it's easier or better.

> Languages like Java and C# made it to the almost ridiculous point where not > only we have to be very explicit about every aspect of our code, but also > made us split this code into an endless amount of files

I see no issue with splitting up a problem into multiple parts that, if sufficiently different, could be hidden from each other.

In the end, I don't think a language can be (un)productive. A language is the means for expressing a solution. Your job as a programmer is to conceive a solution to a problem and pick a language that will best let you express that problem.

Some times functional languages are better at this, some times other languages are better. The thing we should be arguing about is what is best expressed in which language.

<comment><USER4> I started a project out using jade in nodejs, after a while I had a page with enough elements/nesting going on that I was having a hard time keeping track of what was grouped where. Particularly when taking some work a designer did, making it jade compliant, then pasting in.

Aside from a short "if" statement, I now no longer think it's sexy to abandon ending notation whether it be braces, elements, etc.

<comment><USER3> I'd suggest you not leave if statements un-braced. I remember a study where they found the most common bug in most experienced open source developers was leaving out the braced initially, going back to make a change, and having that change introduce a bug.

Basically they had

       if (x)
          then()

and went back and did

       if (x)
          new_call()
          then()

and caused an error that happened silently.

This is something you definitely want to avoid and I personally don't trust myself, after a no-sleep code fixing bender, to remember to add {} around something if I'm editing an if. I'd probably forget.

Again, I'd say shorter does not mean better.

<comment><USER5> One way round this is to put single statement ifs on a single line:

        if (x) then();

If you add another statement to the if, its obvious from the indent that you need to use braces.

<comment><USER6> Yup, I _always_ do this when writing JavaScript or other languages that allow prefix single statements with or without braces. Otherwise I use braces if the statement is too long to fit in the editor w/o forcing you to scroll. Perl only allows postfixed single statements w/o braces, so you're safe:

        say "yes" if $condition;
        if ($condition) {
            say "yes";
            $affirmative++;
        }

</comment></comment></comment></comment></comment><comment><USER7> What is it about programming that just causes people to constantly bash languages they don't use?

<comment><USER8> When a person learns a language, they are making an investment of sorts - <USER2> are saying "I think this is a language that I will invest time into learning because ...". That "..." is usually (unfortunately) "it is becoming more popular and I will have a competitive edge being familiar with it before others". The bashing of other people's languages is a way of either (1) rooting for what you're invested in or (2) reassuring yourself you made a good investment.

</comment></comment><comment><USER9> I think one of the most impressive things I ever saw was at a programming competition while I was in college. I was paired with a suspenders and graybeard and we needed to optimize the brute forcing of a password. He opened a hex editor and kicked out some SPARC assembly that was many times faster than what I was doing in Bash. Lesson: You can be productive anywhere.

Here's the thing when it comes to language design: Define a single way to do something. Yes, be politically incorrect and realize you might hurt some people's feelings if you make braces mandatory. Or make them close their tags on HTML. But in the end, what you're adding is simplicity: The arguments move from "you don't write code the way I do" to other more important things.

</comment><comment><USER10> blah blah blah. clickbait title, same old complaints about language syntax that doesn't agree with someone's personal preference, etc...

Some people like braces, like me. It doesn't matter at the beginning/middle of a code block much, but the clearly visible terminating } is what does it for me. I need that.

If every whitespace significant language had __strict __formatting standards, shipped with a formatting utility (e.g. gofmt), and actually enforced formatting standards everywhere (including stuff like number of empty lines between functions, etc...), then I would be on board with no braces and whitespace significance. Until then, the inconsistencies you run in to in whitespace significant land just don 't work for my brain.

Then, some people hate braces and love whitespace significance. Cool. doesn't matter. the end.

<comment><USER11> I've been using a language that uses python-style indentation (Nim) and while I've grown to like to like the language itself, the back of my mind pines for braces. At least using braces, I can immediately auto-indent a region of code and not have to worry about anything. I sucked it up, though, and I got used to the pythonic syntax anyway.

Either way, opening an article that says "Your programming language is probably unproductive" which immediately devotes itself to whining over pedantic syntax bullshit...makes me not want to read it.

</comment></comment><comment><USER12> I program in embedded C, you don't have to tell me it's 'unproductive'. It's just convenient and familiar.

A while ago I started writing something about _meter_ in programming languages; what could we gain by thinking not just about making them look more like English but more able to be read aloud? I didn't come to any useful conclusions, but I do note that of all the unpronouncable symbols we use the semantic whitespace of python is the most difficult to convey adequately.

<comment><USER13> >what could we gain by thinking not just about making them look more like English but more able to be read aloud?

I wouldn't be in favor of a programming language that tried to enforce verbalizability (I'm thinking something like basic here). But I do think that having a program "tell a story" is a boon for comprehension. Have operations, variable names, function names, choice of where and when to use a function, etc be in such a way to optimize the narrative quality of the code. But I don't immediately see a way for the language construction itself to benefit here. I think having clear structural code is a boon to quickly scanning and understanding the structure of code.

<comment><USER12> Mm. Taking literate programming literally. Perl certainly tried to do this, Wall being a linguist. It resulted in things like the Perl fridge poetry set, but it didn't _enforce_ it and also allowed a line noise style.

</comment></comment></comment><comment><USER14> Counterpoint to the remarks about braces and partial application:

Implicit partial application is a poor idea that makes programs incomprehensible. If you pass only three arguments to a four-argument function foo, you should see a "foo: insufficient arguments" error, and not a function of one argument popping out.

The _semantics_ of obtaining a partially applied function doesn't depend on syntax. It can work fine when function arguments are delimited by parentheses. For instance, suppose that if we write (cons 3) we automatically get the equivalent of (lambda (x) (cons 3 x)). That's partial application, with parens. We can then do (mapcar (cons 0) '(1 2 3)) and get ((0 . 1) (0 . 2) (0 . 3)). Is that a good idea? Firstly, we lose variadic functions and functions with optional arguments. (list 0) can't return a lambda; it already has a meaning; (list) produces the empty list, (list x) a list of one element which is the value of x, and so on. We could end up with an embarrassing proliferation of fixed arity functions like list1, list2 and list3.

It's not that much of a chore to have an _explicit partial application operator_ : Say:

       (op list)     -> (lambda (. args) (apply list args))

       (op list _ 1) -> (lambda (arg) (list arg 1))

If that is too verbose, and used often, we can dedicate alternative closure punctuators to it:

       {list}        ->  (op list)

       {list _ 1}    ->  (op list _ 1)

So braces now help with partial application, enabling it when we want it. The notation keeps code crystal clear because everything is delimited. We know that (op foo 1 2 3) or {foo 1 2 3} partially applies exactly three arguments to foo, no more or less, and we know that (foo 1 2 3) calls foo with exactly three arguments.

</comment><comment><USER15> tl:dr: personal preferences about visual style in coding.

</comment><comment><USER16> Productivity isn't a subjective quality, it's a measurable quantity. Without measurements, you're just bikeshedding.

</comment><comment><USER17> I think we should go back to LISP/Scheme, the only language that supports whatever you want, how you want it and when you want it while still being functional.

Tho admittedly, most LISP libraries tend to strive for the same age as LISP itself, as it looks.

<comment><USER18> There's a whole bunch of more modern lisps than Common Lisp, such as Racket and Clojure

<comment><USER17> I don't find either to be a very attractive alternative, Common Lisp just has that kind of ... air around it.

Although I admit that Clojure is a decent language.

</comment></comment></comment><comment><USER19> I don't like C-like languages. Prefer pascal/python. In delimiters think is far better "begin _or_ do /end" than "{}", but mainly because if you have keywords like "if, while, for" then switch to symbol then switch again is "ugly". I think symbols are for data structures or math or operators, not keywords. key...WORDS. That is.

However apart for that, and also dislike the use of space and implicit type. I use F# and like it, except for how ambiguous is for a lot of things.

What is the point of have a super-strong type engine and when you look at:

let getProductById repository id

You still need to use intelli-sense or check the code as with dynamic languages? If I'm into a static typing, I wanna fully use it.

When I see:

getProductById repository id

Type inference _defeat me_ as a user: The computer know what that is, yet, is _hidden_ from me. Not much different than in dynamic languages. Ah, you can annotate it if want! But then you break the language convention. Is bad to let the user decide, because then everyone will decide, but different.

So, I think is better in a type-static language to annotate the types, all the time. Because that is how the language really is, and is the way to unlock the benefit of better documentation/clarity that is one of the benefits of static type.

This is my main gripe with F#/OCalm.

Also apply code require gymnastic because something is unclear in a secuence:

let result = getId code save result bla bla

When things start or end?. And F# have let fun = and let fun()= both things different. This create a compile time bomb where call some effect trigger before things are ready.

In short: have a way to group and mark blocks is great. Python is closer to how do things with space/indentation. \-----

 _Syntax is very important_. I don't dismiss it like other people that think is just "sugar".

Syntax is _our_ user-interface. When is closer to what the language is, better.

<comment><USER20> > So, I think is better in a type-static language to annotate the types, all > the time.

I agree. ((int)((int) 5) + ((int) 5)) - ((int)2) is way clearer than 5 + 5 - 2.

<comment><USER19> Is well understood that that apply to function/classes/types, etc.. not the non-sense example you pick.

And by the way, a + b + c is not more clear than Int + Int + Int... or sum(customer, products) vs. sum(Customer, ProductArray)

<comment><USER20> My real point was that it's a spectrum. Type information should go where it clarifies and should not go where it obscures.

We should omit the type from intermediate expressions when (and only when!) it will be sufficiently clear from context and it does not serve as a clearer specification of intent than your terms. I contend that this is not a special property of expressions.

<comment><USER19> Then we agree ;)

</comment></comment></comment></comment></comment><comment><USER21> I find this kind of logic to be a common problem among people designing programming languages. It's an interface to talk to a machine, it's not really a toy to play with. And for any good interface the goal is to make sure people have to think as little as possible, learn as little as possible new things and be able to predict behaviors easily. It doesn't matter whether you like braces or not, we have them, they are predictable, no one has to learn them again. Anything else would force thinking and learning and ultimately cannot be a better choice for decades ahead.

<comment><USER22> We have a few models and they all seem to work fine.

</comment></comment><comment><USER23> Apparently unproductive == has curly braces.

</comment><comment><USER24> Placing braces in their own lines, using optional braces and not inlining short ifs are almost always styling choices, not programming language faults. The "simple example" is ridiculously biased.

</comment><comment><USER25> I'm wondering if this guy ever had to maintain other people's code or work with a large code base. IMO readability trumps a lot of these points.

<comment><USER22> Arguably, braces make it harder to read code because you can have misleading whitespace. But I mean, this is what linters and formatters are for.

</comment></comment><comment><USER26> I don't think the complaint about braces is looking at the right issue.

The issue with braces is that many languages allow multiple lines and indentation _when there are no braces_. If languages _required_ you to either say "if (foo) bar()" ON ONE LINE _or_ use braces, 99.2% of all the issues would disappear. Heck, I'd be in favor of a new C17 standard just to add this restriction.

</comment><comment><USER27> For small programs, dynamic, runtime tag checked languages as pioneered by LISP are great environments! (Python, Ruby, JavaScript, Smalltalk, PHP, ...)

For large programs, making the computer instantly tell you where you remembered wrong is more important (like Haskell, as well as Pascal, C++, Java, C#, etc.)

By comparison, small syntactic differences fade into the background noise. This is not news.

</comment><comment><USER28> I beg to differ, Mr. Sokol -- I use LOLCODE.

</comment><comment><USER29> In the example provided under "White space", I find the first (9-line "bad") example _significantly_ better than the 3-line replacement.

I can see in a fraction of a second what the first one does. The second one? 3-4 seconds to be about 85% sure I know what it's doing, and about 6-10 to be certain.

</comment><comment><USER30> Actually his example has noise in both cases. Compare that to Lua's:

        return id > 0 and repository:get(id)

Also in C you can #define maybe(cond, ptr) ((cond)?(ptr):NULL) macro and use it everywhere.

</comment><comment><USER31> I personally find python to be the sweet spot for me with all of its libraries and syntax. I use other languages when I need to squeeze every drop of performance from some hardware.

<comment><USER32> For some performance, check out the Boo language. I got hooked up on it for quite a while. Python syntax + .Net platform and rich meta-programming = lots of fun.

<comment><USER10> a couple jobs ago, for some reason we used boo, in an otherwise 100% c# .net project, to manage our IoC/Dependency injection configuration layer.

I still have no idea why.

</comment></comment></comment><comment><USER33> So functional programming seems to be the bleeding edge programming paradigm that hackers seem to agree on.

What other paradigms are highly regarded among hackers?

<comment><USER34> > What other paradigms are highly regarded among hackers?

None, but hybrid object functional languages have been on the rise in recent years (though, like FP based languages, still very much niche). See Scala, Ceylon, OCaml, among others.

Language functionality aside, multi-target is the next great wave. For example, came across this today[1], pretty awesome -- compiles to server-side, client-side, and native!

Would be quite nice to write-once run literally everywhere with a single language, but that looks to be a couple of years off (if there are production ready tri-target languages out there, I'd like to check them out).

[1] [https://github.com/mkotsbak/scala-native-tellstick- example/t...](https://github.com/mkotsbak/scala-native-tellstick- example/tree/crossProjectWithSJS)

</comment></comment><comment><USER35> elegant =/= productive .

Granted F# is backed by .NET so it has access to a large existing ecosystem (on Windows) which makes it fairly productive ... once it has been learned.</comment>