frontpage.
newsnewestaskshowjobs

Open Source @Github

fp.

Open in hackernews

Matrix and Quaternion FAQ

https://j3d.org/matrix_faq/matrfaq_latest.html
20•signa11•9h ago

Comments

xeonmc•2h ago
The formulas provided for quat to matrix and quat to axis angle is terrible, they only work if the quaternion's magnitude is exactly one. You need to replace sqrt(1 - a*a) assumptions with actual components, and use atan2 instead of acos. I don't blame the author though because the vast majority of info you can find in online learning materials uses this ill-advised formulation, including Wikipedia. But it's really trivial to realize this fact if you just go ahead and derive from the quat sandwich from first principles and realize that the "convenience simplification assuming unit quat" is actually an unnecessary step that have no benefits and are wholly detrimental when implementing them for floating point numbers.
DarkUranium•2h ago
Also, I really think we'd all be better off if we stopped using quaternions entirely and started using rotors instead.
BigTTYGothGF•14m ago
They're pretty much the same thing except in one of them you say "i, j, k" and in the other you say "e12, e13, e23".
esperent•2h ago
> they only work if the quaternion's magnitude is exactly one

That's why you always normalize the quaternion first, and the article seems to require the normalized form:

Q.54 How do I convert a quaternion to a rotation matrix?

Assuming that a quaternion has been created in the form:

Q = |X Y Z W|

At least, I would read |X Y Z W| as meaning normalized(X Y Z W)

I don't see this notation explicitly defined when they describe quaternion normalization (Q.52) though, so I agree this leaves much out. It's more a cheat sheet than learning material.

> You need to replace sqrt(1 - a*a) assumptions with actual components, and use atan2 instead of acos

I'm kind of rusty with this, but I think the reason we don't do that is that it's cheaper to normalize then convert rather than use the non-normalized conversion formula. Correct me if I'm wrong.

fsloth•24m ago
If you need this stuff in production I recommend getting a good computer graphics textbook.

These cheat sheets are convenient _if you already know what you are doing_ and _are confident the cheat sheet uses same presentation as your problem domain_.

That said I'm not sure if there is a nice book that would be both exact and practical at the same time.

Unlimited OCR: One-Shot Long-Horizon Parsing

https://github.com/baidu/Unlimited-OCR
170•ingve•2h ago•48 comments

Steam Machine launches today

https://store.steampowered.com/news/group/45479024/view/685257114654870245
1759•theschwa•21h ago•1494 comments

Elevated error rate across multiple models

https://status.claude.com/incidents/jbhf20wjmzrf
13•rob•6m ago•2 comments

Plotnine

https://plotnine.org/
137•tosh•4d ago•36 comments

Will It Mythos?

https://swelljoe.com/post/will-it-mythos/
224•mindingnever•10h ago•150 comments

MSG Made Dossier on Activists Who Opposed Facial Recognition

https://www.404media.co/madison-square-garden-made-dossier-on-activists-who-opposed-facial-recogn...
27•cdrnsf•50m ago•0 comments

GLM-5.2 – How to Run Locally

https://unsloth.ai/docs/models/glm-5.2
482•TechTechTech•17h ago•225 comments

Crypto in 2026: Oh, This Is the Bad Place

https://www.stephendiehl.com/posts/bad_place_2026/
207•ibobev•4h ago•216 comments

Epidurals are a miracle technology

https://worksinprogress.co/issue/the-wonder-of-epidurals/
42•karakoram•2d ago•22 comments

Spying on kids to save kids from spying is stupid

https://pluralistic.net/2026/06/23/destroy-the-village/
20•hn_acker•21m ago•3 comments

VibeThinker: 3B param model that beats Opus 4.5 on reasoning with novel SFT+GRPO

https://arxiv.org/abs/2606.16140
279•timhigins•12h ago•134 comments

The Traditional Vi

https://ex-vi.sourceforge.net/
41•exvi•5h ago•25 comments

In praise of memcached

https://jchri.st/blog/in-praise-of-memcached/
215•j03b•13h ago•83 comments

Show HN: Neural Particle Automata

https://selforg-npa.github.io/
46•esychology•5h ago•12 comments

Show HN: Shumai – open-source Frame.io alternative for creative work

https://github.com/shumaiOne/shumai
23•Yiling-J•4h ago•0 comments

Apple is going to raise device prices, but when?

https://daringfireball.net/linked/2026/06/22/apple-device-prices-when
53•tosh•3h ago•38 comments

Giant Banana Pulled Over: Driver Says Cops Have Stopped Him 100s of Times

https://cowboystatedaily.com/2026/06/18/giant-banana-pulled-over-in-montana-driver-says-cops-have...
115•speckx•2d ago•28 comments

The Coming Loop

https://lucumr.pocoo.org/2026/6/23/the-coming-loop/
115•ingve•3h ago•103 comments

You already have a Git server

https://gopeek-lovat.vercel.app/blog-you-already-have-a-git-server.html
19•sheelagay•4h ago•6 comments

8086 Segmented Memory was a good idea

https://owl.billpg.com/8086-segmented-memory-was-a-good-idea-almost/
44•billpg•2d ago•76 comments

OpenAI DayBreak – GPT-5.5-Cyber

https://openai.com/index/daybreak-securing-the-world/
153•AaronO•12h ago•118 comments

Researchers used math to crack Wordle

https://www.binghamton.edu/news/story/6327/s-m-a-r-t-these-researchers-used-math-to-crack-wordle
7•hhs•2d ago•1 comments

My Mathematical Regression

https://blog.dahl.dev/posts/my-mathematical-regression/
333•aleda145•4d ago•130 comments

Oracle shed about 20k roles globally in the last year

https://www.bbc.com/news/articles/c4gy0x0j5deo
82•Lyngbakr•2h ago•84 comments

Optocam Zero: a Pi Zero based digital camera made using off the shelf components

https://github.com/dorukkumkumoglu/optocamzero
203•iamnothere•19h ago•52 comments

An Introduction to YOLO26

https://blog.roboflow.com/yolo26/
88•teleforce•12h ago•31 comments

Moebius: 0.2B image inpainting model with 10B-level performance

https://hustvl.github.io/Moebius/
305•DSemba•1d ago•77 comments

Who Does What? Team Topologies for the Agentic Platform

https://blog.owulveryck.info/2026/06/22/who-does-what-team-topologies-for-the-agentic-platform.html
35•owulveryck•9h ago•21 comments

Kyber (YC W23) Is Hiring a Head of Engineering

https://www.ycombinator.com/companies/kyber/jobs/FGmI8mx-head-of-engineering
1•asontha•17h ago

The new HTTP QUERY method explained

https://kreya.app/blog/new-http-query-method-explained/
187•CommonGuy•8h ago•133 comments