Show newer

AHHHHHH I finally understand quaternions!! XDD :DD

I always thought they were neat fun thing in abstract algebra and a neat but arbitrary way of representing rotations with unnecessarily extra numbers.

If someone had just said to me this sentence I would have seen how insanely perfect they are!! :D

As rotations, the i/j/k coefficients are the x/y/z components of the axis-of-rotation vector, and the fourth lone number is the amount of the rotation in radians!

#Math #Geometry #Quaternions

@kline I call it SpaceHeaterApp, it turns your computer into a space heater, doesnt even cost any additional hardware!

No in all seriousness its an implementation of my algorithm I invented for algorithmic trading.

The app is now officially 100% multithreaded with very little thread contention.. Man that wall of 100% CPUs (32 of them) is a beautiful sight.

🎓 Dr. Freemo :jpf: 🇳🇱  
So my app is running only across 32 cores so only 32 threads in action (well its python so multiprocessing)... yet it has 3,201 lock objects total ...

@GodfreyHendrix Algorithmic trading, specifically an algorithm i developed that is applied to that purpose. It works in real time and sequentially, so not something most people would think could be parallelized, and for real-time it didnt need to be. But was far too slow for backtesting so parallelization was needed to backtest.

@Zest

Yup relativity as a whole is definately pretty much experimentally proven at this point even if not all of its individual components have direct evidence.

@Science

@Zest

The riddle/paradox can be found here:

en.wikipedia.org/wiki/Ladder_p

> but either way what I'm curious about is why saying that the things literally happen at different times relative to different places makes more sense than just saying "well the light took this long to get here so we're just seeing it now".

The reason is because its the only way the other things make sense without there being a paradox... If time **actually** dilates (and we have experimental evidence that proves that, it was proven on GPS systems for example) that means the actual time expiernced by different frames of reference must be actually different. If the time is actually and literally different then clearly the events must also occur at different times.

Because all 4 concepts, time dilation, velocity dilation, length constriction, and simultaneity are all interdependent on each other then either they are all an illusion , or they are all real, if you mix and match it you get logical paradoxes that make no sense. we can and have proven that time dilation is real as well as velocity dilation, as we can prove it in particle accelerators, so we know that the others must be real as well.

We have also seen length contraction inside colliders (in this experiment it was observed that gold ions were contracted to a thin disc like shape: physicsforums.com/threads/mode )

However directly and experimentally confirming the ladder paradox itself, thats much harder and I know of no direct evidence of that. But as i said with the other elements being well proven it is the only logically consistent conclusion and matches the math.

@Science

So my app is running only across 32 cores so only 32 threads in action (well its python so multiprocessing)... yet it has 3,201 lock objects total instantiated to accomplish that with minimal read/write contention....

I can honestly say this is the greatest number of thread locks instantiated at a single time that I have ever needed in an application before.

@Zest

Yea, the thing to remember about relativity that is really the trippy part is that you arent just seeing things in the past because light takes longer to reach you (though that is how we talk about it)... but rather things far away from you are literally farther back in time.. with lightening we know the lightening hit much sooner than we hear it, and we think the same way about light. But in reality its that time is warped (or at least this is how I think about it, you wont usually hear scientists describe it this way)

Just think about it in simple terms, if im on a planet around a star that goes super nova and my clock was synced with the clock on a spaceship that is 1 light year away.. if i see the star go supernova on 2020 the space ship according to its internal clock (its stationary by the way) will record the event as happening at 2021 because it took a year for the light to get to him. We usually say its just time delay of light propagation as its easier.. but in a sense it literally didnt happen for that guy on the spaceship until 1 year later.

When you think of "what you see is literally the truth" and not just some optical illusion when it comes to special relativity then it all starts to make sense.

Its no different with the other stuff, one could say that time dilation isnt really happening but instead explain it by the fact that its like a doppler effect where things appear slowed only as an optical illusion because the thing is moving away from you as it produces the image so the "video" gets "stretched" out (like it would with sound).. but that isnt really the case, it is **actually** happening... that is true of everything, including simultaneity.

Once you understand all this weird things you see that you want to dismiss as optical illusions are literally real, then it all makes way more sense.

@Science

@Zest

Its actually not that surprising you see this happen every day with other things, you just never see it happen at such short distances (which is only possible due to the high speeds)...

Imagine sound instead of light, which travels slow enough you can actually see the delays and therefore is easier to conceptualize. if you are right in the middle of two lightening strikes then you would hear them at the exact same moment, assuming you only used your hearing and not sight you would assume they were simultanious.

Likewise imagine you are much closer to one than the other, you would hear that one almost immediately and might not hear the other for a few seconds. Even if they happened at the same time it would seem to you, with your different frame of reference, as if they happened at significantly different points in time.

That's all that is happening here, just in a more confusing way because it isnt due to you being in a physically different location but because time and space itself is warped. But in principle its the same thing.

@Science

@freemo @Science woah! but why though? that's actually really perplexing, I don't know of any reason why it would happen that way

@Zest

Its actually not that surprising you see this happen every day with other things, you just never see it happen at such short distances (which is only possible due to the high speeds)...

Imagine sound instead of light, which travels slow enough you can actually see the delays and therefore is easier to conceptualize. if you are right in the middle of two lightening strikes then you would hear them at the exact same moment, assuming you only used your hearing and not sight you would assume they were simultanious.

Likewise imagine you are much closer to one than the other, you would hear that one almost immediately and might not hear the other for a few seconds. Even if they happened at the same time it would seem to you, with your different frame of reference, as if they happened at significantly different points in time.

That's all that is happening here, just in a more confusing way because it isnt due to you being in a physically different location but because time and space itself is warped. But in principle its the same thing.

@Science

@pganssle do you know of any sort of atomic-float or atomic-int implementations, sometimes called thread safe counters?

I am not talking about jsut implementing my own lock around it, thats what I'm about to do. Some languages make the "+=" and "++" operators atomic at a low level so youc an do it without needing to lock and thus getting performance improvements... im not seeing anything like that in python.

@Zest

The idea is called simultaneity. What that means is that two events that appear simultaneously to one observer (in one frame of reference) is not necessarily simultaneous in another frame of reference.

In this case the two events are the closing and re-opening of each of the barn doors. While that occurs simultaneously from the perspective of the barn and the person doing it, from the perspective of the ship they are not. So while the ship's perspective looks like it cant fit into the barn, and in reality it cant fit in the barn from its perspective, it doesnt have to. From the ships perspective the doors are never closed at the same time. one door closes, then opens, then the other door closes and opens, all at the right time to ensure the ship passes through without crashing through a door.

So while from the ships perspective the ship was never enclosed (both doors shut with it inside) in the too-small-to-fit barn, from the barns perspective where it is more than big enough the ship was, in fact, enclosed inside for a moment.

@Science

@Zest

The idea is called simultaneity. What that means is that two events that appear simultaneously to one observer (in one frame of reference) is not necessarily simultaneous in another frame of reference.

In this case the two events are the closing and re-opening of each of the barn doors. While that occurs simultaneously from the perspective of the barn and the person doing it, from the perspective of the ship they are not. So while the ship's perspective looks like it cant fit into the barn, and in reality it cant fit in the barn from its perspective, it doesnt have to. From the ships perspective the doors are never closed at the same time. one door closes, then opens, then the other door closes and opens, all at the right time to ensure the ship passes through without crashing through a door.

So while from the ships perspective the ship was never enclosed (both doors shut with it inside) in the too-small-to-fit barn, from the barns perspective where it is more than big enough the ship was, in fact, enclosed inside for a moment.

@Science

@pganssle It certainly is 90% of why I am critical of the language.. Its also my biggest gripe with haskell... breaking backwards compatibility is one thing I expect my languages not to do and if they do it im very hesitant to use them ever again, at least if its a major break.

@pganssle fair, but then all the more reason that my original assertion that it should have been fixed when they moved to python 3, before all the third party apps were rewritten holds true. Trying to fix it after the case, as I said, is anotehr backwards compatability nightmare by the sound of it.

@Zest

No it is something new we haven't discussed, though not of the same nature as the other things. Basically you are making an assumption that doesn't hold true anymore, but it isnt any sort of "dilation" of anything.

@Science

@pganssle Are you saying the issue is that it would break third party libs (if so i suppose you are also saying that third party libs dont tend to work with non-standard python interpreters either?)?

@Zest

> so, from the ships perspective the barn shrinks, which causes a problem, but from the barns perspective the ship shrinks, which doesn't cause a problem, or if it doesn't fit in the first place solves a problem but not from the ships perspective...

Correct

> if it still works when the ship wouldn't fit normally but does at near light speed than it's not like they compensate for each other right?

There is something that compensates for the problem and makes it a non-issue. but your use of the term "for each other" suggests it is the length of one or the other compensating to make the situation work. That is not the case, the lengths as you and i have described them are correct as is and do not change in any way to resolve this paradox.

> maybe... the ship is shrinking for real but it can't tell from it's own perspective?

Well from the ships perspective it isnt shrinking, the barn is, from the barns perspective the ship is shrinking. Both of these are "real" from that perspective. To the barn the ship is really smaller, literally and truthfully. From the ships perspective the barn is literally shorter.

> I don't know, at this point either a hint or you could tell me because I think that's the best I can do lol

Does that count as a hint or shall I give the answer now?

@Science

@pganssle I wouldnt doubt that the GIL is a non trivial problem to fix, especially after the fact.. But it has been done in non-standard python interpriters and franky when it comes to the developers of core languages I do have an expectation that they be the best and are capable of solving really hard problems. If they werent then the language probably isnt a great language as it wont live up to its potential.

Show older
CleverLibre Social

CleverLibre Social is an inclusive social instance for open discussion, learning, and community.
All cultures welcome.
Hate speech and harassment strictly forbidden.