Hacker Newsnew | past | comments | ask | show | jobs | submit | Evidlo's commentslogin

Nice try, Google!

Why can't the polyfill be enabled by default? It would fix the security issues and we wouldn't have to worry about breaking websites.

The JS polyfill also makes supporting modern XSLT feasible.


I tried the JS polyfill on some of the basic XSLT that I wrote, and it only kinda worked. I can't imagine how it would fail on anything with any complexity.


The videos were restored, though...


Pretty easy. Just a scoop of whey.


Why does the cursor flicker around the screen for most of these? Does it have something to do with not double buffering the display?


Some artifact from asciinema maybe. Only shows up in the preview gifs. Needs to be fixed!


Was thinking about vectorizing these and using a pen plotter to make some cool art for my wall, but the images are not very high resolution, unfortunately :(


Would be nice to have a demo on the page that lets you change the SVG interactively with radio buttons


One may attach JavaScript onClick action Listeners to any SVG named object (see attributes menu in inkscape.) For security reasons, this trick only works on live web server pages, and can't be run off the local file systems in most browsers.

While I would never allow uploading SVG formats to a public server... a vector format is great for line art style interface. =3


Thanks for the suggestions I will modify the demo


Why is there an in-flight internet bypass blog post every year, but they never mention Iodine?


Anyone else feel like the pendulum motion seems off? Maybe the default mass settings are weird, but the movement just does not look physical to me.


It's way off. My first guess was that there was something wrong with the physics code, but after carefully checking against this[1] derivation of the Hamiltonian it seemed fine, and once I wrapped my head around the JavaScript the RK4 integration[2] checked out as well.

So, what else might be wrong I wondered. Well, it seems to move in the wrong direction... so I checked how the pendulum is displayed. And sure enough, I think there's a sign error:

  getUpperBob() {
     const { x0, y0, ang0, l0 } = this;
     const { x, y } = this.calculateBobPosition(x0, y0, ang0, l0);
     return { x, y };
   }

   getLowerBob() {
     const upperBobPos = this.getUpperBob();
     const { ang1, l1 } = this;
     const { x, y } = this.calculateBobPosition(
    upperBobPos.x,
    upperBobPos.y,
    -ang1,
    l1
     );
     return { x, y };
   }
Note how the upper bob uses ang0 while the lower one has -ang1. Meanwhile the physics derivation assumes both angles are against the vertical, so have same sign.

Changing -ang1 to ang1 does indeed make the pendulum move in a natural way, except now dragging it is flipped. Ie you drag it left and it moves right. Another sign error in setLowerBobPos. Fixing that as well it now works as I'd expect.

[1]: https://dassencio.org/46

[2]: https://lpsa.swarthmore.edu/NumInt/NumIntFourth.html##sectio...


Just made a PR


I considered it, but had to go to work and I figured since the last commit was over 4 years ago it might just sit there idly, so I skipped it.

But no, PR was merged in short order. Lesson learned.


Hn shows this story is 3 hours old, yet your GitHub PR was made 2 days ago, linking here?


The story has been reposted to HN via the “second-chance pool”, which resets the dates.

https://news.ycombinator.com/item?id=26998308


There's a "How To Use?" section on the GitHub repo page.

https://github.com/theabbie/DoublePendulum?tab=readme-ov-fil...


Yep, it's just bad. Physics feels totally off.


Yes I think the physics is wrong


When you bring up the lower mass and let it go, it seems to push the upper mass away, which should never happen. This whole site smells off vibe coded jank.


I don't think that's fair. Also the project is 4 years old so the timeline doesn't really work out for being vibe-coded.


> This whole site smells off vibe coded jank.

A vibe-coded double pendulum sim should produce a much better result than the physics on this page. Claude Code made this just now off one prompt, the physics are much better: https://keir.is/swinging


Just start going through your accounts gradually over several years and you won't experience much friction.


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: