414 stories
·
2 followers

Saturday Morning Breakfast Cereal - Escape

1 Comment and 4 Shares


Click here to go see the bonus panel!

Hovertext:
I originally had a hamster but that seemed mean.


Today's News:
Read the whole story
GaryBIshop
1 day ago
reply
Ha!
Share this story
Delete

Saturday Morning Breakfast Cereal - Knowing

1 Comment and 4 Shares


Click here to go see the bonus panel!

Hovertext:
Look the fact that there's a misspelling in the votey panel just makes the point more strong.


Today's News:
Read the whole story
GaryBIshop
14 days ago
reply
I don't know shit and people like me are running the world!
Share this story
Delete

Why I Use Elm in 2023

1 Comment

elm mario example code

elm debugger

If you look at some of my recent projects, you’ll notice I enjoy building lean websites with pure HTML+CSS.

But building UIs in HTML+CSS can be untenable. When making complex frontend experiences, I reach for Elm. Here’s why:

  1. community packages that work
  2. great performance
  3. solid tooling
  4. minimal cognitive overhead
  5. extreme predictability
  6. fearless refactoring
  7. incredible API design

7. Community Packages That Work

Modern web development seems hellish for some organizations.

For the past 10 years, I’ve watched teams struggle against NPM packages. I’ve been part of multiple migrations between moment.js, Luxon, and day.js. React applications drown in state management libraries that perpetually break something important. And don’t get me started on React hooks.

Every package on NPM seems (1) inundated with breaking changes or (2) completely abandoned. Codebase upgrades are terrifying after your team finds the perfect package.lock that works for everybody.

The poor quality of NPM also leaks into the devops-side of frontend. Every Webpack/Babel/Vite/EsBuild/Parcel ecosystem feels like a delicate mess on stilts. I’ve witness countless engineering hours wasted on JS source maps, polyfills, and build errors.

Outside of React, the situation seems equally bleak. Frontend frameworks in JS, Python, Elixir, etc. look riddled with similar quality problems. There’s a lot of software out there, so please email me if there are any ecosystems I should reconsider.

Elm’s packages are generally well-documented, focused, appropriately named, and bug-free. But don’t take my word for it – pick any of these packages at random and see the quality for yourself:

6. Great Performance

This piece from Rakuten matches my own experiences with Elm:

  • The performances of Elm applications are among the fastest. Internally Elm uses the concept of a virtual DOM, similar to React. The speed of the Elm virtual DOM is comparable to Svelte, which uses a different mechanism to update the DOM.
  • The Elm compiler produces smaller assets compared to other frameworks. Among the various optimizations to achieve this result, there is the dead code elimination with granularity to the single function that works across the entire ecosystem. If you import a large package and use only one of the functions contained, the compiler will ensure that only that function ends up in your generated code.
  • The Elm compiler per se is also fast. Our bigger codebase contains ~66,500 lines of Elm code, and it compiles incrementally in 0.3 seconds and from scratch in 2.5 seconds.

I want to add that Elm’s virtual DOM will obviously be strictly worse than an equivalent optimized vanilla JS program. But for modern browsers, Elm seems to offer the best balance of developer ergonomics and runtime speed.

Writing Elm in Neovim is wonderful. Everything feels snappy regardless of file sizes: types hints, tests, errors, autoformatting, and recompilation.

Thanks to the speedy and simple Elm compiler, I can keep my tooling extremely simple during development. Here’s my entire live webdev setup:

http-server dist \
& watch -p "**/*.elm" -c "elm make src/Main.elm --debug --output=dist/elm.js"

Debugging is straightforward. When my code behaves strangely, I use Elm’s time-travelling debugger to inspect the model at each state-change. From there, pure functions make errors obvious.

4. Minimal Cognitive Overhead

Most languages are too powerful for my palate.

Don’t get me wrong – I love Rust and many other languages! But sometimes they’re just too much for me.

When writing Rust or JS or Haskell or Python or Lisp, I’m overwhelmed by opportunity. Should I make this generic? Should I use classes or structs? Immutable or mutable? Macros? Functional or imperative array manipulation?

I try to please compilers and coworkers and customers, but all are disappointed. Give me a woodshop and I’m lost, but give me a simple chisel and I intuitively know what to do. There’s a certain freedom in restricted toolsets.

Languages like Go and Elm spurn extravagance. They resist overcomplication. They force me to solve real problems instead of fighting compiler errors and stylistic differences.

Furthermore, consistent code makes portable mental-models. Go and Elm codebases tend to be extremely readable.

3. Extreme Predictability

I like shiny new features and predictability.

Unfortunately, there are tradeoffs. For compiler teams, bug-hunting steals time from feature-development.

I can live with landmines if they don’t change positions. Releasing patches reduces predictability. If a bug has a known workaround, I want the devs to focus all efforts on their next release instead of old errors.

But I’m also a patient person who loves ambitious visions. I would rather wait years for tightly-integrated featuresets than months for haphazard improvements.

Elm 0.19.1 has been the latest version since 2019. I’ve heard rumors of some new stuff coming in 2023, which is super exciting, but 0.19.1 remains wonderfully stable. I’ll be happy with future releases as long as they’re predictable, holistically designed, and relatively infrequent.

2. Fearless Refactoring

When it comes to building software, my first guesses are generally wrong.

In most languages, changing things is a brutal process. I tend to live with my mistakes because refactoring is too tiresome.

With Elm, I experiment and change everything with little resistance. As long as I watch wildcard matches in my case statements, the compiler quickly guides me back to a working program from any change.

Theoretically, all static type systems should be able to do this, but they just don’t. I don’t know why, but my major changes in Haskell/Rust/Go always end up with unintended results. Elm’s error messages are really in a class of their own, and it has nothing to do with pretty formatting.

1. Incredible API Design

Elm’s mental models made me a better programmer.

If you haven’t already, take some time to browse Elm’s 1st-party libraries: core, html, json, browser, url, http, bytes, file, parser, random, regex, and time.

All the main libraries contain gems. They’re easy yet strict; simple yet powerful.

For example, consider the parser library. Parser pipelines are delightful to use, and teach you to think in terms of non-backtracking flows. When you’re ready, you can upgrade to Parser.Advanced for extra contextual powers, but the complexity doesn’t get in the way when you don’t need it.

Even if you never seriously use Elm, study its libraries and build some toys with them. There’s plenty of wisdom to glean from its careful design.

Adblock test (Why?)

Read the whole story
GaryBIshop
14 days ago
reply
He makes me want to look at Elm.
Share this story
Delete

The Great Ptolemaic Smackdown: From Plausible to Proven (2013)

1 Comment

Previously: Part 8, Trial and Error

From Plausible to Proven

 
The great dishonesty of Galileo’s Dialogue was to present a contest between the Copernican and Ptolemaic models.  By that time, both had been smacked down and the real contest was between the Tychonic/Ursine models and Kepler’s model, with the Ursine model being “ahead on points.”  Galileo did not mention either one. He regarded the Tychonic/Ursine models as unaesthetic and klunky.  He seems to have regarded Kepler's model, which came annexed to a physics in which the Sun put out a mysterious force that chivvied the planets about, as occultism.  Besides, he was committed to perfect Platonic circles, and Kepler had ellipticated them.  Boo. 

Galileo’s book “proved popular amongst literati who were not astronomers [and] who enjoyed his very obvious polemic writing skills; but contrary to popular opinion it didn’t play a significant role in the contemporary scientific discussion.”  (Christie, Galileo’s great bluff 2010)  One could even make an argument that Galileo managed to delay acceptance, although TOF does not do so.

What it came down to is that the issue would not be settled by astronomical mathematics, but by a new physics.

Please Help Me, I'm Falling....


The objections to geomobility on the part of the physicists were manifold, but because the old physics is gone, Patient Reader will blink in astonishment at some of the objections and a little thought-balloon reading WTF? will form over his or her noggin.  For example, heavy bodies will in the common course of nature fall toward the center of the world.  If the Sun were in the center of the world, cannon balls dropped from the tower of Pisa would fly off toward the Sun; but we see that they do not, therefore etc.  Us Moderns in our wisdom are left scratching our collective heads and saying Really?

Other objections made more sense, in that we can understand why people would have raised them.

Those headwinds sure are strong!
  • If the world is turning at a high rate toward the east, why is there no steady breeze coming from the east?  This is a sort of ancient Michelson-Morley experiment.  
  • If the earth is whipping around the sun, why isn't the Moon left behind?  (Or the oceans and the atmosphere?)  

Of course, there were answers to these, even then.  "Common motion" asserts that the air shares the earth's rotation, and therefore there would be no particular east wind.  And the moons of Jupiter showed that, whether we knew why or not, moons are not left behind as their planet moves. 
As the earth revolves, the relative positions of the stars
should change
  • If the earth were whipping around the sun, we should see parallax among the fixed stars, but do not.  The Copernicans answered, "Well, yeah, but maybe the stars aren't just far away but really really far away."  But you cannot save an unproven hypothesis by asserting a second unproven hypothesis.  The stars had to be relatively close because otherwise their observed diameters would mean they were ginormous entities. Some Copernicans embraced this and said "Goddidit!"  Who cared how enormous the stars were, since God was infinite.  
As the earth turns a ball at the top of the
tower has a greater eastward velocity
and will fall east of the plumb line
  • If the earth were rotating, objects at the top of a tower would have a greater eastward motion than those at the bottom of the tower; and therefore, a dropped object would not only fall but move eastward realtive to the tower.  No such deflection is observed.  "Well, yeah," said the Copernicans, "it's probably a really small deflection that falls within the error of measurement." 
Maybe so, but science is supposed to be more rigorous than a dorm bull session.  It's not enough to concoct a plausible story.  Sooner or later, there has to be empirical evidence that the story is true.  And this evidence cannot be the same evidence that was used to concoct the story in the first place!

The problem of history, John Lukacs used to tell us is that we "must consider the battle of Salamis as if the Persians might still win."  Meaning that you want to understand what happens in 1633, you can't consider things learned in 1687 or 1803.  The mid-17th century had no clear concept of inertia, of gravitation, of forces, etc.; and while ontologically there may still be no clear concept of these (and therefore we are blind to the foolishness over which our descendents will one day mock us) the same is certainly true of 380 years ago.  After all, the classical, medieval, and Renaissance folks laughed at the ancient belief that the world was flat.  (The Chinese at this point still did believe.)  But because Aristotle had demonstrated that the world was a sphere, the Scriptural passages describing the sky as a tent pitched over a flat earth were no longer understood as literal. 

What was needed now was a new theory of motion.

Just Dropped in to See What Condition My Condition was in

A new theory of motion was already in development.  Aristotle had declared that heavier bodies would fall faster than lighter bodies.  But Albrecht of Saxony described a thought experiment in the 14th century in which he imagined two equal-sized falling bodies attached by a string, and then mentally cutting the string.  It was absurd to imagine the two separate bodies would suddenly decelerate to half speed.  Thomas Bradwardine and the Merton Calculators proved the Mean Speed Theorem and described the free fall of bodies.  Doubts about Aristotle's physics began to circulate.  
1543  Benedetto Varchi publishes a book listing experimental evidence from Francesco Beato and Luca Ghini contradicting Aristotle's view of free fall.

1544  Domingo de Soto, a Dominican philosopher, publishes a book with the first correct statement of the law of free fall.

1570  In Opus novum de proportionibus, Girolamo Cardano, demonstrates that two balls of different sizes will fall from a great height at the same time.

1574 Girolamo Borro, one of Galileo's teachers, describes experiments repeated several times where a wooden and lead ball were thrown out of a high window and the wooden ball reached the ground first.

1575  Guiseppe Moletti, Galileo's predecessor at University of Padua, drops balls of the same volume but different materials and of the same material but different weights and discovers they hit ground at same time.

1585  Flemish Scientist Simon Stevin conducts an experiment dropping two balls, one weighing 10 times the other from 30 feet and discovers that they reach ground at same time.

Aristotelian physics was tottering well before Galileo took up a sledge hammer.

1632.  Bonaventura Cavalieri publishes Specchio Ustoria (On Burning Mirrors).  Otherwise a book about mirrors, it's the first book to describe the parabolic nature of projectile motion. Both Thomas Harriot and Galileo Galilei had described this motion before Cavalieri, but in private notes never published.  Well, Harriot never published nothing, but Galileo was not one for staying mum.  Projectile motion does not sound very heliocentric, but folks are creeping up on a calculus of motion.  For all practical purposes, up to now mathematics basically consists of arithmetic and geometry, with geometry having pride of place.  No wonder Aristotle thought mathematics was unsuited to physics, which involved changeable matter.

Meanwhile, Back at the Glass...

Late 1632.  Leander Bandtius, Abbot of Dunisburgh, (and owner of a particularly fine telescope)  notes a large red spot on Jupiter. 

1636.   In Harmonie Universelle, Fr. Marin Mersenne diagrams the construction of reflecting telescopes in configurations similar to the Gregorian and Cassegrain telescopes.  Parabolic mirrors are notoriously difficult to grind.  Can we say "Hubble Space Telescope"? 

1637.   Galileo Galilei publishes Dialogues Concerning Two New Sciences.  The two sciences are strength of materials, in which he describes the square-cube law, and the physics of motion, in which he confirms De Soto's law and Bradwardine's medieval observations.  He even uses Nicole d'Oresme's graphical geometric proof of the Mean Speed Theorem.  Without attribution, of course.  (The Wikipedia article contains several infelicities.)

Technically, Galileo had been forbidden to publish any new works; but he started writing this while under house arrest in the palace of Archbishop Piccolomini and had arranged for Elsevier to print it in the Netherlands.  The same three characters carry on the dialogue here as in his previous work, but curiously, Simplicio is no longer presented as a stubborn and foolish dork.  (TOF wonders if this was a sort of peace offering to He Who Must Not Be Compared to a Simpleton.)  No one came after Galileo for publishing a new work, so this may simply be an example of the old Renaissance game of official severity coupled with practical leniency.


JeremiahHorrocks.jpg
Jerry Horrocks spots Venus; forgets to tell
anyone else.
4 Dec 1639*.  Jeremiah Horrocks makes the first recorded observation of a transit of Venus from his home near Preston, England.  Horrocks has corrected Kepler's calculations for Venus' orbit and realizes that transits of Venus occur in pairs 8 years apart.  Kepler had predicted a near miss transits for 1639 but Horrocks correction predicts a full-fledged, no-foolin', straight-up Venusian transit.  He has it pegged for 3:00 pm, more or less, the more-or-less part being tricky.  Also, the day is cloudy.  But, shazaam!  The clouds clear at 3:15 pm.  He calculates the size of Venus from the dot in his projected image and from it estimates the Astronomical Unit (mean distance between the Earth and the Sun). He's wrong of course, but he is less wrong than anyone previously.  Then -- wait for it -- true to the great tradition of Harriot, his results will not be published until 1661, after his death.  What is it with those English?
(*) 24 November under the Julian calendar then in use in England.
Francesco Maria Grimaldi.jpg
Grimaldi
alt
Riccioli
1640.  Jesuits Francesco Maria Grimaldi and Giovanni Battista Riccioli drop weights from the Torre di Asinelli in Bologna and times the fall using a pendulum. From this he calculates the acceleration due to gravity (g) as 9.144 m/s².  (The modern value is 9.80665 m/s².  Both men have craters named for them on the Moon for the excellent reason that they were the ones who named the lunar craters.
alt
View straight down from the Torre di Asinelli
12 Mar 1641.  In a letter dated, March 13, 1641, Vincenzo Renieri, a professor at the University of Pisa, reports to Galileo on experiments he conducted the day before in which he dropped balls from the Tower of Pisa.  Renieri is an Olivetan monk, an order co-founded by one of the Piccolominis of Siena, and it was at Archbishop Piccolomini's palace that Renieri met Galileo (1633).  When Galileo dies next year, he will leave all his unfinished scientific work for Renieri to complete; but Renieri himself will die shortly after (1647).  Galileo's friend and biographer, Vincenzo Viviani, also a friend of Renieri, will ascribe the Tower of Pisa experiment to his master, starting a legend that lives to this day.

8 Jan 1642.  Galileo goes off to that great observatory in the sky.  Urban's animus pursues him, and will not permit the Archbishop of Florence to bury him in the cathedral as proposed.  Geez, can't he let bygonesbe bygones?

29 July 1644.  Urban VIII finishes his bucket list and kicks off.  Everything is much quieter now. 

{{{image_alt}}}
I got an idea!  Let's replace wars of dynasties with
wars of nationalism!  Then things will be peaceful!
15 May 1648.  The Peace of Münster is signed, finally ending the Spanish-Dutch portion of the Thirty Years War. 
24 Oct 1648.  The Treaties of Münster and Osnabrück are signed, ending the rest of the Thirty Years War: between the Empire and France and the Empire and Sweden, resp.  But during the peace conference...
All those weeks, all those days, all those last futile hours, they had been fighting at Prague, and went on fighting for nine days longer before they, too, had news of the peace.  Then they, too, fired their salvo to the skies, sang their Te Deum and rang their church bells because the war was over. 

Almost all -- one excepts the King of Sweden -- were actuated rather by fear than by lust of conquest or passion of faith.  They wanted peace and they fought for thirty years to be sure of it.  They did not learn then, and have not since, that war breeds only war.
-- C.V. Wedgwood, The Thirty Years War
alt
Tychonic and Copernican systems argue
on the frontispiece to the New Almagest
while Ptolemy lies prostrate crying
"I will rise again!"

1651. Riccioli publishes his masterwork Almagestum novum. In one section, he presents both major theories -- Copernican and Tychonic -- and gives arguments for and against each one: 
  • 49 arguments in favor of Copernicanism, with rebuttals to each, and 
  • 77 arguments against Copernicanism, with rebuttals to each.   
This is the book Galileo was supposed to write, weighing the pros and cons.  Contrary to popular belief, Riccioli did not simply count the number of arguments, since they were of unequal weight; nor did he decide on the Tychonic model for religious reasons.  Rather, he emphasizes the need for sensible [empirical] evidence as the deciding factor. 
“Both sides present good arguments as point and counter-point. Religious arguments play a minor role in the debate; careful, reproducible experiments a major role.  To Riccioli, the anti-Copernican arguments carry the greater weight, on the basis of a few key arguments against which the Copernicans have no good response.  …  Given the available scientific knowledge in 1651, a geo-heliocentric hypothesis clearly had real strength, but Riccioli presents it as merely the “least absurd” available model…” 
(Graney, 126 Arguments Concerning the Motion of the Earth 2011.)
alt
You are here.  Riccioli's lunar map.
Actually, you are not here; but you once were
The “key arguments against which the Copernicans had no good response” are the lack of parallax and Coriolis effects.  Graney states, “Today, a new theory which predicts observable effects that are not observed, while requiring the ad hoc creation of an unprecedented new type of object [gigantic stars], would have limited appeal, even were it mathematically elegant.”  The Tychonic model fit the data better.  It predicted all the same phenomena as the Copernican, plus it explained why there was no visible parallax or Coriolis.

Unlike Galileo's Dialogue, which was a polemic written for the public, and like Scheiner's Rosa Ursina, Riccioli's New Almagest was a dense, scientific and mathematical tome written for scientists.  It remained a standard text into the 18th century.  In it, Riccioli also reports the value of g for gravitational acceleration, gives the geography of the moon*, shows that bodies do not fall at the same rate,** et al. He gave detailed descriptions of the experiments so that anyone who wished could duplicate them.

(*) geography of the moon. The New Almagest has the first detailed lunar map, with the sea and crater names that we still use.  Riccioli named craters for Copernicus and his followers and for Tycho and Ptolemy and their followers, acknowledging in this offhand manner the collegial and cumulative nature of science.  
(**) do not fall at the same rate.  If two heavy objects of differing weight are dropped simultaneously from the same height, the heavier one descends more quickly provided it is of equal or greater density.  If both bodies are of equal weight, the denser one drops more quickly.  Air resistance does matter.
Christiaan Huygens.jpg
Chris Huygens
1655.  Christian Huygens builds the most powerful telescope ever and  spots a bright moon in orbit around Saturn, which he calls “Saturni Luna.” (In 1847 John Herschel will decide to name it Titan. 

1659.  Huygens studies Saturn some more and discovered the true shape of the planet’s rings. Galileo and others with less powerful telescopes had thought the rings were love handles

The 1660s.  Nearly 120 years after heliocentrism had been formally proposed, Kepler’s elliptical model has won the contest.   The astronomical community has accepted the ellipses with nary a murmur and the Third Law with positive glee.  However, the Second Law (the Equal Area law) is rejected as ugly and Kepler’s proof is deficient.  But the Rudolphine Tables are just plain easier to use.  In the Platonic Renaissance, that carries weight.

There is a long-standing tension between Aristotelians and Platonists over the nature of mathematical physics.  The issue is whether something is true simply because the mathematical model is elegant and "works."  To the Platonists, the mathematics can be more real than the physics. We see that today in the reliance on complex computer models, in which the model output is sometimes, amazingly enough, called "data."  So the Keplerian model was accepted because it was so damn elegant it had to be true and if we keep the faith, sooner or later we'll find the data.  But as Einstein once said to Heisenberg, "Theory determines what can be observed." 
alt
A chronology of Chronos. 
1665.  Riccioli publishes Astronomia Reformata (Reformed Astronomy), a condensed and updated version of the New Almagest.   It incorporates Keplerian ellipses into the Tychonic model.  It includes reports on Bandtius' observation of the Great Red Spot, on the Jovian cloud belts disappearing and reappearing, on the appearance of Saturn's rings from time to time. 

1672. Nicolas Mercator develops a correct mathematical derivation of Kepler's Second Law.  (Christie, Galileo’s great bluff 2010)

1687. Newton presents his theory of Universal Gravitation.  It’s hard for the Late Modern to grasp what a stunning achievement this is.  Suddenly, everything makes sense!  He does not use calculus to do this.  The Principia is carefully structured in correct Aristotelian form, with axioms and deductive logic, to ensure that is true scientia.  There is one elegant solution to all the planets, to all the motions!  Kepler's laws can be deduced from the principle.  Finally, a simple, elegant reason why Kepler’s model ought to be true! 

Just one problem; or rather two:
•    There is still no @#^$% parallax. 
•    There is still no *#^%$ Coriolis effect. 

Dang!  But we can’t let inconvenient facts get in the way of a really kool theory. 

alt Fat lady finally sings! 

By this time everybody supposes that stellar parallax is simply too small to detect, but there is not yet any empirical evidence that the stars lie at the enormous distances required. 

The lack of Coriolis is more troubling.  Even though a rotating Earth had been more easily accepted than a revolving Earth, the rotation is still undetected.  Newton had described an experiment – dropping a musket ball from a tower – and Hooke had carried it out.  But he reported finding no deflection.

Then comes something really unexpected. 

How aiming a telescope is like running in the rain with an umbrella
If the earth is moving, the telescope will move during the
time light from a star travels down the tube.  Thus you have
to tilt the tube a little bit.

1728.  Building on efforts by Flamsteed, Hooke, and others attempting to detect that old bugaboo, parallax, James Bradley detects stellar aberration in γ-Draconis (Phil. Trans. Royal Soc., 1729).

A similar phenomenon appears when you drive through a snow storm.  Even though the snow is falling straight down, it appears to originate at some point forward of your car.  This is because as snow falls, your car is moving toward the snow.  Similarly, as the starlight falls down the telescope tube, the telescope tube is moving with the earth and the light ray will hit the side of the tube instead of the eyepiece unless the telescope is tilted slightly.  

The effect is small, and detectable only with special instruments, but it counts as a proof that the Earth is moving.  

Huzzah!  Sorta.  It may not convince non-specialists, however.  

1734.  Bradley’s paper is translated into Italian

1744.  A "corrected" copy of Galileo's Dialogue is printed in Italy.  Not a word is changed, but the term "if" is inserted in various marginal topic headers.  This would have been all that was necessary had the original recommendation of the extensor been followed in the Galileo trial.

1758.  Copernicanism is removed from the Index.  Stellar aberration seems to have been sufficient.  

altJun-Sep, 1791.  In a series of experiments, Giovanni Guglielmini, a professor of mathematics at the University of Bologna, drops weights from the Torre dei Asinelli in Bologna -- the same tower used earlier by Riccioli and Grimaldi -- and finds an eastward (and southward) deflection.  Concerned with windage, he repeats the experiment down the center of the spiral staircase at the Instituto della Scienze and finds a 4 mm Coriolis deflection over a 29 m drop; thus providing direct empirical evidence of the rotation of the Earth.  These experiments are later confirmed in Germany (using a mine shaft) and in the United States.

1806.  Giuseppi Calandrelli, director of the observatory at the Roman College publishes "Ozzervatione e riflessione sulla paralasse annua dall’alfa della Lira," reporting parallax in α-Lyrae.  This provides a simple direct observation of the revolution of the Earth. 

Zeus: I've got a splitting headache!
Courtier: Uh... Got wimmin on yer mind?
Keplerian heliocentrism had been accepted because it was computationally easier and because it popped out mathematically from Newton’s theory like Athena from the brow of Zeus.  But now, finally, 263 years after Copernicus, the dual motions are established by empirical fact.  Hot diggity. 

1820.  Giuseppe Settele, astronomy professor at the Sapienza (now the University of Rome) incorporates these findings into the second volume of his Elementa di Ottica e di Astronomia, and tells his colleague, Benedetto Olivieri (who is then Commissary of the Holy Office) that this provides the demonstration requested by Bellarmino back in 1616.  Olivieri agrees, and convinces the Office and Pope Pius VII.

12 Aug 1820.  The injunction is lifted in light of the astronomical discoveries made since Galileo's time:

Decree of Approval for the work "Elements of Astronomy" by Giuseppe Settele, in support of the heliocentric system
The Assessor of the Holy Office has referred the request of Giuseppe Settele, Professor of Optics and Astronomy at La Sapienza University, regarding permission to publish his work Elements of Astronomy in which he espouses the common opinion of the astronomers of our time regarding the earth’s daily and yearly motions, to His Holiness through Divine Providence, Pope Pius VII. Previously, His Holiness had referred this request to the Supreme Sacred Congregation and concurrently to the consideration of the Most Eminent and Most Reverend General Cardinal Inquisitor. His Holiness has decreed that no obstacles exist for those who sustain Copernicus’ affirmation regarding the earth’s movement in the manner in which it is affirmed today, even by Catholic authors. He has, moreover, suggested the insertion of several notations into this work, aimed at demonstrating that the above mentioned affirmation [of Copernicus], as it is has come to be understood, does not present any difficulties; difficulties that existed in times past, prior to the subsequent astronomical observations that have now occurred. [Pope Pius VII] has also recommended that the implementation [of these decisions] be given to the Cardinal Secretary of the Supreme Sacred Congregation and Master of the Sacred Apostolic Palace. He is now appointed the task of bringing to an end any concerns and criticisms regarding the printing of this book, and, at the same time, ensuring that in the future, regarding the publication of such works, permission is sought from the Cardinal Vicar whose signature will not be given without the authorization of the Superior of his Order.
Original Latin source: W. Brandmüller and E.J. Greipl, eds., Copernicus, Galileo, and the Church: The End of the Controversy (1820), Acts of the Holy Office (Florence: Leo Olschki, 1992), pp. 300-301.
 The imprimatur was granted in 1820 and the ban on teaching heliocentrism as proven fact was lifted.

That’s a long time to hold out for empirical confirmation.  

Aside: The Crucial Role of Galileo. 

There was none.  Every discovery made by Galileo was made by someone else at pretty much the same time.  Marius discovered the moons of Jupiter one day later.  Scheiner made a detailed study of the sunspots earlier than Galileo.  The phases of Venus were noted by Lembo and others.  And so on.  Even his more valuable work in mechanics duplicated the work of De Soto, Stevins, and others.  Matters would have proceeded differently -- certainly with less fuss and feathers -- and some conclusions may have taken longer, or perhaps shorter times to achieve.  The thing is, science does not depend upon any single individual.  No one is "the father of" any particular theory or practice.  As Newton observed, he stood upon the shoulders of giants -- a sentiment expressed by Bernard of Chartres back in the Early Middle Ages!  Regarding heliocentrism, Galileo's biggest accomplishment was to get some folks so riled up that the conversation was inhibited for a short time in some quarters.

HISTORY MUST BE CURVED, for there is a horizon in the affairs of mankind.  Beyond this horizon, events pass out of historical consciousness and into myth.  Accounts are shortened, complexities sloughed off, analogous figures fused, traditions “abraded into anecdotes.”  Real people become culture heroes: archetypical beings performing iconic deeds.  (Vansina 1985)

In oral societies this horizon lies typically at eighty years; but historical consciousness endures longer in literate societies, and the horizon may fall as far back as three centuries.  Arthur, a late 5th cent. war leader, had become by the time of Charlemagne the subject of an elaborate story cycle.  Three centuries later, troubadours had done the same to Charlemagne himself.  History had slipped over the horizon and become the stuff of legend.

In AD 778, a Basque war party ambushed the Carolingian rear guard (Annales regni francorum).  Forty years later, Einhard, a minister of Charlemagne, mentioned “Roland, prefect of the Breton Marches” among those killed (“Hruodlandus Brittannici limitis praefectus,” Vita karoli magni).  But by 1098, Roland had become a “paladin” and the central character,  the Basques had become Saracens, and a magic horn and tale of treachery had been added (La chanson de Roland).  Compare the parallel fate of a Hopi narrative regarding a Navajo ambush (Vansina, pp. 19-20). 
This suggests that 17th century history has for the bulk of the population already become myth.  Jamestown is reduced to “Pocahontas,” and Massachusetts boils down to “the First Thanksgiving.”  And the story of how heliocentrism replaced geocentrism has become a Genesis Myth, in which a culture-hero performs iconic deeds that affirm the rightness of Our Modern World-view. 

Conclusion: Our ancestors were not fools. 

In three centuries, the long complex story of how the mobile Earth replaced the stationary Earth dipped below the horizon from History into Legend.  Like all good legends, the story of heliocentrism and the culture-hero Galileo is simple and general and geared toward supporting the Rightness of the Modern worldview.  But history is always detailed and particular.

The reasons for the stationary Earth were rooted in empirical experience and successful modeling.  The dual motion of the Earth is not sensibly evident and was difficult to establish on empirical grounds.  Heliocentrism triumphed first of all because Neoplatonic number mysticism had become au courant during the Renaissance, and Platonists equated mathematical elegance with physical evidence.

Resistance to heliocentrism was rooted in the science of the day and religion entered the picture mainly because the Church Fathers had interpreted Scripture in the light of that science.  They weren’t about to change until there was solid evidence that the science (and hence the interpretation) was wrong; not in the middle of no honkin' Reformation they weren’t.  Thomas Huxley said after investigating the affair that “the Church had the better case.” But Pierre Duhem put it differently.  The Copernicans were “right for the wrong reasons.”  The Ptolemaics were “wrong for the right reasons.”

Science doesn’t follow a mythic positivist ideal but the plural scientific methods described by Feyerabend: a mixture of empiricism, flights of fancy, intuition, aesthetics, doggedness, and jealousy.  Scientific theories are underdetermined.  Any finite set of facts can support multiple theories, and for a long time the available facts were equally explained by geostationary or geomobile models.

In the Legend, the conflict was between Science and Religion.  But in the History, the conflict was between two groups of scientists, with churchmen lined up on all sides.  Copernicanism was supported by humanist literati and opposed by Aristotelian physicists; so it was a mixed bag all around. 
Science does not take place in a bubble.  International and domestic politics and individual personalities roil the pot as well.  The mystery is not why Galileo failed to triumph – he didn’t have good evidence, made enemies of his friends, and stepped into a political minefield.  The real mystery is why Kepler, who actually had the correct solution, constantly flew under the radar.  A deviant Lutheran working in a Catholic monarchy, he pushed Copernicanism as strongly as Galileo; but no one hassled him over it.  Too bad he couldn’t write his way out of a paper bag.

TOF doffs

The end.  Thank goodness.  We now return you to your regularly scheduled blog.  

References

  1. Aristotle. On the Heavens
  2. Aslaksen, Helmer.  Myths about the Copernican Revolution   
  3. Bellarmino, Roberto (1615) Letter to Foscarini 
  4. Blackwell, Richard J.  Behind the Scenes at Galileo's Trial.  University of Notre Dame Press, 2006
  5. Chastek, James.  (2006)  The givenness of the proper sensibles  
  6. Christie, Thony.  The Renaissance Mathematicus.  A treasure trove!  Some items used:
  7. Christie, Thony.  (2013)  The speed of light, a spin off from longitude research.
    Christie, Thony.  (2011)  A small spot in front of the sun, a small step down the road to heliocentricity.  Christie, Thony. But it doesn’t move! June 22, 2011.
    Christie, Thony. Extracting the Stopper. June 2, 2010.
    Christie, Thony. Galileo’s great bluff. Nov. 12, 2010.
    Christie, Thony (2011) Spotting the Spots
    Christie, Thony (2011) Questions on spots
    Christie, Thony (2013) He didn’t publish and so he perished (historically).
    Christie, Thony (2013) Apelles hiding behind the painting
    Christie, Thony (2009) Astronomy and Astrology.
    Christie, Thony (2013) Refusing to look
  8. Copernicus, Nicholas; Charles Wallis (trans). On the Revolutions of the Heavenly Spheres
  9. Crombie, A. C. Medieval and Early Modern Science, vol. II. Garden City, NU: Doubleday Anchor, 1959.
  10. D'Addio, Mario. The Galileo Case: Trial, Science, Truth.  Gracewing Publishing, 2004
  11. De Santillana, Giorgio. The Crime of Galileo. Chicago: University of Chicago Press, 1955.
  12. Duhem, Pierre. (1892)  Some reflections on the subject of physical theories in Essays in the History and Philosophy of Science (ed. Roger Ariew and Peter Barker)
  13. Franklin, James.  "The Renaissance Myth"  Quadrant 26 (11) (Nov. 1982), pp. 51-60
  14. The Galilean Library.  Non-Intellectual Contexts.  
  15. The Galileo Project.  Chronology
  16. Galileo's sunspot letters to Mark Welser
  17. Gigli, Rossella. (1995)  Galileo's Theory of the Tides 
  18. Graney, Christopher M. 126 Arguments Concerning the Motion of the Earth. Mar. 14, 2011. 
  19. Graney, Christopher M. Tycho was a scientist, not a blunderer. Mar. 6, 2012.
  20. Huff, Toby. Intellectual Curiosity and the Scientific Revolution. Cambridge: Cambridge University Press, 2011.
  21. Lindberg, David C. (ed). Science in the Middle Ages. Chicago: University of Chicago Press, 1978.
  22. Lindberg, David C. and Ronald L. Numbers (eds.).  God and Nature: Historical Essays on the Encounter Between Christianity and Science.  University of California Press, 1986
  23. Linder, Douglas.  The Trial of Galileo
  24. Mayer, Thomas F.  (ed.) The Trial of Galileo, 1612-1633.  University of Toronto Press, 2012  (includes translations of basic documents in the case; a textbook for law)
  25. Oresme, Nicholas. On the Book of the Heavens and the World by Aristotle. Feb. 1999.  (accessed April 4, 2012).
  26. Osiander, Andreas.  Foreword to Copernicus' Revolutionibus.  unsigned.
  27. Palmieri, Paolo.  Re-examining Galileo’s Theory of Tides.  Arch. Hist. Exact Sci. 53 (1998) 223–375
  28. Peters, Edward. Inquisition University of California Press, 1989
  29. Ptolemy, Claudius. Syntaxis Mathematiké. In The Great Books Series. Chicago: Encyclopedia Britannica/Univ. of Chicago, 1952.
  30. Rowland, Wade. Galileo's Mistake. New York: Arcade Publishing, 2003.
  31. Sant, Joseph (2012). Jesuits and the Early Telescope:Scheiner and Grienberger.
  32. Sant, Joseph (2012). Timeline of the telescope.
  33. Sant, Joseph (2012). Timeline of mechanics.
  34. Sharratt, Michael. (1994)  Galileo: Decisive Innovator 
  35. Shea, William R. & Mariano Artigas. Galileo in Rome. Oxford: Oxford University Press, 2003.
  36. Shea, William R. & Mariano Artigas.  The Galileo Affair.  A short summary of previous, with slides.
  37. TOF (2011).  The Far Seeing Looking Glass Goes to China
  38. Vansina, Jan. Oral Tradition as History. Madison: University of Wisconsin Press, 1985.
  39. Wallace, William A. The Modeling of Nature. Washington, DC: Catholic University of America Press, 1996.
  40. Wedgwood, C.V. (1938, 1995) The Thirty Years War. (Book of the Month Club reprint)
  41. plus sundry Wikipedia biographies and topic pages, to be used with caution.

Adblock test (Why?)

Read the whole story
GaryBIshop
22 days ago
reply
Very interesting reading.
Share this story
Delete

The Wrong Abstraction

1 Comment

_I originally wrote the following for my Chainline Newsletter, but I continue to get tweets about this idea, so I'm re-publishing the article here on my blog. This version has been lightly edited._


I've been thinking about the consequences of the "wrong abstraction." My RailsConf 2014 "all the little things" talk included a section where I asserted:

duplication is far cheaper than the wrong abstraction

And in the summary, I went on to advise:

prefer duplication over the wrong abstraction

This small section of a much bigger talk invoked a surprisingly strong reaction. A few folks suggested that I had lost my mind, but many more expressed sentiments along the lines of:

The strength of the reaction made me realize just how widespread and intractable the "wrong abstraction" problem is. I started asking questions and came to see the following pattern:

  1. Programmer A sees duplication.

  2. Programmer A extracts duplication and gives it a name.

    This creates a new abstraction. It could be a new method, or perhaps even a new class.

  3. Programmer A replaces the duplication with the new abstraction.

    Ah, the code is perfect. Programmer A trots happily away.

  4. Time passes.

  5. A new requirement appears for which the current abstraction is almost perfect.

  6. Programmer B gets tasked to implement this requirement.

    Programmer B feels honor-bound to retain the existing abstraction, but since isn't exactly the same for every case, they alter the code to take a parameter, and then add logic to conditionally do the right thing based on the value of that parameter.

    What was once a universal abstraction now behaves differently for different cases.

  7. Another new requirement arrives.
    Programmer X.
    Another additional parameter.
    Another new conditional.
    Loop until code becomes incomprehensible.

  8. You appear in the story about here, and your life takes a dramatic turn for the worse.

Existing code exerts a powerful influence. Its very presence argues that it is both correct and necessary. We know that code represents effort expended, and we are very motivated to preserve the value of this effort. And, unfortunately, the sad truth is that the more complicated and incomprehensible the code, i.e. the deeper the investment in creating it, the more we feel pressure to retain it (the "sunk cost fallacy"). It's as if our unconscious tell us "Goodness, that's so confusing, it must have taken ages to get right. Surely it's really, really important. It would be a sin to let all that effort go to waste."

When you appear in this story in step 8 above, this pressure may compel you to proceed forward, that is, to implement the new requirement by changing the existing code. Attempting to do so, however, is brutal. The code no longer represents a single, common abstraction, but has instead become a condition-laden procedure which interleaves a number of vaguely associated ideas. It is hard to understand and easy to break.

If you find yourself in this situation, resist being driven by sunk costs. When dealing with the wrong abstraction, the fastest way forward is back. Do the following:

  1. Re-introduce duplication by inlining the abstracted code back into every caller.
  2. Within each caller, use the parameters being passed to determine the subset of the inlined code that this specific caller executes.
  3. Delete the bits that aren't needed for this particular caller.

This removes both the abstraction and the conditionals, and reduces each caller to only the code it needs. When you rewind decisions in this way, it's common to find that although each caller ostensibly invoked a shared abstraction, the code they were running was fairly unique. Once you completely remove the old abstraction you can start anew, re-isolating duplication and re-extracting abstractions.

I've seen problems where folks were trying valiantly to move forward with the wrong abstraction, but having very little success. Adding new features was incredibly hard, and each success further complicated the code, which made adding the next feature even harder. When they altered their point of view from "I must preserve our investment in this code" to "This code made sense for a while, but perhaps we've learned all we can from it," and gave themselves permission to re-think their abstractions in light of current requirements, everything got easier. Once they inlined the code, the path forward became obvious, and adding new features become faster and easier.

The moral of this story? Don't get trapped by the sunk cost fallacy. If you find yourself passing parameters and adding conditional paths through shared code, the abstraction is incorrect. It may have been right to begin with, but that day has passed. Once an abstraction is proved wrong the best strategy is to re-introduce duplication and let it show you what's right. Although it occasionally makes sense to accumulate a few conditionals to gain insight into what's going on, you'll suffer less pain if you abandon the wrong abstraction sooner rather than later.

When the abstraction is wrong, the fastest way forward is back. This is not retreat, it's advance in a better direction. Do it. You'll improve your own life, and the lives of all who follow.

News: 99 Bottles of OOP in JS, PHP, and Ruby!

The 2nd Edition of 99 Bottles of OOP has been released!

The 2nd Edition contains 3 new chapters and is about 50% longer than the 1st. Also, because 99 Bottles of OOP is about object-oriented design in general rather than any specific language, this time around we created separate books that are technically identical, but use different programming languages for the examples.

99 Bottles of OOP is currently available in Ruby, JavaScript, and PHP versions, and beer and milk beverages. It's delivered in epub, kepub, mobi and pdf formats. This results in six different books and (3x2x4) 24 possible downloads; all unique, yet still the same. One purchase gives you rights to download any or all.

Adblock test (Why?)

Read the whole story
GaryBIshop
24 days ago
reply
He's so right.
Share this story
Delete

Gen Tojo’s Teeth: Morse Code Shows Up in the Strangest Places

1 Comment

The Baader-Meinhof effect is the common name for what scientists call frequency illusion. Suppose you are watching Star Trek’s Christopher Pike explain how he makes pasta mama, and you’ve never heard of it before. Immediately after that, you’ll hear about pasta mama repeatedly. You’ll see it on menus. Someone at work will talk about having it at Hugo’s. Here’s the thing. Pasta mama was there all along (and, by the way, delicious). You just started noticing it. We sometimes wonder if that’s the deal with Morse code. Once you know it, it seems to show up everywhere.

Gen. Hideki Tojo in custody in 1947

One of the strangest places we’ve ever heard of Morse code appearing is the infamous case of Tojo’s teeth. If you don’t remember, General Hideki Tojo was one of the main “bad guys” in the Pacific part of World War II. In particular, he is thought to have approved the attack on Pearl Harbor, which started the American involvement in the war globally. Turns out, Tojo would be inextricably tied to Morse code, but he probably didn’t realize it.

The Honorable Attempt

At the end of the war, the US military had a list of people they wanted to try, and Tojo was near the top of their list of 40 top-level officials. As prime minister of Japan, he had ordered the attack that brought the US into the war. He remained prime minister until 1944, when he resigned, but the US had painted him as the face of the Japanese enemy. Often shown in caricature along with Hitler and Mussolini, Tojo was the face of the Japanese war machine to most Americans.

In Allied propaganda, Tojo was one of the “big three”

When Americans tried to arrest him, though, he shot himself. However, his suicide attempt failed. Reportedly, he apologized to the American medics who resuscitated him for failing to kill himself. Held in Sugamo Prison awaiting a trial, he requested a dentist to make him a new set of dentures so he could speak clearly during the trial.

A Morse Code Dentist

Jack Mallory, a young Navy dentist on loan to the Army, drew the duty of making Tojo’s new dentures. The 22-year-old had been at the 361st Station Hospital for about a month. His roommate, George Foster, had examined Tojo and brought Jack in to make an upper denture. Tojo had declined a full set because he did not expect to survive his trial.

Jack’s roommate, George Foster, is seen with an unknown soldier examining Tojo.

The standard procedure was to engrave the patient’s name, rank, and serial number of any dentures made by the hospital. However, Mallory’s colleague suggested that it would be fitting to engrave Tojo’s with the common phrase “REMEMBER PEARL HARBOR.” At 22, you are often susceptible to bad ideas, but Jack knew that could get him in trouble. But he decided to do it any way but to make it less conspicuous, he used — you guessed it — Morse code.

At first, only Jack and his roommate knew the secret. However, two recruits had to be let into the secret because they were examining the dentures and were sure to notice. One of them wrote home about the incident, and, as you might expect, the military command was not amused. Mallory’s commanding officer ordered him to remove the markings, which he did, and everyone denied it ever happened. As far as anyone knows, Tojo never knew that his dentures had carried a secret message.

General Tojo’s trial didn’t go well for him, and he was executed late in 1948. Jack had been back in the states for over a year, reuniting with his wife and starting a dental practice. The story would only surface again years later, in 1995.

Code is Everywhere

Of course, soldiers have a long history of using Morse code to communicate secretly, like Admiral Denton blinking “torture” during his appearance in a propaganda film made by his captors during the Vietnam war. The Colombian army encoded secret messages to captive soldiers in a pop song.

Even civilian songs get into the act. There are a ton of songs that have some Morse code embedded in them, ranging from London Calling by the Clash to YYZ by Rush and many others. The Capitol Records building sends out Morse code, although it seems most people don’t notice. Not many people realize that the beat of the theme music to Mission Impossible actually spells out MI, either.

Then there’s the Curiosity Mars rover. The wheels on that plucky vehicle leave the letters JPL in Morse code behind in the sand. However, our pet peeve these days is the “morse code bracelets” that use beads to spell out messages like “loved.” Why is that a pet peeve? Becuase there is no spacing between elements, so, for example, loved is “.-..—…-.-..” Of course, that could also be “aumski” or a bunch of other nonsense words.

As you can see, once you know Morse code, you can find it just about everywhere. You might even find it in your dreams. Too lazy to learn the code? Take the Blue Pill.

Read the whole story
GaryBIshop
46 days ago
reply
cool story.
Share this story
Delete
Next Page of Stories