Why do I feel like I’m being sold on some kind of mathematical cult?
@kungfooman
3 жыл бұрын
Because it looks fancy in ganja.js :^)
@nissimhadar
3 жыл бұрын
Do you think he is wrong?
@yabgu79
3 жыл бұрын
I feel like it is intentionally obfuscated too. Geometric (Clifford) algebra is really so much better and easier to understand it cannot be a coincidence it is this hidden while videos like these exist: kzitem.info/news/bejne/xWp7zZadjZ9hdZw and they always use sentences as such: "See this figure is called linelander (I see myself there), his mind is so simple he cannot understand 4d concepts bla bla bla......". Isn't it too common these words used to be a coincidence? "You cannot understand because you are like line 2d lander trying to understand 3d while we demigods can grasp 4d space and all the magic...". Well... How about now; After watching this video I completely understand what 3d rotation is, so who was accusing me of being a simpleton...
@marctenbosch
3 жыл бұрын
I think the real cult is the quaternion guys 😂 since the real cult is always the other guys 😂. Seriously though, my sense is that it started with Hamilton and how he really wanted quaternions to contain 3D vectors (when in fact they contain bivectors) and trying to convince everyone of that, that we still feel the ripples today. If you're interested, look up the articles on the history at the end of the article: marctenbosch.com/quaternions/#history
@maxwellsequation4887
3 жыл бұрын
@@marctenbosch Hmmmm it feels there is going to be crusades soon.....
@AndrewJonkers
3 жыл бұрын
Very nice. I had the same questions about quaternions that you did regarding dimensionality.
@renexmachina
3 жыл бұрын
i didn't really understand anything despite a background in videogame graphics, but i feel like my efforts avoiding quaternions all these years have been justified.
@Sh-hg8kf
3 жыл бұрын
As a beginner planning to learn 3d graphics, same XD. Hopefully I can understand this soon enough
@SteinCodes
3 жыл бұрын
Clear up your head rewatch it from the outer product part. It will flow quite well. I had started watching the video with too much bias because of the title so had a lot of issues in understanding on first attempt it's extremely simple. Basically your cross product gives you a perpendicular vector which adds complexity while you can avoid it by simply using a bivector instead which is an outer product. Outer product of same vectors is 0 is an base identity of it, and allows to build other identities required for implementation. 3D bivectors are slightly confusing as they need understanding of plane projection to get their components but the essence is all the same. But here computer is doing the maths so it's not a concern. Otherwise bivectors are the same as cross product in equations just use basis planes instead. The best part though is the fact that they can scale infinitely(bi - tri - quad), it's part of multivector algebra. And truth be told I knew about it to some extent just never thought of using it. Search Wikipedia for Multivector and Clifford Algebra on internet.
@Sh-hg8kf
3 жыл бұрын
@@SteinCodes What level of math background does one need to understand this video and the topic at hand in your opinion?
@SteinCodes
3 жыл бұрын
@@Sh-hg8kf Whatever level I am at, so around a little more than High School. Or a few years of experience writing/working game engine rendering source. For the purpose of brevity anyone who graduated with Maths as a subject in college.
@Sh-hg8kf
3 жыл бұрын
@@SteinCodes How would one tackle this prior to finishing high school math? Linear algebra was barely taught here, with a brief explanation of matrices, steps of matrice multiplication given without intuition and determinants to give a perspective. Any stuff I should cover on top of these (I am a bit decent with the multiplication intuition now)? Since our syllabuses might be diff, idk how much stuff matches up. Also, wait, if a engine dev with years of experience can understand this, most normal starting-out game devs would find this hard and thus not have to implement stuff like this and quaternions?
@dakotapearl0
3 жыл бұрын
Really interesting! It's like quaternions are a simplification of this concept. What I'm trying to figure out is if the implementation of rotors in a 3D game engine can be as efficient as quaternions. How much information needs to be stored for each rotation and how many operations need to be done per rotation?
@nzuckman
3 жыл бұрын
Quaternions are an even subalgebra of the Cl(3) geometric algebra - if you throw out the vectors and trivectors, you're left with scalars and bivectors whose algebra is exactly the same as the quaternions. They contain the same information, although a geometric algebra has *slightly* more overhead because it has the vectors and trivectors too - however, the intuitive understanding gained from this is well worth it.
@petrowi
4 жыл бұрын
I'm very eager to see these 4D rotations and movement in Miagakure, is it coming out?
@jonathancapps1103
3 жыл бұрын
@1:40 The way I understand it n-dimensional rotation pretty much always has smoother rotation interpolation in n+1 dimensions I remember understanding the explanation of why when I read it, but that was almost 20 years ago.
@oivinf
3 жыл бұрын
Perhaps weirdly, I find quaternions to be much more intuitive than this. Sure, having to multiply from both "sides" to preserve the projection might seem strange conceptually, but once you get an understanding of why it's happening it' not much of a problem. Another nice thing about quaternions that is very intuitive is that you can apply a rotation around any axis by defining the axis as a normal 3D vector and then construct the following: cos(angle) + sin(angle) * (xi + yj + zk) where x,y,z is your axis as a 3D vector.
@marctenbosch
3 жыл бұрын
It's the same for rotors.
@adamz8314
3 жыл бұрын
angle should divide by 2,for me when i used quaternions ,i see them as black box and this was big problem.
@plus-sign
3 жыл бұрын
For rotors in Geometric Algebra, it is just (cos (a/2) + B sin (a/2)) v (cos (a/2) - B sin (a/2)), where B is the plane of rotation and v is your geometric object (can be vector, point, blade, flat, sphere, etc.). It's similar to quarternions yet it can be used in any dimensions. If you're to stick with 3D, then I suppose quarternions are enough. GA implementations are a bit slower.
@Hampardo
3 жыл бұрын
Mmmm your video makes me want to learn differential geometry so bad.
@HilbertXVI
3 жыл бұрын
Why don't you? It's so cool
@stevedixon921
3 жыл бұрын
Conceptually, staying out of the 4th dimension is a good idea. That said, there needs to be a computational advantage to using Rotors to incentivize replacement of Quaternions within the software realm. If the compute cost is identical, it will be a near impossible challenge, but if it can yield immediate tangible gains it could be adopted quickly. If the API would need to be altered it would be an even greater challenge to implement.
@Sandromatic
3 жыл бұрын
It's identical. I mean, quaternion i,j,and k, are almost literally the exact same thing as the basis planes xy, yz, and xz, from memory, and work as a drop-in replacement there.
@RGD2k
3 жыл бұрын
There is, go watch kzitem.info/news/bejne/uJB31oWhfXSjaKQ
@blinded6502
2 жыл бұрын
Quaternions are rotors. A dumbed down version of rotors, that is explained in absolutely incorrect way. Rotors themselves can be easily interpolated with absolutely no bugs in their behavior. And rotors can encode not only rotations, but also translations. And you can easily create rotors, that take you from one orientation to another one with a single tiny formula.
@msergejev
2 жыл бұрын
Comment on 7:30, components of a bi-vector: aren't bi-vectors something of a "directional" surface, that contain also a information about the direction of rotation rather then just area of the surface? Is this information then contained in the individual contributions in the unit bi-vectors?
@marctenbosch
Жыл бұрын
Sorry for the late reply: yes, for example, you can see (earlier in the video) how in 2D I change the color of the bivector from blue to green when the rotation goes from clockwise to anti-clockwise. It is a "signed" area. In 3D you would have to multiply all three bivector components by -1 to represent the opposite rotation, just like negating a vector, which is equivalent to -(a^b) = b^a
@tobiaszb
3 жыл бұрын
A new perspective! ...or projection and reflection.
@blinded6502
2 жыл бұрын
You only need a reflection though
@ihato8535
3 жыл бұрын
wtf why are there no more videos??
@Troynjk
Жыл бұрын
Question: How many degrees of freedom an object can manifest at the same time? For example, a sphere is spinning clockwise and moving forward at the same time, i.e. it’s using 2 out of 6 degrees of freedom, can it have more?
@angeldude101
Жыл бұрын
In N-dimensions, there are N choose 2 degrees of freedom in choosing an axis of rotation, but a given rotation can have up to floor(N/2) distinct axes being rotated around at once. In your example, representing translation as a kind of rotation requires an extra projective dimension, so it acts like 4D in this case, with 6 degrees of freedom for choosing an axis, and 2 distinct axes that it's rotating around, one for spinning around its center, and one acting as an "axis of translation." Since floor(4/2) = 2, any subsequent rotations you try to add will just change the two existing axes rather than add any new ones.
@Troynjk
Жыл бұрын
@@angeldude101 so the maximum is 2? Only 2 can be engaged simultaneously be it positive or negative while the other 4 will be 0 ?
@angeldude101
Жыл бұрын
@@Troynjk Uh... No? You can still rotate around any plane in 4D space whether or not it's aligned with the coordinate axes, which gives an infinite amount of options, but trying to rotate around any more than 2 independent axes will always collapse them down to 2, even if they might be around different axes than the four rotations you were composing.
@Troynjk
Жыл бұрын
@@angeldude101 I think i understand, but lets do a somewhat practical example. We have an object that moves 5 cm on Y axis, our measuring devices show: X - 0 Y - 5 Z - 0 X(spin) - 0 Y(spun) - 0 Z(spin) - 0 We start again but this time the object gets a spin on Z axis of 3 rpm and it’s moving 7 cm on Y axis, our measurement devices will show: X - 0 Y - 7 Z - 0 X(spin) - 0 Y(spin) - 0 Z(spin) - 3 In this case the object uses 2 out of 6 degrees of freedom simultaneously. My question is how many (what is the maximum) degrees of freedom an object can use simultaneously? 2 out of 6 ? 3 out of 6 ? Or all 6 ?
@angeldude101
Жыл бұрын
@@Troynjk 7e02 + 3e12 = (7e0 + 3e1) ∧ e2, so that's actually using only 1 of the 2 available independent axes, even if said axis isn't aligned with any of the 6 basis axes.
@sirnukesalot24
3 жыл бұрын
Looks like the rotor isn't just a more generalized form that captures the quaternion, it captures the spinor as well. It might be worth pointing that out since spinors have been popping up in the public discussion within the last year or so.
@schwajj
4 жыл бұрын
Thanks for a great explanation. I have a constructive criticism... I find it jarring when one equation cross-fades into an equivalent equation. I would prefer to have a new equation fade in below, so I can verify equivalence myself. This would make it easy to pause the video to compare the two equations. Instead, I have to rewind the video to see the previous equation. Going back and forth between the two equations is tedious. Thanks again!
@schwajj
4 жыл бұрын
An example of what I have problems with is 6:45, and what works for me is 13:05
@marctenbosch
4 жыл бұрын
Thank you for your suggestion.
@LeonardPauli
3 жыл бұрын
@@marctenbosch I believe animations can help a lot, as long as they are connected to what's happening mathematically. I usually really enjoy the in-place animations, but yeah, in the 6:45 example, it was a bit jarring; for just elimination, fade is great, though when a term is moved, a movement animation may suitable (or just fall back on a new line).
@badradish2116
3 жыл бұрын
colorizing the differences might help too
@Toxo
3 жыл бұрын
If you really want to make an argument for replacing quaternions, I think you should establish that the new way is computationally equally or less expensive than quaternions. Using black boxes are a non-issue in software engineering, provided they do what you intended every time and aren't inefficient. Anyway, your video is really well made and I am grateful you made it!
@porky1118
3 жыл бұрын
They are isomorphic. The implementation would basically be the same.
@Ruktiet
3 жыл бұрын
@@porky1118 that's not what isomorphism implies. You could have an isomorphic structure that has representations and operations on those representations involving lots of computations compared to another one.
@porky1118
3 жыл бұрын
@@Ruktiet I would expect some data type to already use the most efficient algorithm possible. So if some isomorphic data structure to quaternions existed, which is more efficient, it would probably already have been used internally. Isomorphic would just mean, they have the same API, maybe with different names.
@z-beeblebrox
3 жыл бұрын
@@porky1118 "I would expect some data type to already use the most efficient algorithm possible." That is an INCREDIBLY optimistic assumption
@levknoblock88
3 жыл бұрын
@@Ruktiet Not only an optimistic assumption, but also an unrealistic one. Libraries for the same things constantly disagree on which data structures to use, even for something as common and 'simple' as matrix multiplication. On top of that, there are a lot of problems in CS where we just don't know what the most efficient approach is. And even then, the "best approach" changes depending on what computer you run the code on, so it's even more messy than that.
@lukostello
4 жыл бұрын
I feel like there is an untold story of how you tried to code rotations in 4d for miagakure and discovered 4d rotors rather than a 5d solution. Then were like "well jeez if we dont need a 5th dimension for 4d rotations then why would we need a 4th dimension for 3d rotations?"
@marctenbosch
4 жыл бұрын
Yeah, except it is 8D, not 5D, ahah: marctenbosch.com/news/2011/05/4d-rotations-and-the-4d-equivalent-of-quaternions/
@petrowi
4 жыл бұрын
@@marctenbosch I'd be very curious to see a similar video for octonions. Loved this presentation
@williamchamberlain2263
4 жыл бұрын
@@petrowi too right - octonions get far too much play in game engines.
@petrowi
4 жыл бұрын
@@williamchamberlain2263 my curiosity on the subject is not related to game engines
@mudkip_btw
3 жыл бұрын
@@frankdimeglio8216 very elaborate shitpost
@eeromutka
4 жыл бұрын
Fantastic read/video! One thing that bugs me though if the fact that you're explaining everything in terms of XY, YZ and XZ planes, but things would get more consistent if you used YZ, ZX and XY planes instead. There are a couple of things that this fixes, let me explain. Firstly, if you take the cross product of the basis vectors of the XY plane, you'll get Z=1. For YZ plane, you'll get X=1. But with XZ, you'll get Y=-1. Seems very wrong right? Using ZX not only fixes this, but also it's quite logical that Y comes after X, Z comes after Y and, after wrapping around, X comes after Z. At 7:43, you explain how the outer product is almost like the cross product, but the value for Y is negative. But by using ZX, this also gets fixed and the values are identical! Also, if you fix the order so that it's [YZ, ZX, XY] and not [XY, YZ, XZ], it'd match up with the rows of the matrix you'd get from a cross product.
@marctenbosch
4 жыл бұрын
Yeah I think both have advantages. I have an aside in the article (marctenbosch.com/quaternions/) that says: "I chose a lexicographic order for the basis because it is easy to remember, but choosing z∧x instead of x∧z would make the signs the same. It would also makes the bivector basis directions consistent. This is the right hand rule, except the understandable non-arbitrary version :)" It does become more difficult to define in 4D and higher: should it be YW or WY ? So I think lexicographic order is helpful then.
@OMGclueless
3 жыл бұрын
@@marctenbosch If you choose an ordering and then take the (circular) pairs of unit vectors as your bivector basis, it should work out in all dimensions, no? Sure, it doesn't tell you whether it's `yw` or `wy`, but neither of those bivectors are basis bivectors in the standard basis. And if you were to project the 4D space into a 3D space the choice of `yw` or `wy` would be dictated pretty naturally by your choice of projection following the same logic (for example, in `wxy` space it's `yw` and in `wyz` space it's `wy`).
@theodorostsilikis4025
3 жыл бұрын
Staying consistant with the permutations becomes much more relevant in higher dimensions .In 3vectors xyz,yzx,zxy have the same sign,imagine xyz,yzx,-xzy...
@ZedaZ80
3 жыл бұрын
Oh, that's pretty helpful :0
@angeldude101
2 жыл бұрын
Of of the things I love about geometric algebra is that it doesn't matter whether you use xz or zx, because the two will always be negatives of each other. With quaternions and cross products, there is only 1 choice of basis and it's rather arbitrary. With geometric algebra, you have two options for each basis bivector and can store them however you like as long as you understand xz = -zx. Some sources use wx, wy, and wz, along with a cyclic permutation of the other 3, while others use xw, yw, and zw.
@mudkip_btw
3 жыл бұрын
I have known geometric algebra was supposed to be more intuitive for a while. Recently I've used quaternions for the first time and I was really enthusiastic about how numerically efficient and stable they were, but I don't fully understand them. I think the next time I do a project involving 3d rotations, I will use the geometric algebra formalism. Thanks!
@r.pizzamonkey7379
3 жыл бұрын
I feel like the name is slightly clickbait. What it seems like you're actually arguing here is a different way to teach quaternions. I don't think using this approach would actually change anything about how a 3D engine is implemented under the hood. At best it would be some different identifiers and documentation, but once you compile and optimize everything you're left with the same end product.
@primarysecondaryxd
3 жыл бұрын
Check out watch?v=tX4H_ctggYo if you're interested. I think it works out to a very small memory advantage over matrices in the 2d/3d case if the whole thing was implemented under the hood (otherwise I think it all works within one matrix per object), with much more generality between 2d and 3d as well as simplifying the implementation (less exceptions to deal with, everything is one type, 2d functions work for 3d and vice versa) from the programmer's side. That said it's hard to use when game engines don't have a native implementation and you have to translate between everything yourself.
@r.pizzamonkey7379
3 жыл бұрын
@@primarysecondaryxd what I mean is if j really is just yz, and you don't want to implement an entire general CAS solver when all you need is a few specific cases, you're going to end up with the same ijk lookup table just written with the bivectors, as seen in section 3.2. I mean, it's the same as your standard quaternion table except they omit the identity operation (1x), but it's not really necessary there either.
@MathAndComputers
3 жыл бұрын
I noticed this, too, and also that quaternions usually aren't used for rotating vectors, since for more than a handful of vectors, it's more efficient to convert to a rotation matrix first and use that. Quaternions are usually used for composing transforms or blending transforms, since they're more efficient than matrices for those, at which point, I'd be curious whether dropping the real component like this might lead to inefficiency. 🤔
@LukeVilent
3 жыл бұрын
@@MathAndComputers You're not dropping the real component here. Since rotors and quaternions are the same, identical thing, captured by the math term "isomorphic", a product of two general rotors will almost certainly produce a rotor with a real part. UPD. Maybe, you were meaning replacing unit quaternions with their Lie algebra counterparts. I've tried that - not the best idea.
@MathAndComputers
3 жыл бұрын
@@LukeVilent Isomorphic doesn't mean that they're the same, identical thing; it means that they're mathematically interchangeable. As described in the video, rotors are 3 components; quaternions are 4 components, i.e. the 3 components of rotors, plus an additional component that can be computed from the other 3 (ignoring the sign) if only unit quaternions are relevant. The sign is sometimes needed, which technically makes them not isomorphic, but even if we ignore that, and even if isomorphic did mean that they're exactly the same, then "rotor" would be a redundant term for "quaternion", and removing quaternions from all 3D engines would mean removing rotors from all 3D engines, and the title of the video is still contradicted by the video, which is pretty much the point I was making in the first place.
@ChrisOffner
4 жыл бұрын
Can you recommend any great resources (books, lecture playlists, etc.) on Geometric Algebra?
@elijahlape
4 жыл бұрын
A nice introductory book is Volume 1 from this series: foundationsofgameenginedev.com/ Playlist: kzitem.info/door/PLpzmRsG7u_gqaTo_vEseQ7U8KFvtiJY4K
@writerightmathnation9481
3 жыл бұрын
Hestenes
@ChrisOffner
3 жыл бұрын
@@writerightmathnation9481 Do you mean "Clifford algebra to geometric calculus: A unified language for mathematics and physics" by David Hestenes and Garret Sobczyk?
@plus-sign
3 жыл бұрын
I'm reading "Geometric Algebra for Computer Science" (Dorst, 2007). Good if you're a programmer.
@ChrisOffner
3 жыл бұрын
@@plus-sign Cheers, I'll check it out.
@Alexander_Sannikov
3 жыл бұрын
For me the similarities between hypercomplex basis and a bivector basis were always obvious because I always thought of ijk basis as a bivector basis to start with. But I never realised that reflection about a and then reflection about b is the same is rotating by twice the angle between a and b. This actually was very insightful.
@writerightmathnation9481
3 жыл бұрын
There are lots of useful resources if you really want to learn such stuff: Hestenes' Space-Time Algebra book, Hoffman & Kunze's Linear Algebra book, and Anadijiban Das' Tensor Analysis book. In this sense, a bivector is nothing but an element of a tensor product of a vector space with itself, and a bivector basis should naturally be a member of the canonical basis for such a tensor product, constructed using the tensor products of pairs of members of a given basis for the original vector space.
@rogierbrussee3460
3 жыл бұрын
So Clifford algebras (which is what geometric algebras are except without the cult of Hestenes) are really useful. For example they are fundamental for the notion of spinor. In particular |H = Cl(|R^2, Q) where Q is negative definite inner product. But there is nothing strange about the Quaternions. Them being 4 dimensional comes from the space of all rotations SO(3) being 3 dimensional and its universal cover Sp(1) being a 3-sphere. Of course a 3-sphere naturally sits in a 4 dimensional space: exactly the three sphere of unit quaternions. It works as follows. The space of imaginary quaternions Im(|H) = {v\in |H | v = x I + yJ + z K} is clearly a 3D space with v\bar v = x^2 + y^2 + z^2 the standard inner product. let Sp(1) = { q \in |H | ||q|| = q \bar q = 1} Then Sp(1) is obviously a 3-sphere. Note that the Lie algebra sp(1) consists naturally of the quaternions h such that (1 + \epsilon h) (1 + \epsilon \bar h) = 1 + \epsilon ( h + \bar h) + O(\epsilon^2) = 1 + O(\epsilon^2) i.e. h \in Im(|H). Moreover Sp(1) acts on Im(|H) by v --> q v \bar q This is an orthogonal transformation of Im (|H) since \bar (q v\bar q) = q \bar v \bar q = - q v \bar q and q v \bar q \bar(q v \bar q) = q v (\bar q) q \bar v \bar q = q v \bar v \bar q = ||v||^2 q \bar q = ||v||^2 In fact it defines a rotation because Sp(1) is connected so the determinant of v --> q v \bar q which can only take on the values ±1 must be constant 1. This explains how quaternions give rise to rotations, and clearly q and -q give rise to the same rotation. (1 + \epsilon I), (1 + \epsilon J) and (1 + \epsilon K) as a matrix on Im(|H) and keep the first order terms e.g. (1 + \epsilon I) I (1 - \epsilon I) = 1 +\epsilon [I, I] + O(\epsion^2) = 1 + O(\epsilon^2) (1 + \epsilon I) J (1 - \epsilon I) = 1 + \epsilon [I, J] + O(\epsilon^2) = 1 + 2\epsilon K + O(\epsilon^2) (1 + \epsilon I) K (1 - \epsilon I) = 1 + \epsilon[ I, K] + O(\epsilon^2) = 1 - 2\epsilon J + O(\epsilon^2) lie algebra element I corresponds to the matrix 1 0 0 0 0 2 0 -2 0 Proceeding similarly for J and K we see that sp(1) --> SO(3) is an isomorphism. The map Sp(1) --> SO(3) is then open, and since Sp(1) is compact it is also closed, so the image of Sp(1) is a closed and open subgroup of SO(3) which must be everything.
@PS3PCDJ
3 жыл бұрын
Cant wait for Randy to find this and then watch him go and refactor most of his code to get rid of the Quaternions he just learned about and implemented into his game
@LukeVilent
3 жыл бұрын
And find out that he replaced quaternions with... quaternions.
@DarkCloud7
Жыл бұрын
It took a bit to digest, but after reviewing the article a few times I felt a sense of enlightenment. The stuff that seemed so out of the blue before (like the cross product) now fall into place so naturally. Thank you very much for this intro to geometric algebra.
@QRebound
4 жыл бұрын
Great video, but early on you say that rotors and quaternions are isomorphic, and in the same breath say that quaternions have less capabilities than rotors. That would mean they aren't isomorphic, wouldn't it? If they truly are isomorphic, it may be more *awkward* to use quaternions for some things, but they'd still be capable of everything rotors are.
@marctenbosch
4 жыл бұрын
3D Rotors (the even subalgebra of 3D geometric algebra) are isomorphic to quaternions, but they can also operate on things that are not isomorphic to quaternions via the full geometric algebra.
@trueriver1950
3 жыл бұрын
@@marctenbosch So more exactly what you meant is that rotors contain a subset that is isomorphic to quarternions? That might make rotors a useful extension to quarternions even apart from being more intuitive. Do you have an example of a physical effect that can be modelled by a rotor operation but not with quarternions?
@elkinmontoya9640
3 жыл бұрын
@@marctenbosch Is this isomorphism local, or global?
@polyhistorphilomath
3 жыл бұрын
@@trueriver1950▽F= μ_0 c J. Maxwells equations with the laws as 0-, 1-, 2-, 3-vector components
@polyhistorphilomath
3 жыл бұрын
It’s not really a proof of inapplicability. But the Clifford algebra representation is concise if nothing else.
@Alexander_Sannikov
3 жыл бұрын
I think the greatest confusion in understanding quaternions comes from the fact that in 3d the dimentionality of an axis of rotation is the same as dimentionality of the space itself. This is not the case for any(?) other dimensionality. Because of this, we think of rotation axes as if they were part of the same space when they are really not, which's particularly obvious in non-orthogonal bases.
@writerightmathnation9481
3 жыл бұрын
What do you mean by "dimensionality of an axis of rotation", please? Let's stick to the three dimensional case for now. In my view, the dimension of an axis of rotation in three-space is 1 because it is a line ( a translate of a one dimensional real subspace of thre space), but the dimension of three-space is not 1. The term "dimensionality" is strange to me and undefined in this context.
@Alexander_Sannikov
3 жыл бұрын
@@writerightmathnation9481 by dimensionality i mean "units of measure". dimensionality of axis of rotation is not units of vector space, it's units of bivector space. So it's not [meters]^3, but rather [meters*meters]^3
@JivanPal
3 жыл бұрын
@@Alexander_Sannikov, rotations are dimensionless, since they are angles. The result of a cross product merely encodes a plane and a scalar corresponding to something related to that plane (e.g. a rotation, angular velocity, torque, etc. in that plane). A vector is simply a nice way to encode both of these things together.
@Alexander_Sannikov
3 жыл бұрын
@@JivanPal rotations are only dimensionless in a dimensionless space. But you can easily consider a space that has its own dimensionality. In fact, typically spaces in physics are measured in physical units of length (meters, etc), but you can easily imagine a hypothetical abstract space where each basis vector has its own unit of measure associated with it. Since decomposition by these unit vectors is unique, each vector of this space will have a unique measure composition as well. And then you'll notice that in order to define a rotation axis in this hypothetical space, you CAN'T use a vector of the same space, you need to use a vector of so-called dual space, and dual space is a space of bivectors. Another hint to why rotation axis can not have the same dimensionality in general as the space itself: only in 3d axis of rotation has the same number of dimensions as a vector that it rotates. For example, in 2d space your axis of rotation is 1d, and in 4d space your axis of rotation has 6 components (which is the dimentionality of dual space associated with it).
@porky1118
3 жыл бұрын
@@writerightmathnation9481 Dimension is the correct term: en.wikipedia.org/wiki/Vector_space#Basis_and_dimension
@bluceree6897
3 жыл бұрын
Man, I wish i was smart enough to understand any of it and how to properly utilize it in my code :(
@galvanizeddreamer2051
3 жыл бұрын
Bookmark it, and come back to it after taking an entire course on geometric algebra or something. Because you can bet your arse that's what I'll be doing.
@MyLittleMagneton
3 ай бұрын
@@galvanizeddreamer2051 How'd it go?
@galvanizeddreamer2051
3 ай бұрын
@@MyLittleMagneton I forgot to do this, and I still can't code. I wrote an RPG system tho.
@atomictraveller
Ай бұрын
try this: // init s0 = 1; s1 = 0;; // loop s0 -= w * s1; s1 += w * s1; renormalise the leg every buffer or so
@Taronites
3 жыл бұрын
This totally beats any OBE meditation. By the 10th minute I find myself hovering at least 7 inches above my chair. ^^
@atomictraveller
Ай бұрын
seven inches rofl :)
@Pherecydes
Жыл бұрын
Brilliant! I have wondered about cross products for decades, and even after working through the derivations algebraically they never really clicked. This video was a jolt of enlightenment. Thank you.
@EMB3D
Жыл бұрын
1:43 if you think about matricies, and vectors. If you want 3D transformation (nost just rotation but translation and scaling) with them, you need one extra dimension, hence a 4x4 matricies and x,y,z,w homogenous vectors are needed in to order express such.
@linuxp00
2 ай бұрын
Real 4×4 or Complex 2×2, aka, Pauli Matrices
@NikolajKuntner
3 жыл бұрын
I feel you start this out with a non-argument: "I wasn't taught why quaternions work, so here's an alternative..."
@LukeVilent
3 жыл бұрын
"Working out quaternions is hard, so let's replace this rusty crap with the algebraic completion of 2-wedge products over three generators, which are quaternions, but now lactose and gluten free."
@NikolajKuntner
3 жыл бұрын
@@LukeVilent lol
@stefanvasilev2013
2 жыл бұрын
Sorry, but I can't see any gain in this method. It does not seem more intuitive. By introducing addition between entities of different type, you basically start working in a Clifford algebra-like space where bases square to 1 instead of -1. This already starts deviating from standard mathematical conventions (when we talk about rotations) leading to many potential bugs and misunderstandings. This is also the root cause why (xy)(yz) = xz instead of zx which would be more intuitive. Doing this, you also include excessive machinery and notation much more cumbersome than falling to 3D and using quaternions. Moreover, rotations are represented by unit quaternions, often called versors, which form a 3-dimensional group, not a 4-dimensional one, so no 4D here. I must oppose to this sentence: "Each plane is perpendicular to one axis. This is a coincidence that only happens in three dimensions (*) and it is why historically we have been confusing bivectors with vectors." It is by no means a coincidence, nothing here is!! This is a remarkable theorem by Adams. The duality between 2-forms and 1-vectors over a 3-dimensional manifold is fundamental in mathematics. The very existence of quaternions and them forming a division algebra (i.e. we can multiply and invert them) is what enables us to use this duality and multiply two vectors using the cross product to get another vector (the dual of the 2-form/bivector). All the similarities you've seen and pointed out are rooted here. Nothing comes form thin air. TLDR; I think this approach suggests discarding the use of strong mathematical results to achieve the same goal by the same means, just with worse notation and compliance to standard theory. For comparison's sake: a unit quaternion (versor) rotates a vector by conjugation, exactly like the suggested bivectors; versors naturally form a multiplicative group (two-fold covering of the standard 3D rotation group); you can explicitly read off the rotation axis and magnitude from the versor representation. Clear, concise and sufficient.
@angeldude101
Жыл бұрын
"you basically start working in a Clifford algebra-like space where bases square to 1 instead of -1" What do you mean "-like"? This _is_ a Clifford algebra. The only reason they used (xy)(yz) = xz is because it's required in order to conform with quaternions. The most natural bivector basis of Cl(3) is [e₂₃, e₃₁, e₁₂], since they are respectively the duals of each of the vectors. It however doesn't work as a quaternion basis since it would make ijk = 1 rather than -1. "The duality between 2-forms and 1-vectors over a 3-dimensional manifold is fundamental in mathematics." I would say 2 + 1 = 3 to be more trivial than fundamental. I could just as easily say 2 + 2 = 4 and oh hey! 4D planes are dual to other planes! Meanwhile 1 + 3 = 4 making hyperplanes dual to lines. If we were flatlanders, the equivalent is quite literally 1 + 1 = 2. "Moreover, rotations are represented by unit quaternions ... which form a 3-dimensional group, not a 4-dimensional one, so no 4D here." Funny. This is normally used as justification for rotors over quaternions since quaternions are usually taught as 4-dimensional, when using Clifford algebra makes it very clear that no; they were never 4-dimensional unless you consider "doing nothing" a dimension. The part about confusing vectors and bivectors is accurate, though I'd say it's more about confusing rotational degrees of freedom with linear degrees of freedom. These only have a 1-1 correspondence in 3D. In 2D, there's only 1 rotational degree of freedom, but 3D mathematicians often have a hard time conceiving of that so they invent a new linear degree of freedom sticking out of the plane rather than accept that they could just use a point and acknowledge that rotational degrees of freedom are distinct from linear degrees of freedom. In 4D, there are 6 rotational degrees of freedom, but only 4 linear degrees of freedom. Since it's not possible to make a 1-1 correspondence between them, and they can't just invent new linear degrees of freedom when they've already past what can be visualized, the usual response seems to just be to give up and stick to 3D. You can however make a 1-1 correspondence in 4D between linear dimensions and volumetric dimensions, though the latter isn't useful for rotations until 5D (where it's no longer 1-1 with linear dimensions) and the former only works for rotations in 3D.
@sumdumbmick
3 жыл бұрын
as a general rule when the people around you are all dogmatically saying the same thing and nobody can explain why, it is more than legitimate to question it.
@michaeltsouris8190
3 жыл бұрын
if you're surrounded by people who can't explain something that is well documented, you're asking the wrong people.
@ericy1817
3 жыл бұрын
@thatonespathi Sometimes these things honestly just fall to convention. Both pi and tau have their merits, its just that people started using pi first so we stuck with it.
@danielb270
3 жыл бұрын
Any Computer Graphics Course (the coding kind) in University should explain it. Also, super-short answer: that is how GPU's work, so ANYTHING else would be slower.
@omp199
3 жыл бұрын
@@ericy1817 I am unaware of any merits to using pi rather than tau, other than that all the works of reference already use pi. Also, there are all these people talking about quaternions here, but I can't see any mention of why they were a thing in the first place. The Wikipedia article sums up why quaternions are a thing: in 1877, Ferdinand Georg Frobenius proved that for a division algebra over the real numbers to be finite-dimensional and associative, it cannot be three-dimensional, and that there are only three such division algebras: the real numbers, the complex numbers and the quaternions, which have dimension 1, 2, and 4 respectively. That's what makes them special.
@cooperpilot8094
3 жыл бұрын
5:53 my grandpa is anti-symmetric :/
@roygalaasen
4 жыл бұрын
I am confused. Not by your excellent video, but because I was already subscribed to your channel. That means there were excellent videos here from before. But this is the only video here and it was released 30 minutes ago. Did you delete all of your old content? That is a bit sad because although I don’t remember it off the top of my head, I did subscribe because it was good, and if it is deleted, good content has been taken away from this world.
@ddegn
4 жыл бұрын
I initially felt like you described. I checked out his website and felt a bit more at ease. There's lots of great stuff on his website. Apparently this is an update of an older video. I also don't recall how many videos he had, I just remember being impressed by the quality of the previous video.
@roygalaasen
4 жыл бұрын
Duane Degn if I remember correctly, this is the channel I commented that it was sad that he didn’t make any more videos since they were few, but really good and his last video was like 3 years ago or something. In that case we are in for a lot of goodies coming up in the future.
@ShankarSivarajan
4 жыл бұрын
This is the Miegakure guy. That's almost certainly why you were subscribed.
@roygalaasen
4 жыл бұрын
Shankar Sivarajan oh it is? I am certain that was not the reason, but I subscribe to loads of math channels and also watching a few videos of that game, KZitem algorithm probably thought to suggest videos from this channel, and I took the bait and subscribed. Thanks for the connection though!
@marctenbosch
4 жыл бұрын
My other videos are unlisted, they are old and I embed them on the related articles on my website.
@LAK132
4 жыл бұрын
Hi, thank you for this video! I'm looking through your code, and I'm having a hard time working out how you came up with this implementation. I see the trivector value in there, but I can't work out how that comes out of the bavab equation?
@marctenbosch
4 жыл бұрын
You have a rotor that is r=a*b, then you first multiply v by r, that gives a vector + trivector, then you multiply the result of that by reverse(r) and that kills off the trivector part.
@MarkKrebs
4 ай бұрын
I guess I'll pitch a monkey wrench at this. I *love* quaternions. When you have a rotation, thinking of the two-d case (where Bosch begins) the axle about which the rotation happens lies in the third dimension. In this way it's not too unnatural to imagine that 3-d rotations might need 4 elements to describe them. Quaternions anticipated the mathematics of vector calculus eg Maxwell's equations and aerodynamics and quantum mechanics etc etc. Don't be scared off too easily, quaternions are great.
@thygrrr
11 ай бұрын
Thank you for this great perspective, but especially in the middle, I fail to connect the dots and have no mental model whatsoever of your bivector, numerically. I always thought it is the cross product. I think you could have provided the actual formula for the bivector for the 3D case. Numerical only, default unit basis in 3 dimensions ("xyz", or index 1 to 3, or 0 to 2 for us coders). Is it the cross product in 3d now, or IS IT NOT? Your formula looks like it's self referential, each outer product requiring another outer product multiplied with the components of the cross product. 7:56 How do we even read the bottom equality? Or is it a formatting error and the wedge products on the right side are subscripts? And which one do we use? It appears like this depends on the handedness of our coordinate system but you just skipped over it. 😢 Or is the first + in the bottom equation at 7:56 a typo? From the looks of it, it's also not clear whether trig functions are needed for this wedge notation or not. Can I express a definitive rotation from a into b (around the axis axb) without first calculating the angle 2alpha, just by using the two unit vectors a and b? As it stands now, I find the exponential map / quaternion representation of rotations more intuitive, and that's really saying a lot.
@GamingKing-jo9py
10 ай бұрын
7:43 marc PLEASE fix this. this has been confusing me for years you should make the y for the cross product as (-y) removing the y up front. otherwise it looks arbitrarily different. either change that base to -y or flip the bivector x∧z to z∧x. it makes the connection so much clearer, and stops another soul from looking at countless wiki articles trying to find why the negative and why everyone is saying they're exactly the same
@monke5100
Жыл бұрын
Isn't it ironic that this guy is teaching us things that should prevent us from thinking in 4 dimensions?
@linuxp00
2 ай бұрын
Actually not, quaternions are not geometrical dimensions, they're algebraic dimensions. For reasons too long to explain here, the true dimensional upgrade is given by a sum of a vector and two quaternion bases: [t, x, y, z] (quadriposition); [tx, ty, tz] (hyperbolic rotations / relativistic boosts), [xy, yz, zx] (spherical rotations / orientations)
@JanPBtest
3 жыл бұрын
Mathematicians call it "Clifford algebra" and "Clifford multiplication". I don't know where the terms "geometric algebra" and "geometric product" came from originally. Likewise, the wedge product of vectors is a part of "Grassmann algebra". I agree all this should be taught early on, along the standard vector product (which can be very useful too, it works not only in 3D but as a product of (n-1) vectors in n-D.
@kvazau8444
3 жыл бұрын
the term "geometric algebra/product" came from clifford himself.
@JanPBtest
3 жыл бұрын
@@kvazau8444 I wonder why the name did not stick with mathematicians.
@MichaelPohoreski
3 жыл бұрын
Jan I'm not sure where you are getting the lie that Mathematicians don't call it Geometric Algebra. Austrian Mathematician Emil Artin has a 1957 book called _Geometric Algebra._
@JanPBtest
3 жыл бұрын
@@MichaelPohoreski I never heard the term "geometric algebra" used in the areas connected to manifold geometry and topology. I'm sure it's used in _some_ areas of mathematics. But then I left academia 20 years ago so perhaps things have changed today.
@MichaelPohoreski
3 жыл бұрын
@@JanPBtest The problem is a LOT of math teachers are horrible teachers teaching by rote, suck the passion out of kids, and are ignorant about modern topics such as bivectors, why the cross product only being defined in 3 and 7 dimensions is a problem, don't teach that the imaginary value i = sqrt(-1) is a 90° rotation, etc. This is mostly due to their teachers being uninformed and bad as well. You'll want to read Paul Lockhart's _A Mathematician's Lament_ that gives a depressing but accurate summary of the state of teaching mathematics.
@PhantomKING113
3 жыл бұрын
I knew it! The multiplication table at 12:10 looked familiar, and that's for a simple reason: since rotors and quaternions are isomorphic, there's no way to run away from them. Basically, rotors use 2 leters for the same thing for which a quaternion uses 1; though idk how to emulate vectors with quaternions, I am not a mathematician... Let's say xy is like i, and yz like j, then xz is like k and we get the following multiplication tables: \ *1 xy yz xz* *1* 1 xy yz xz *xy* xy -1 xz yz *yz* yz xz -1 xy *xz* xz yz xy -1 So it's just quaternions again. As for the other table: \ *1 x y z* *1* 1 x y z *x* x 1 xy xz *y* y xz 1 yz *x* z xz yz 1 In quaternions, that probably also has some representation, but I am not a mathematician or anything like that so I'ma stop here before I get something wrong. Anyway, cool video! Also, the quaternion multiplication table doesn't come out of nowhere, there's logic to it... Edit: Btw, 3D rotors are also 4-dimensional, so don't get confused. If you represent the xy component on the z axis, the yz component on the x axis and the xz component on the y axis, you still need a fourth axis for the scalar part (if that was how it was called). So no, rotors aren't any simpler, they just favour a different angle from which to approach the same overall mathematical system.
@angeldude101
3 жыл бұрын
The 4th component is the scalar-part, correct. It can also be called the 0-vector or grade-0 vector since it's a product of 0 basis vectors. From what I understand, quaternions were originally conceived as the quotient of two vectors, so your second table is probably not far off from how Hamilton defined them since the inverse of a vector in GA is just the vector scaled to the reciprocal of its length, which for the basis vectors is just themselves. The biggest problem is just that it's never mentioned when initially teaching quaternions, while bivectors have a clear relation to the vectors that formed them.
@blinded6502
2 жыл бұрын
Actually, considering the fact that quaternions are usually constructed from rotation-axis pseudovector: i = yz j = xz k = xy 3d rotors are not 4d. I mean, you could represent them as 4 quantities along 4 different axes, but.... Why?
@erickweil4580
4 жыл бұрын
Also, how is the geometric product generalized to 4D when you have Bivector x vector? from my calculations it produces a vector plus four trivector parts. Those trivector parts can be dropped out? my Geometric Algebra understanding only was able to make 3D Rotors work.
@erickweil4580
4 жыл бұрын
After doing some math, actually those trivector parts are used in the second multiplication of the rotation sandwitch. I'm not sure if its 100% correct but it worked so far. Thanks for this video and article. In a future article you could talk a little bit about Rotors is in 4D, is not that trivial.
@marctenbosch
4 жыл бұрын
The trivector part drops out when doing the full sandwich product, yes.
@erickweil4580
4 жыл бұрын
@@marctenbosch To solve it I ended up doing a program that expands the geometric algebra expressions following the rules and then getting only the final reduced formula(used python and the library sympy) So rotor multiplication and matrix conversion worked perfectly. But... I found some problems while interpolating 4D Rotors, as with some combinations of rotors the result is a rotation with scaling. I didn't found any resources about log or square roots of rotors ( also exp is very very slow ) as there is a way to interpolate that requires this calculation (multiplicative interpolation)
@losiu998
3 жыл бұрын
6:51 - B_xy looks like determinant of the 2D matrix, where columns are 2D vectors, coincidence? Of course not :)
@SteinCodes
3 жыл бұрын
Sorry for only watching it now, but incredible stuff, I feel dumb for just accepting quaternions in all my code as it is, till now. They would have made the like of high school me, trying to learn graphics programming so much easier, thanks a lot. I had taken multiple courses in Maths, wasted several hours working on geometric algebra but never did I think of using it. So thanks a lot. 😊 I will try and port as much of my code to rotors as possible, and only leave a quaternion api as a secondary solution. :)
@AThagoras
3 ай бұрын
Best introduction to geometric algebra that I've ever seen. I've used quaternions for graphics and always thought geometric algebra was too complicated because of the different products and mixed type sums etc. but when it's clearly explained, it makes sense and seems simpler to work with because you can use geometric intuition to break up calculations instead of having to do a lot of algebra and hope you got it right.
@JohnTan
3 жыл бұрын
8:17 Just to clarify, the vector given by cross product is not a "confusion". It is a result of Hodge duality in the exterior algebra. Aka the hodge dual of x is exactly y^z and so on.
@user-hh5bx8xe5o
3 жыл бұрын
That's true but the cross product is only relevant in 3D as the dual of a bivector is of dimension n-2 so only mapping vectors to vectors when n is 3.
@WhiteDragon103
3 жыл бұрын
Can you please explain this in code instead of math notation?
@porky1118
3 жыл бұрын
That's basically the same math used in most programming languages. You assume, your programming language has two new operators. What kind of code notation would help you?
@blinded6502
2 жыл бұрын
@@porky1118 ^
@pladselsker8340
3 жыл бұрын
This seems unpractical to me. My quaternion rotations are working just fine. It's a well made video though, I think the editing is pretty good.
@khatharrmalkavian3306
3 жыл бұрын
Ahh... Math and quaaludes. Great combination you've got going here.
@arnoldn2017
3 жыл бұрын
Quarter ions are nicely wrapped Rodriguez rotations. The only point I see in favor of quaternions is that it is possible to multiply them with a ‘C-O’ quaternion to mathematically align an observation quaternion to a body quaternion for real time applications like on seagoing vessels
@platinummyrr
3 жыл бұрын
That's the primary advantage I found when trying to do a 3d rubics cube program. It was frustrating to have traditional naive rotations break in weird ways when you tried to drag parts of the cube. (If you rotated the cube 180* about an axis, then naive rotations would flip the wrong intuitive way because they were being applied wrong). Using quaternions I was able to easily translate the input into the desired motion.
@gnramires
11 ай бұрын
I think this would benefit from deriving rotors of an axis-angle rotation. (I think insight sometimes comes from connecting many viewpoints, not just a single one), I found that missing after describing rotors from reflections. But rotors do seem quite compelling, as well as GA as a whole! Thanks.
@konstantinchepurkin5595
3 жыл бұрын
I don't see any practical impact from this construction. As quaternions are isomorphic to rotors (even part of Clifford algebra of R^3) all the formulas should be the same. There stands that it is more convinient to parametrize rotations by plane and scalar and that is why rotors are natural. But I think it is ok to parametrize rotations by axe and angle (what quaternions do). Besides all this stuff doesn't word for greater dimensions in that way. Of course quaternions could give optimal representation (in the sense of memory used) only for 3d and 4d rotations (3 and 6 parameters + signs). But geometric algebra approach fails already for 4 dimessions. As I understand they suggest to use new 2^4=16 dimensional algebra (Clifford algebra for R^4) to parametrize rotations in 4d. And in general they use 2^n dimensional space (Clifford algebra for R^n) to parametrize rotations of R^n. And use exponentiation instead of polynomial formulas. It's weird as one can parametrize rotations by skewsymmetric matricies that takes n(n-1)/2 parameters. Take a skewsymmetric matrix A. Then its exponent e^A is a rotation matrix and any rotation matrix appears in this way. One also can avoid exponentiation (at the cost that there are some exeptions: (E+A)(E-A)^{-1} is a rotation matrix if A is skewsymetric and almost every rotation matrix appears in this way) Quaternions are not harder to understand than complex numbers. Idea of using multiplication rules for basis vectors is simple. But general constructions of geometric algebra use much heavier concepts like Clifford algebra and Exterior algebra. I also wonder, why don't call this old well known mathematical tools in a proper way?!
@marctenbosch
3 жыл бұрын
It works great in any number of dimensions. I wrote a SIGGRAPH paper that use n-D Rotors for n-D rotations... marctenbosch.com/ndphysics/
@joeedh
3 жыл бұрын
But is it simpler in 3 dimensions? Honestly, who cares about higher dimensions?
@jakubscholtz3320
3 жыл бұрын
Just wait for the moment you realize that in 3d bi-vectors are related through Hodge dual to the vectors and this whole video was about being surprised this isomorphism exists :-)
@zzasdfwas
3 жыл бұрын
He says pretty early on that it's isomorphic.
@DrakeLarson-js9px
6 ай бұрын
Your instinct was sound.. it is somewhat overly complicated ... it is rotation (and how to describe?) and Hamilton 1843 notice of the twirling vortexes of water under the bridge was the foundation of this.. which is useful for 'creative projections' ... (This video is a ton of information in under 20 minutes, Congratulations.)
@qedqubit
3 жыл бұрын
So.... if the people at Blender institute /foundation in Amsterdam learned geometric algebra, would this speed up blender ? c(/w)ould it make things easier for math-ignorant users as well ? #blender-developer
@l_a_h797
5 ай бұрын
I agree with some other commenters that while the explanation of and argument for rotors and bivectors is good, the criticism of quaternions is misplaced and sometimes hypocritical. For example, you complain that the right-hand rule is an arbitrary convention (and it is); but the sense of rotation of the xy plane is equally an arbitrary convention, as is that of the bivector x ^ y. It may be easier to remember, but it's still arbitrary, like the sense of subtraction or function composition. By all means, explain how geometric algebra is a useful tool. Or explain how quaternions ought to be taught better. But if you want to criticize other tools, you'll have to be fair and even-handed about it. Instead, the title of this video descends to provocative clickbait. The video would be better without it.
@yurikaneumi8597
6 ай бұрын
i'm afraid this video presents a skewed perspective on vector algebra in particular, it lumps together hamilton's quaternions and gibbs's cross product, but gibbs and heaviside developed their approach in opposition to quaternions with quaternions you don't use the cross product but its quaternionic equivalent: the hamilton product, better known as just "multiplication" i'd recommend this vid to get some of the missing context and history: kzitem.info/news/bejne/wHeXtXp5pWSam5gfeature=shared from what i understand, clifford algebras are like a third way that's supposed to reconcile, supersede and generalize both quaternions and gibbs vectors rather than a mere alternative
@MadocComadrin
Жыл бұрын
I may be a few years late, but I'm not really convinced. Here's why: - The isomorphism between the 3D Rotors and Quaternions seems boring (as you pretty much admitted in your intro to the article/video). - The argument that Rotors are better because they generalize to higher dimensions in unconvincing. In nearly all 3D engines, from a software developer perspective, YAGNI. Computationally, if you're going to implement dimension-as-a-parameter Rotors, I find it highly unlikely that the code would be as efficient for 3D-only unless you specifically code for the case. - I'm not sure the slightly (imo) easier geometric intuition is worth the extra algebraic machinery. Somewhat tangentially, I also find the idea that this presentation is "from scratch" somewhat false, as the exterior product and geometric product are introduced ex nihilo (essentially for the former and totally for the latter) and given a geometric interpretation. How is this any different than introducing the Quaternions ex nihilo and giving them a geometric interpretation?
@ChrisDjangoConcerts
2 жыл бұрын
Very good video ! I learned new things while already familiar to the subject Good job Marc !
@DougSweetser
3 жыл бұрын
Let's remove every 3D Engine. The only thing that is of interest to me is 3D space-time engines. Build time in from the start, not next_frame() or some kind of looping mechanism. The scalar is TIME. Quaternions are necessarily dynamic. This is the root reason why putting something necessarily dynamic into a static box feels like a hack. It is a hack. What then is (0, 0, 0, 0)? That is an observer at here-now. (0, 1, 0, 0) is a point at there_i-now. If a signal is sent from there_i-now to the observer, when will it arrive at the observer's here-future? (0, 1, 0, 0)(0, 1, 0, 0) = (-1, 0, 0, 0). The here-future for an observer has a negative scalar for the future. The negative value is why no one has lived any moment of their life in the future. The only thing that increases is the amount of our past. And our here-past does not change which will only happen with a positive number, the negatives flip signs. I suspect that idea will be less popular than the right-hand rule. Full disclosure: I own quaternions.com. My hobby is to take claims that things cannot be done with quaternions, and then just do it anyway.
@blinded6502
2 жыл бұрын
You better be renaming your website to rotors then, lol, since they are more general than quaternions are at describing rotations Also watch a video called "Swift introduction to geometric algebra"
@samisiddiqi5411
4 жыл бұрын
Curiously, what does the fourth dimension mean for motion in quaternions?
@FiremarkPl
10 ай бұрын
ijk dimensions are for "heading" of the object and fourth dimension is for rotation around the ijk vector. Btw this is funny: en.m.wikipedia.org/wiki/Axis%E2%80%93angle_representation
@trueriver1950
3 жыл бұрын
The case for quarternions in mechanical motion is greatly enhanced by special relativity, because throughout SR time and space turn up squared but with opposite signs. One approach is to just write the formulae with three minus signs. Another is to always multiply times by ic (the square root of minus one times the speed of light). The most elegant solution is to bundle the "imaginaryness" into the spatial coordinates giving quarternions where the real component of time-distsnce (or of energy-momentum) is time (or energy) and the three imaginary components represent the three spatial components the spatial separations (momentum). This produces a delightfully simple version of the otherwise complicated expressions that relate how a moving and stationary observer respectively measure energy momentum, spatial separations, time differences. As seen from a moving observer, the transformed values are simply a rotation in a plane containing time and one spatial direction. The maths looks identical to any other rotation. If you never intend to incorporate relativity into your physics then I agree rotors make more intuitive sense than quarternions. But I have never seen the same represented using rotors. Until I do, I am not convinced it is possible, and therefore in my mind there remains a place for quarternions, even if that place is not in the coding of gaming engines and virtual reality.
@user-hh5bx8xe5o
3 жыл бұрын
Check en.m.wikipedia.org/wiki/Spacetime_algebra for a treatment of space time with geometric algebra
@SpaghettiToaster
3 жыл бұрын
"Until I do, I am not convinced it is possible, and therefore in my mind there remains a place for quarternions, even if that place is not in the coding of gaming engines and virtual reality." They're isomorphic so clearly it must be possible.
@blinded6502
2 жыл бұрын
Bruh. There's a literal branch of spacetime algebra in geometric algebra, that does exactly that.
@person1082
2 жыл бұрын
lorentz transformations can be expressed as a single rotor
@angeldude101
Жыл бұрын
True, there is only one plane in 2D to rotate within, however there are also infinitely many points in 2D to rotate around, unless you're restricting yourself to rotations around the origin, in which case the origin itself is the only point to rotate around. Also who said anything about rotating around a line? 2D lines are mirrors, not rotation axes. Extending to 3D, which this does give back the idea of an "axis of rotation" (which _is_ a line when in 3D), I'd still argue that they're more clear than quaternions since the direction is still encoded in how you write the basis: xy, yx, yz, or zy instead of i or -i.
@IElial
3 жыл бұрын
Nice video ! I feel like I am still unaware of more and more stuff the more I learn new one. I heard of quaternion reading of book about DirectX 9 back in the days, without totally understanding it beyond that it is better because it solve gimbal lock. And now I discover there was a whole algebraic side developped end of 19th Centurty as a better Quaternion solution !
@8cto289
5 ай бұрын
10:14 i know this video is four years old but can anyone explain how he magically turned this into a*b + a^b?
@georgeweller1
3 жыл бұрын
Rotors might be a good learning tool, but theres nothing wrong with Quaternions. If a person doesn't understand the maths behind rotations then regurgitating it in a slightly different way isn't really going to help.
@blinded6502
2 жыл бұрын
Rotors have far better maths behind them. They are built from reflections, after all. And reflections have good few properties, that quaternions simply do not explore.
@codatheseus5060
6 ай бұрын
I actually understand the quaternion stuff and it's not as complicated as it seems, but yes geometric algebra is easier to learn and work with
@AlbeyAmakiir
2 жыл бұрын
So... from the perspective of an animator or game developer, would this look any different, or is this all "under the hood"? Who is using this?
@fiveoneecho
3 жыл бұрын
This reads like a derivation of quaternions lol
@angeldude101
3 жыл бұрын
That's honestly the real power of using rotors. It lets you rederive quaternions, as well as complex numbers, though a simple process that's easy to follow. Geometric Algebra in general doesn't really let you do anything _new_ compared to existing techniques, but it can vastly help demystify them.
@lazerpie101
10 ай бұрын
where does the 'a' in a 3D rotor come from? edit: after skimming the comments in the code, it is the rotation around the bivector defined by the latter 3 elements.
@rotgertesla
2 жыл бұрын
I really like the interactive article you provided with your video! Very good idea. Suggestion : it would be nice if we could pause the animations in the interactive doc
@davidwright8432
3 жыл бұрын
'Quaternions are taught at face value. We just accept their odd multiplication tables and other arcane definitions and use them as black boxes that rotate vectors in the ways we want'' Not where I went to school! (University of Waterloo, Ontario). They were taught in the context of their algebraic structure - and explicity why the myultipliction rule was so 'weird'. That was in a class of pure, and pplied, mathematicians.
@aetheruszhou1526
3 жыл бұрын
I feel there are many concepts I don't know. Axial vector? Bivector (or by-vector)? What does that ^ operator mean? I think it could be better to explain those things first or at least show how to spell those things so that we can google.
@charetjc
3 жыл бұрын
Yea, the outer product confused me, too. With dot product, I understand that `V dot A = |V||A| cos(θ) = V.x * A.x + V.y * A.y`. That equality defines a relationship between the dot product and scalar algebra, the latter of which I understand well. With this video, the outer product is just a "thing" that sits in the equation and takes up space. Hopefully, all the formula for geometric transformations eliminate the outer products from the result, cause I fail to understand what to do with them otherwise. Same with bivectors.
@plus-sign
3 жыл бұрын
You can use the equation *v* ^ *B* = 0 to solve for a span of vectors *v* spanning the subspace represented by blade *B* . The ^ symbol here denotes the exterior product (wedge product), which some also call by the name "outer product". A k-blade is a mathematical object formed by the outer product of k vectors. Particularly, a 2-blade is called a bivector, 3-blade is called trivector. The formal definition of the exterior product is in fact just a mathematical tool (with geometric implication of representing subspace, i.e. planes for bivector): For vectors *u* and *v* , *u* ^ *v* = 0 if *u* = k *v* (corresponds to *parallelism* in Linear Algebra, i.e. parallel vectors has 0 as exterior product. ) Distributivity: *u* ^ ( *v* + *w* ) = *u* ^ *v* + *u* ^ *w* Associativity: ( *u* ^ *v* ) ^ *w* = *u* ^ ( *v* ^ *w* ) Unit vectors: *i* ^ *j* = *ij* for orthonormal basis. ( *ij* is in fact the *geometric product* ) There are also more complex concepts like a dual (representing perpendicular subspaces), left and right contractions... You may find more details in Wikipedia (Geometric Algebra) and Google book (Geometric Algebra for Computer Science, Dorst, 2007)
@JivanPal
3 жыл бұрын
It's literally all explained in the video. Is there anything in particular that you feel like you are not understanding about these concepts.
@moonmakesmagic
3 жыл бұрын
I'm still using quaternions because, well, existing APIs, but this was very well explained and helpful
@zaq1320
3 жыл бұрын
This is great! Some really cool vector math I didn't know about. So, while I have no doubt that these work, I'm struggling to understand how they would serve artists better in a 3D program. The math being prettier under the hood doesn't mean much if it doesn't actually improve the production process, and I can't actually tell exactly what implementing these with all degrees of freedom would look like. Say your A vector is just fixed to some arbitrary unit axis (of the artist's choice). Makes sense. The artist now has to define another point in 3D space, with three numbers we can then normalise to the B vector. Great. I struggle to understand how this doesn't just amount to a "swing" rotation, which we then add a "twist" rotation to afterwards. Swing and twist rotations are already implemented in blender (not sure about maya), and are very useful - if that's what an implementation of rotors shakes out to, then we already have 'em, although only in the drivers. They're great! They are computed from quats, though. If rotors kind of naturally decompose to swing and twist that's convenient for the developers, which is nice I guess. For an artist I don't imagine it would make too much of a difference.
@JivanPal
3 жыл бұрын
*_"I'm struggling to understand how they would serve artists better in a 3D program."_* - It doesn't, that's the whole point of the video. Quaternions work just fine, and the author points out that they are isomorphic to rotors. That is, they're functionally one and the same. The point of considering rotors is that they are more intuitive to work with. It's a mathematician's interest, not a software engineer's. If you were to implement both quaternions and rotors in code, the implementations would be equivalent. If, as a programmer, you are working with a physics library that implements its functionality with either quaternions or rotors, but abstracts that away from you via an API that makes no mention of either, then the underlying math is not a concern. However, if you are working directly with quaternions or rotors, then the latter is most likely favoured, because they are easier to intuit about.
@zaq1320
3 жыл бұрын
@@JivanPal Yeah, I figured it seemed like a purely mathematical/software engineering exercise and again, from a back end perspective this is really cool. The title does say we should remove quaternions from every 3D engine, though, I think it’s not unreasonable to infer a claim about improving the work of 3D engine users from that, right? I’m just always on the look out for better ways to handle rotations as a technical artist.
@JivanPal
3 жыл бұрын
@@zaq1320 *_"The title does say we should remove quaternions from every 3D engine, though, I think it’s not unreasonable to infer a claim about improving the work of 3D engine users from that, right?"_* - Ehh, semi-clickbait. Seems to me like the author is merely advocating that such a change should take place because computer physics/graphics courses should be teaching students about rotations from the rotor perspective rather than the quaternion perspective, in order to aid intuition and understanding as to what these things are and why they work. *_"I’m just always on the look out for better ways to handle rotations as a technical artist."_* - You're probably not going to find it! The APIs and optimised hardware already exist, nothing better will appear (at least not anytime soon; mathematics has pretty much got this area covered already).
@joojaa3927
3 жыл бұрын
For an artist this gives a way for you to better visualize the rotation. Not well but better. This in turn means that we can eventually work out a more workable way of controlling the rotation with animation curves. Since eventually the visualisation will lead to a understanding. Theres no way you can directly manipulate the quaternion values in a meaningful way. In addition its hard to work with quaternion in physics context. So that could mean better user interfaces for inverse simulations. Inverse simulations would allow us to have better controllable simulations in conjunction to keyframes. But ultimately having more of your programmers actually understand the math gives ground for more tools, more tries and better successful tools for you to use.
@joeedh
3 жыл бұрын
@@JivanPal Honestly I'm not convinced that either approach is particularly intuitive. I don't care if geometric algebra makes more sense in >3 dimension, for 3d it seems to add complexity without value.
@tomoki-v6o
5 ай бұрын
In solid mechanic there is what we call the Mohr circle where the transformations double the angle !
@elfeiin
Ай бұрын
You don't go into any detail about the concrete representation of rotors...
@fredeisele1895
3 жыл бұрын
When you say they quaternions are isomorphic with rotors, I think you mean adjoint.
@nietschecrossout550
3 жыл бұрын
Are there any benchmarks on what can he computer faster? 4D 32bit floating point numbers smell of superscalar optimisation, do they not? To the best of my knowledge with a length 3 vector youll end up with 4 byte of wasted memory on your GPU per operation.
@JivanPal
3 жыл бұрын
It sounds like you're advocating the use of 3D vectors rather than either quaternions _or_ rotors. If that's the case, you need to realise that the whole reason quaternions are used in computer physics in the first place, rather than 3D matrix algebra, is that matrix algebra suffers certain problems (such as gimbal lock when interpolating rotations) that the former overcomes. As for computational time/complexity, there is not much overhead. Multiplication is fast, and these days we have ICs expressly designed to do this kind of computation as fast as possible. That's what in your GPU. As for memory, consider that power-of-2 multiples of allocated memory are generally preferred because of chip/DIMM design. That is, if I have a 3D vector data structure comprising three 32-bit numbers, it is likely that when I instantiate multiple instances of it, they will be aligned on 64-bit or 128-bit boundaries rather than 32-bit boundaries anyway, so you don't actually save any memory from a practical standpoint.
@johnterpack3940
11 ай бұрын
I understood none of that. Somehow, it still seems more efficient than quaternoins.
@rb8049
8 ай бұрын
As far as I can tell these are identical. Neto’s of learning is different. In the end it’s the same.
@MACMAN2003
Жыл бұрын
i wish my euler angled brain was smart enough to understand this
@Alexander_Sannikov
3 жыл бұрын
I don't see an explanation of how exactly you define a geometric product, and more specifically, how do you add its scalar part with its bivector part. Because if you define geometric product as an operation that acts on two vectors and produces a scalar + bivector, how do you later claim that reflection is R(v, a) = v - 2*(v*a)a = ava, where you have a vector on the left side of the equation and a (bivector+scalar)*vector=trivector on the right side?
@user-hh5bx8xe5o
3 жыл бұрын
In the video, the geometric product is defined on vectors by splitting it into the symmetric part and antisymmetric part. The first is identified with the dot product and the second with the exterior product. Note that conceptually, the geometric product on vectors is the sum of a contraction (the output has a lower dimension than the inputs) and an extension (higher dimension than the input). In practical terms, the geometric product can be computed from the relationships of the basis vectors. In the Euclidean case described in the video, a vector multiplied by itself is 1 and multiplied by any other basis vector is 0 (Kronecker's delta). Other elements (bivectors, trivectors, ...) products can be computed by the rules on vectors and the antisymmetry of the basis bivectors (e1*e2 = - e2*e1) which allows to swap terms to cancel duplicates (e2*e1*e2 = - e2*e2*e1 = - e1).
@stefanvasilev2013
2 жыл бұрын
A valid remark. As already noted, it's defined as a sum but the sum is between different entities. To make that valid you need to introduce another space where both entities live, which was not done in the video, losing rigorousness. Another miss was the lack of proof why this product is invertible, there were only (questionable) heuristics. Describing the whole thing consistently would've been more work than just explaining how to use quaternions in a clear way, so it would've defeated the purpouse of the video I guess :)
@undeadpresident
4 ай бұрын
Flagged for Anti-Symmetrism!
@edomeindertsma6669
2 жыл бұрын
11:42 that 'property bundle' reminds me of quaternions.
@ReginaldCarey
3 жыл бұрын
If this helps to visualize the operations fine. If it does not change the computational complexity, then it’s just an alternative formulation and computationally identical. Thus removing quaternions in favor of this alternate approach is a fruitless endeavor. The same would be said if the argument was going the other way.
@JivanPal
3 жыл бұрын
The point of the video is intuition and understanding, not computational simplification.
@ReginaldCarey
3 жыл бұрын
@@JivanPal sure, I get it. This can be more approachable than quaternions. My reaction is more to the video title. If there is a computational benefit, it makes sense, otherwise it does not. I admit that I was lost seeing the reduced complexity/improved understanding in rotors vs quaternions. But that’s irrelevant. This vid does make me want to consume others on this topic though so big plus for that! Vector and Tensor Calculus for example, really adjusted my thinking of mathematics and how it can be applied.
@porky1118
3 жыл бұрын
Not really. It's only the same for 3D. But you could write your types dimension generic. Some programming languages allow generics over constants as well. Basically only C++ right now. (and soon also rust, hopefully; also some small experimental languages maybe like Scopes) In such languages, you could write your vector type like this: Vector But you can't have dimension generic Quaternion. It's always Quaternion You could define rotor types, though, which you can define similar to vector types: Rotor (3D Rotors, Quaternions). Or you use 2D rotors for your 2D game using the same math library: Rotor
@ReginaldCarey
3 жыл бұрын
@@porky1118 regardless of language choice, or representation of quaternions or rotors or other data structures the question is how many computations are required to perform an operation. Which algorithm is most efficient in terms of memory and computational steps. If rotors offer an advantage over quaternions then they should be adopted. If they are of equal complexity, it’s fruitless to move away from current implementation. en.m.wikipedia.org/wiki/Big_O_notation
@porky1118
3 жыл бұрын
@@ReginaldCarey I know about O-Notation. I did study computer science at university. Efficiency is not the benefit of quaternions. They are basically equivalent in implementation. If you already have some 3D math library, it doesn't make much sense to use rotors instead. You could rename the Quaternion type to Rotor3 or something like that for consistency and also add some Rotor2 or whatever, but doesn't really seem useful. It's more about how you think about your math code and how you organize it. Bivectors are more important than quaternions, or at least as important, I think. When having both, you can do a lot of stuff you can't when just having vectors an quaternions. Most important about bivectors: When you use bivectors instead of axis vectors in 3D, you can use bivectors in the same places in 2D or 4D. It doesn't matter if you call the quaternions rotors. Rotors might just be a bit more consistent. Especially if you want to write some new math library, you might consider adding rotors instead of quaternions and implementing them in a dimension generic way, which allows you to define a lot of algorithms in a dimension generic way as well. Often you could use vectors instead of bivectors in 3D, or scalars instead of bivectors in 2D, but then you need to learn two different ways of thinking for 2D and 3D Get the normal: to a line in 2D: Swap x and y of the line direction, negate one of them. to a plane in 3D: cross product between two lines on the plane How it works in GA: 1. multiply all lines on the subspace using the outer product 2. multiply the result with the pseudo-scalar
@aniksamiurrahman6365
2 жыл бұрын
I'm not getting a simple thing - why the hell so many mathematicians have a problem with such a beautiful system? Geometric Algebra provides a way to make field extension for real numbers for any dimension. That alone is a beautiful thing, along with being very mathematically pleasing. The problem might be, that a good deal of geometric algebra enthusiast aren't mathematician or well versed in mathematics and lack fundamental understanding of vector space (like how it's just an Abelian group over a field and nothing else, and no geometric algebra doesn't make this definition unnecessary, it rather fits beautifully into it). Thus, their half-assed enthusiasm might feel rowdy to actual mathematicians.
@thestemgamer3346
2 жыл бұрын
Geometric Algebra enthusiasts are mathematicians. It's called a clifford algebra and there is a subalgebra called the grassman algebra which is common in differential forms. This construction is used more prevalently in physics however as mathematics doesn't always deal with structures where clifford algebras are relevant. In particular clifford algebra and lie algebra become handy for calculations on Riemannian manifolds and lie groups. This is only really relevant to physicists working in classical mechanics, engineers. There are a few relevant fields of math like differential geometry, but it isn't quite relevant to modern research. A lot of modern research in mathematics delves into representation theory, category theory, and homotopy type theory. Clifford algebras are only loosely relevant to representations of lie groups.
@ongamex
3 жыл бұрын
I just do not see why is this better/different form quaternions. It is a different name for the same thing. Do you have a coded example, where I can see the differences in use (not the implementation or Rotors, for what I saw it is just quaternions with different wordings)? One thing I always wanted to to do with quats is to apply a "partial" rotation, something like "take N% of the rotation represented by q1 and apply it to q0". Is this possible with rotors? With quats you basically have to extract the axis and the angle and then contruct a new quaternion. Can a rotor represents rotation outside of [0;360deg], for example a 720deg rotation, where I can take N% of it? I just don't see why and how this is better then the established quaternions. It is easy to extract the plane and the angle of rotation from a quat. Multiplication and inverses/conjugates are quite easy. lerp/slerp-ing them is easy.
@marctenbosch
3 жыл бұрын
It's better because rotors don't come out of nowhere like quaternions do. Here's the code: marctenbosch.com/quaternions/code.htm
@porky1118
3 жыл бұрын
Quaternions and 3D rotors are just the same thing. There's nothing you can do with 3D rotors, that you can't do with quaternions by themselves. There are two advantages of rotors. 1. Rotors are dimension generic. So you could write some utility method for rotors in general and it works for rotors of any dimension. 2. If you also have other GA types like bivectors, rotors show their true power. For example you can create a torque by mutliplying two vectors using the outer product and get a bivector, which you use as torque. Then you compute the exponential function of that bivector and get a rotor, which you use to rotate the object. Then you multiply the rotor by another rotor to change the view. So rotors aren't that special themselves, but GA is.
@ongamex
3 жыл бұрын
@@porky1118 Aha, that dimension generic thing is the key. Thanks for the clarification. Maybe If I delve more into physics they will start making sense.
@porky1118
3 жыл бұрын
@@ongamex A simple example in physics, why you would prefer GA is torque (angular momentum). In 2D you would probably represent angular speed using a scalar, in 3D you would use an axis vector, where the magnitude represents the velocity. In GA, you would just use a bivector. A 2D (x, y) bivector has only one component (xy), so it's similar to a scalar. In 3D (x, y, z) it has 3 components (xy, xz, yz), so it's similar to a axis vector. And in 4D (x, y, z, w) it has 6 components (xy, xz, xw, yz, yw, zw). You might need it for space-time (relativity).
@porky1118
3 жыл бұрын
@@ongamex A simple example in physics, why you would prefer GA is torque (angular momentum). In 2D you would probably represent angular speed using a scalar, in 3D you would use an axis vector, where the magnitude represents the velocity. In GA, you would just use a bivector. A 2D (x, y) bivector has only one component (xy), so it's similar to a scalar. In 3D (x, y, z) it has 3 components (xy, xz, yz), so it's similar to a axis vector. And in 4D (x, y, z, w) it has 6 components (xy, xz, xw, yz, yw, zw). You might need it for space-time (relativity).
@VeteranVandal
7 ай бұрын
Geometric Algebra will win and Clifford will be avenged. Gibbs and Heaviside were wrong, but they didn't know we had a better tool.
@yurikaneumi8597
6 ай бұрын
out of curiosity: do you know what gibbs and heaviside's views on clifford algebras were if any?
@peterwilson69
3 жыл бұрын
I built my own 3D engine from scratch and never needed Quaternions; I could solve every problem I needed without them. I built my own flight simulator with advanced camera control system able to view from outside the aircraft, in cockpit and ability to fly around, all while the aircraft was doing it's own thing. Never had a problem.
@porky1118
3 жыл бұрын
Do you have gimbal lock and just don't have a problem with it? Would it be easy to make your simulator work around a planet?
@asdfghyter
3 жыл бұрын
How do you avoid running into issues at the poles without quaternions? Like rotations around the, x/y/z axes? Or are you using something equivalent to quaternions?
@peterwilson69
2 жыл бұрын
@@porky1118 Gimbal lock occurs when you let a user “look down” the UP axis. So just rotate the UP axis when they start looking at it. Ie. Rotate the entire reference frame. If you nest reference frames, then you easily and simply mimic the behaviour of quaternions, while still using easy to understand transformation matrices/maths. If you are tasked with making a pilot look out a window in the direction of flight, while flying in a different direction, while allowing their pilot seat to be moved at the same time as plane is banking taking into account the curvature of the Earth the plane is flying over, then all these nested transformations become trivial and fast, and more importantly for a programmer, easier to debug, extend or change behaviours. Ie. Do all the above, but add a virtual camera following near the aircraft, that keeps the plane in view, while also tracking an incoming missile (to increase drama and let this virtual viewer see the drama unfolding from a unique perspective) Adding all these transformations is easier without worrying about quaternions. Don’t be bullied by others into making you believe you need them - you don’t! There’s more than one way to do things. Plus, the more advanced your camera system is, the more options you have for a user never “wanting” to look down the UP vector. Make it boring to look at, never let the user even rotate their point of view “to” a gimbal lock situation. Allow them to get close (if they insist) but never fully locked. Always make the user look at a dummy object, but position this dummy object in such a way it helps guide the experience for a user. Sorry, could talk forever.
@peterwilson69
2 жыл бұрын
@@asdfghyter yes, very trivial to fly anywhere around a planet. But you must learn to nest transformations, and be able to write them out to help debug or plan. Ie. Pilot head (ie the camera) = Earth surface location transform * Aircraft_Location * Adjustable_seat_position_within_aircraft * Orientation_of_pilots_head. camera = earth * aircraft * seat * look Each multiplication step is a 4x4 matrix. The result is a 4x4 matrix which then gets applied to all geometry (landscape, aircraft, flight attendants walking down aisle etc) You can nest these transformations as deep as you want without paying any penalty in terms of speed. Each transform has a gimbal lock, the pilot sitting in his pilots seat, can still have gimbal lock if he looks directly UP at the cockpit ceiling.But there’s ways to avoid this simply by directing his attention “close to up” with a bias of looking forward towards towards the cockpit window. Or, just rotate where UP actually is, which then fully mimics quaternions, but then won’t be as intuitive for a user experience. I would urge you to perform simple experiments in nesting transforms.
@blinded6502
2 жыл бұрын
Just... Use geometric algebra please. It simplifies a lot of things. A lot. Of things. Interpolations it generates are absolutely perfect, and derivations with it's use only take a line or two of code. If you need me to, I could explain GA in layman terms.
@L1Q
3 жыл бұрын
Watching video multiple times and reading the article still does not make it clear to me what kind of struct would be used to represent a bivector. If vector a can be derived from vector b and and their geometric product ba, how can this be done provided those are 3d vectors and geometric product being a sum of two scalars (dot product and outer product)? From what I can see in other sources the outer product is not actually a scalar, it's a bivector. But your explanation suggests strongly you can only canculate scalar value from it. No further info on how it might be stored. In the 2d example it seems the value of bivector is just the sinus between two vectors, a scalar. In 3d examples it's sum of areas for each basis planes, sum of scalars => a single scalar. Even if bivector *can* be represented as sum of those basis, there is no telling how in the world it can keep enough information for what it promises. This confuses me immensely.
@blinded6502
2 жыл бұрын
In geometric algebra we have coordinates (geometric units), that can square to different values. Usually we have them set up as such: x*x = y*y = z*z = +1 o*o = 0 (ignore this one, it's for translations, lol) Geoproduct (multiplication) between two different units does not give you anything new. They are simply "stuck" together. x*y = x*y (or xy for short) General vector in 3d: a*x + b*y + c*z General bivector in 3d: a*xy + b*xz + c*yz General trivector in 3d: a*xyz (lol) General rotor in 3d: d + a*xy + b*xz + c*yz (scalar + bivector)
@fenix7970
3 жыл бұрын
I am only certain that i am watching something that is above my comprehension.
@BleachWizz
4 жыл бұрын
nice, so if you ignore quaternions and come up with rules to allow you to rotate things in 3D you invent quaternions. shouldn't the outside part be reflected twice thus returning back to the original value? at 14:50
@marctenbosch
3 жыл бұрын
No it's two reflections with different planes of reflection.
@AkamiChannel
Жыл бұрын
Can bivectors be used for smoothly interpolating rotations?
@angeldude101
Жыл бұрын
Yup! For the same reasons that quaternions are good for spherical interpolation.
@badradish2116
3 жыл бұрын
wish you had opened with a stronger, maybe concrete example of why this is better than quaternions
@JivanPal
3 жыл бұрын
Explanatory power and intuition - that's it.
@porky1118
3 жыл бұрын
The main reason is, they are generalizable to other dimensions like 2D and also higher dimensions.
@JordanWeitz
4 жыл бұрын
Has @3Blue1Brown seen this? So good.
@kevinportillo9882
3 жыл бұрын
I was thinking about this too! It seems like this should be the norm since it's so generalized
Yes, I hear you. Especially with other competing systems, like tensors. Especifically for rotation there is also the added complexity of Euler parameters vs Rodrigues vs Cayley-Klein and a few others...
@blinded6502
2 жыл бұрын
You don't need complexes/quaternions/octonions in geometric algebra. All you need are blades - reflections along different axes. They compose everything else, including rotors.
@danielb270
3 жыл бұрын
The reason Quaternions are used is because they can be computed and represent as a 4x4 matrix - matrix addition and matrix multiplication is what GPUs specialize at. ALL 3D graphical 3d applications use a single 4x4 matrix to represent position, rotation and scale. And it is used to perform screen projection. One way or another to represent rotation inside the engine quaternions are the optimal solution as it costs a single matrix addition. If you want you can create whatever wrapper level you want, but at the end YOU MUST provide 4x4 matrix to the GPU for rotation (unless you develop a new hardware architecture, graphics API, and with a better performance)
@joeedh
3 жыл бұрын
GPUs are SIMD (single instruction multiple data) machines. They don't require 4x4 matrices per se. Some engines will work in quaternions for real-time skinning, only using the final camera matrix at the end..
@danielb270
3 жыл бұрын
@@joeedh they don’t require 4x4 matrices, but they have hardware specifically for those operations
@blinded6502
2 жыл бұрын
Quaternions are rotors. They are literally rotors, but they are named wrong. And because people don't understand how do they work (in terms of GA behind it), they can't fully utilize them. And there's a ton of features that GA framework provides.
Пікірлер: 686