Wolfram Student Podcast S2.5 Ep1: Visualizing Star Fields & Black Hole Mergers

Macy walks through student projects built in Wolfram Language: a starfield visualization at 99.5% light speed using Lorentz transformations, a binary black hole merger inspired by LIGO detections, and current work on the Wolfram Physics Project's Ruliad and observer theory.
Questions this video answers
September 14, 2015.
About 1.3 billion light years.
NDSolve.
Approximately 99.5% of the speed of light.
2018, 2019, and 2020.
Chapters
Hello, everyone, and welcome to season 2.5, episode 1 of the Wolfram Student Podcast. I'm Sam, and today I'm your host. So this is the Wolfram Student Podcast, where every fortnight we dive into a new, innovative project on my high schoolers or undergraduate students using the Wolfram language. So, for this episode, let's welcome Macy, who'll be discussing her projects on astrophysics. Hi, Macy.
Hello.
Yeah, it's great to have you. Just for our audience, do you want to give us, like, a quick introduction about yourself, where you're from, your experience with Wolfram, so on?
Sure. So, as Sam said, I'm Macy, I live in Massachusetts, and I started out with the Wolfram High School summer camp in 2018. I did a project which I'll be discussing a bit today, and I absolutely fell in love with the experience and had such a fun that I came back in 2019 and did another project which I'll be discussing today. And then I came back in 2020, which was during COVID but still fun, even though it was on Zoom. And so that was three years of the Wolfram High School Summer Research Program. And I've gone on to mentor the Wolfram Middle School Summer Camp and TA at the Wolfram High School Summer Research Program. So it's been a long and a long journey. Yep. And I'm currently working on some stuff with the Wolfram physics project now, so.
Yeah, that's really cool. Not gonna say that physics is my strong suit or, frankly, anything that I enjoy, but I don't know, I think it's really cool what you've done so far. And just a question we like to ask everyone when they come on. What do you think is your favorite Wolfram function? Hmm.
That's a tough one. I'm gonna have to go with ND Solve, I think, just because it's come in handy so many times for me that I don't know where I'd be without it.
So just for some context, maybe you should mention what ND Solve does, because I know, but I'm not sure how many people do it.
So ndsolve is a wonderful function in Wolfram, which allows you to solve differential equations, so are not stuck typing everything out for hours on end or doing it by hand, which is even worse, especially when you're working with equations that are incredibly long and terrifying, and then it takes, like, five pages to actually work them out. So it's very handy. You just give it the equation, plug it in, and it will spit out the results.
I remember Doing a project last year that had some for whelp that had some nasty differential equations in it. And I plugged it into indiesel because I was like, I'm not doing this by hand. The answer for me in like a minute. And I was like, honestly, this is the greatest thing ever invented. Right? Yeah. I think normally when we ask people this question, they tend to go for two sides. So one is, like, for very, like, niche functions, like, often or sometimes we have someone, like, go for a very niche, like, geography function or something that they used on their project. And then on the other side of the spectrum, we have people who go like, table. Because, honestly, it's like, the foundation of everything. Right. Or, like, map.
Those are both very reasonable responses, I think.
Yeah. But it's interesting to see where every new person falls on that spectrum. All right, so let's get right into your first project, which is relativistic starfield demonstration. I have zero clue what that means, and I'm very excited to learn. Do you want to taste through it?
Sure. So this was my first project at the Wolfram High School summer Research Program. Stephen Wolfram gave me the idea that if you were in a spaceship like the Starship Enterprise or the Millennium Falcon, and you hit the button and traveled into lightspeed, and what would that really look like? Right? Because when you're watching something like Star wars, and full disclosure, definitely more of a Star wars fan than a Star Trek fan, but I do. I do appreciate Star Trek. I don't want to cause a rift. But when you're watching something like Star wars, right, and you hop into light speed, it's just this giant churning tunnel of something, and you don't really see much when they actually make the jump. Like, the stars just sort of elongate, but there's nothing else to it. And so that's what this project was. And you're traveling here in this demonstration at, like, 99.5% the speed of light. So not all the way, but, you know, enough that we can model it to the best of our ability. And I'm sure, like, obviously looking back, there's things that I would change. But so for this project, we use Lorenz transformations and vector calculus in order to determine what, you know, the universe scape around you would really look like because we're working here with the Doppler effect effect.
Right.
So as you'll see, there's a shift in the color of the stars as they move towards and away from you. And that's redshift and blue shift. And so that's a very common thing in the Doppler effect when you're like, in space, so you have more, I guess, more space to sort of see you're in a wider visual field. We don't really see that as much here with motion. But you do hear the Doppler effect all the time when you hear any sort of siren or like a plane flying overhead starts off quieter, gets louder when it's near you, and then gets quieter again. So that's like an everyday example of the Doppler effect. So we can get into the code a bit here. And this is the very, like, base starfield. I will say that this was done in 2018. And so when we put up the community post in 2018, we didn't have a lot of code to show. It was more screenshots of code and not actually working code at the time. So I do apologize that nothing moves or is that exciting. But you can see just like one of the base blocks of code here. And so what we were doing was saying we're going to have these bodies in space. And so we made a field. So you have some, like, tiny stars in the back and then small stars and then big stars. So the tiny stars are what you see. I can zoom in and it's not gonna. There we go like these little points way in the back. And then the small stars are like these little guys. And the medium stars closer to the front. And then just created a manipulate. So you could increase the number of stars here, which, as I said, unfortunately, can't do right now. And then you could also change the seed too. So how many would spawn when you ran this text? And then this is the time function. So basically what the time function would do is you would play it and the stars would start moving towards you, which is pretty cool. But go ahead.
No problem. I love your naming convention for these stars. But so are you saying, like, when you start the time function, this is showing a visualization, like, as you move closer towards the stars, what they look like as they're, like, passing by you. And is this specifically at light speed or is this like just a model of what a moving star field would look like?
This isn't at light speed yet. So this is like just the moving starfield and you're moving into it. So right, like if you're piloting the Millennium Falcon, you're, like going into the starfield. So they're all. All the stars are going to be coming towards you.
Okay, so do you encounter the doppler effect, like because of like your movement towards them. Like how does the Doppler effect play into this?
So it's not as obvious. Like if you were just meandering through space, right, you're not traveling at a really, really high speed. Like let's say you're in the ISS right now, just in orbit around Earth, you're not really going to notice it as much. So because this was just traveling through, not yet at light speed, as you can see, I should have mentioned earlier actually, but there's no like color function in here. So this is just like we're moving stars are going past us leisurely days.
The reason the Doppler effect isn't like relevant in this model is the same reason that we don't see it like in day to day lives. Because we're moving too slow for it to like be relative, like relatively noticeable, I guess.
Exactly. Yeah. So speaking of the Doppler effect, here we are, and this is just, you know, simple proportionality. So we had R B redshift and BB blue shift. And so change in both of those is proportional to any change in the speed of light. So basically if you are traveling like let's say nowhere near the speed of light, like we were just saying, sort of meandering throughout space, going pretty slowly, it'll be less for both of you. Won't see as much redshift and blue shift. You probably won't see any. If you're traveling at about 50% the speed of light, light maybe you'll start to see some, but you know, it's not going to be as in your face as it would be if you're traveling as what I modeled here is like 99.5% the speed of light. Okay, this is here the Lorentz transformation that we had for the Doppler effect. So basically in special relativity, oh, I don't want to get too much into this, but so you have this thing called time dilation and length contraction. And for just a blanket statement, if you've ever heard of the twin paradox where one twin stays on Earth and the other goes out and like travels at light speed and then comes back and everything on Earth has changed. But because they're traveling at the speed of light and they've only been away like let's say 18 years, they've aged, you know, 18 years because they're traveling, everything else on Earth has changed. So that's basically a paradox of special relativity. So, so what we're modeling here is the same reason as to why the Doppler effect occurs this, you know, stretching and shrinking of waves. So I think length contraction would be like, the biggest thing here because we're seeing, like, the star is sort of. I'm making motions with my hands, you can't see anything, but then sort of like elongate and then shrink as they move past you at this speed. So here is the manipulate that we had for the Doppler effect. And here is our lovely color function that we've integrated now. Thermometer colors. So in this manipulate, as you moved along here for whichever direction you moved in, it would start shifting the color. So this was like very basic, just one sphere trying to sort of figure that out. And then once we did that and got that working. So there's an example of redshift. And here is the final manipulate. So obviously our functions are in here for the Doppler effect, the stars themselves, and then the scaling of the stars. The code is interesting, but I think this is a little more fun, and that's that we can finally see the redshift and blue shift in the stars. So redshift and blue shift, as you can see here. So they're blue when they are coming towards you and red when they are going away from you. So you can see that these. I can get bigger. There we go. That these stars that are coming towards us are blue shifted, and then these that are moving away from us are redshifted. And we are this wonderful little block observer. Sadly, we did not have time to, like, put the actual Millennium Falcon in there, which I think would have been very cool.
Is there any significance to, like, how bright or dark the red or blue shifts are? Like, this dot over there is, like, significantly brighter red than the dots than some other red ones.
No, no, I think that's just the position of each. You know what would be fascinating, and I can lie and say that we actually totally intended to plan this, was that each of these are different types of stars. So clearly these are. No, I'm kidding. I did not intend for that to happen. But it would be very cool if you were like, oh, that's an A type star. That's an O type star. And you could calculate, like, the brightness or something, or you had a white dwarf compared to, like, a, you know, super background. That would be great future project idea for anybody who wants to take that on you a full. Go ahead. But here, the first slider we have up here, you can change the number of stars that you're seeing. So if you want, like, I. Unfortunately, as I Said, I can't show it. But if you, like, decrease the slider, the stars would be a bit more in your face, so they'd appear larger and you could get some, like, really close up action of the actual Doppler effect. And then the bigger it got, the more vast the field was. And then this here is the speed of light on the bottom. And if you. You can slide it down so you can go like, you know, I forget what the lowest was, but, you know, 1% the speed of light or something like that. And Then here is 99.5. And that was the original goal. And if you hit the time button, we can all imagine that this is happening. It would play through and you'd travel through the starfield. And here we had, just for fun, some view directions so you could see everything from the front. That's how this is depicted from the side or from the back, which I wish I had screenshots of. But, yeah, that was my first project. It was very, very fun. I had an excellent. And with my mentor, he was a wonderful mentor. And it was a great first foray into Wolfram. I think this was a wonderful jumping off.
I think, for your first project. This is incredibly impressive. I'm excited to see how you got only bigger and better from here. It's really cool. Moving on to your second one, which you did in 2019, visualizing a binary black hole merger. This was actually what I wanted to do for my very first product in camp in 2021. And I ended up not doing it. But this was the same concept, was what I wanted to do my very first time with program. So it's exciting to see how you did it.
And you say that you're not a physics fan, Sam. I know what you are.
See, I was just really interested in stars and black hole, but I didn't like the physics part of it, which.
That'S valid. That's totally fair. They're very fast.
I think that's probably why I ended up not doing this. That.
Yes. So this was my second project. I wanted to model two fuzzballs colliding. And as funny as it sounds, fuzzballs are actually the name of a type of black hole. So when I was thinking about this with Stephen, he came up with the idea to sort of create a demonstration not of just two random black holes, but as we were sort of going back and forth, it settled on the LIGO black holes. And if you're aware of ligo, LIGO is the Laser Interferometer and Gravitational Wave Observatory, which I've said so many times that I can finally get it, like, in one go. And LIGO is an observatory that was detecting things from these two colliding black holes and currently is working on more things relating to gravitational waves. So on September 14th in 2015, LIGO detected a ping from these two black holes that I've modeled. Well, they're not like, specifically to these black holes, but this general idea. And this ping was 1.3 billion light years away from Earth, so very far away. But it proved Einstein's general theory of relativity, which was huge. So going through the project and not as much of like a history of ligo, differential equations had to be solved in order to figure out the orbits of these black holes as they collided inward to each other. So basically, binary black hole system, like any binary star system, you have two black holes orbiting each other. But obviously these bodies are so incredibly dense that as they keep orbiting around each other, they're pulling each other in and eventually they spin together and collapse. So we have two functions here. The first is the function of eccentricity for the orbit and then the average angular momentum magnitude along the Z axis and the rate of change of the semi major axis. So this is for, you know, very simply the speed of the black holes. So in the final visualization, what we wanted to do was have the, you know, black circles, unfortunately, here on my screen, sort of just spin inwards. And as they spun, we wanted to show that they are getting faster and as they come closer and closer together. So we needed this equation in order to do that. And I know I said at the beginning I loved Andy solve. And this is why. Okay, here's where it gets interesting. So this is the radius of the orbit that we planned out, and then the angular velocity around the center of inertia, which is the center that we designated that they would be orbiting into. So obviously they have a pull on each other. So we're trying to find, like, that pole sort of the center of that, and then how they would orbit around it. So this is our first very, very like, basic graph. None of the differential equations at this point were implemented. This was more just like. Let's start with the basics when it comes to the graphics side of things, and put two black dots on a screen on a circle and make them orbit each other. And so we got that here.
I was just wondering, like, like when you have two black holes or each other, do they. Are they both equidistant from each other as they, like, orbit? Because they're both like Pulling in each other and like repulsing each other or do they like kind of spin in towards each other so at one point they end up colliding?
So very interesting question actually. So anything that has an orbit, like anything orbiting around it, let's like, let's take the Earth around the sun. The Earth is very small compared to the sun, but there's still going to be a bit of a wiggle to it. So when you're detecting exoplanets, there's a few big things that you look for. One of them being any sort of shadows crossing a star. But another huge thing is if that star sort of wiggles, if there's a slight variation in its orbit like around its center, because obviously it's still spinning around an axis, right. Then you can say, okay, there's something orbiting around this star. And the larger that variation, like that little wiggle is, you can sort of determine, okay, is this another star, is this a planet? And so when we're looking at black holes, I mean here, for this project, to keep it simple, they're equidistant, right? But obviously it's not always going to be like that. They're still going to have a gravitational effect on each other. But we didn't really get into this for my project. And I think this would be like looking back on it now would have been an interesting thing, is that there are different types of black holes. There's two, there's Schwarzschild black holes and there's Kerr black holes. And Kerr black holes, spin and spatial black holes just sort of sit, right. So yeah, so when we're looking at this, like there's no variation in them. But that would be interesting to like and I think it would be like it doesn't necessarily have to be LIGO black holes, right? Like you could do a project and say these are spot showed black holes, these are curved black holes, you know, what's the difference in their orbit? I think that would be fascinating. Don't want to like go too much in that here, but I think that would be a very interesting project.
Yeah, thank you.
This is the final animation. So we went from, I know it's a pretty big jump, like we went from this to this, but not actually that complicated. What we did was plot the orbits of the black holes through the differential equations and then mapped the spheres that we have here onto those orbits. So you create this 3D plot and when it plays, which is the graphic on the top of the community post, you can see that they spin Inwards, and then they'll speed up. So they start further out, like on the rings, further out here. This almost reminds me of like a vinyl. So if you think of it like a vinyl sort of like on the outer edges, and then each one according to its own orbit. So there's the, like, yellow ochre sort of colored one and then the blue one, respectively. You'll see those spheres start, you know, here in this situation, equidistant from one another, and then they'll spin in and collide here in the center. And starfield from last time came back. And just to make a cute little graphic of it, this is the final black hole. This one does not spin, I regret to inform you. Just another still. But this is sort of viewing them like, flat on. So see, this one's, like, a little smaller than that one. So we're seeing them, like eye level rather than looking down on it from above. Because here, Obviously, it's a 3D manipulate, so you can drag it and move it around and see it from different perspectives. So that was done here. So you get a sense of, like, you know, level to this actually happening. And after this was complete, unfortunately, I don't have a community post for it. I worked with my mentor and we developed the ping that you would have heard from these colliding. I do not have the sound available at the moment, but that's not that much of a loss considering it's actually quite unpleasant to the ears, but very cool nonetheless.
Yeah, that's. That's really fascinating. I remember when I was. Well, I still am really interested in black holes, but this would have been my dream project. So it's really amazing to see how you've done this. So it's been really amazing to see all of your projects and what you've done and astrophysic stuff. So what kind of future projects have you considered? Like, I guess. Are you working on anything big right now? Are you expanding on one of the ones you've done previously? Yeah.
So currently I am doing some work for the Wolfram physics project. And this is a website that I have made for that. I am working on Stephen Wolfram's new idea of the Ruliad, which is a wonderfully complicated little thing. I say little, that's an oxymoron. We're talking about the universe here, as well as his idea on observer theory. So Stephen Wolfram's ruliad is this idea of a model of the universe, but not something like, you know, the cosmic microwave background, but more of a theoretical Thought experiment, philosophical model of the universe that grows and evolves with each new discovery. So it's basically this idea of experiences, what we know, what we can prove true. So think of something like Descartes. Cogito, right? Cogito, ergo sum. I think, therefore I am. That's something that we know. So that involves like and evolves our understanding of the universe and how we perceive it. And what we're really looking at here is what do we experience as an individual within the universe? And so that's the general idea of observer theory, right? Because we're all unique individuals. We all have our own ideas and preferences and worldviews and beliefs. And what we want to understand is how does the world, how does the universe, and how do our own individual experiences sort of shape that viewpoint that we have? So the basis of this website is not to just educate you on the Ruliad, it's more of a home base as to what this general project is. So here are some introductions. We have ideas on the current research of the Ruliad, what we want to achieve. I'm not going to read these for the sake of time and why this is important. I do want to talk a bit about this though. And it's because philosophy, philosophical thought and the sciences, I think a lot of times stem in the humanities, they're sort of this like gap between them, right? People are, you know, very humanities oriented or they're very stem oriented. And we don't really see the intersection of those two. And working on the Ruliad and the Ruliad itself is this excellent moment to say, well, we need math, we need science, you know, we need physics, we need this concrete understanding, but we also need thought experiments and we need to understand all these philosophers that have come before who have posed ideas similar to this. The most important, I think that stands out to a lot of people when we talk about the Ruliad is Leibniz and his idea of monads. But something that's very interesting about Leibniz is that he includes God in all of his discoveries. And so we have to think, those philosophers who came before these predecessors, how do their thoughts fit into the idea of the Ruliad? So we have to consider, how does God fit into the Ruliad? How does religion as a whole fit into the Ruliad? Every sect of religion. And so we get into literature and deeper aspects of the humanities and all these works of philosophers. I'm currently looking into stuff regarding Buddhism. So it's like, oh, here's this really Cool thing. Like, let's try formalizing stuff with logic. Let's try looking at this mathematically. Let's code something. But also, why don't we, you know, open the Lotus Sutra and try to understand this. So you have this huge wide variety, which is overwhelming at times, but also quite fascinating.
Yeah, I think that's a really cool concept, you know, like, you know, just kind of mixing the sciences and the humanities together, like philosophy and math. And it's definitely really unique to ever think about that because I've always done very like concrete stem, kind of like pure math. And it's interesting to think about, like how the broader world and like thought experiments and philosophy can all be brought into this. So, yeah, I think that's really cool.
Here's just more about the project, the Wolfram Physics project, and just the idea of the ruliad. Great thing about being on YouTube is you can pause and read so I don't have to do it for you. And here's publications. These are blogs by Stephen Wolfram. And once this website officially gets published itself, you can click on these and it will bring you right to Steven's blogs. How cool is that? I love hyperlinks. So basically this is just going to be a hub, a little research hub.
Ok, thank you so much, Macy, for coming on and, you know, sharing all the research you've done in astrophysics and this like, and the rulead and yeah, I've definitely learned a lot and been exposed to more physics than I thought I would ever be able to handle in one day. But yeah, thank you so much.
Likewise. Thank you for having me on the podcast.
Thanks for listening to this episode of the Wolfram Student Podcast. I hope you learned something new and took away insights from today's discussion. If you want to be featured in a future episode, fill out the form@tinyurl.com WSP S2 interest and be sure to tune back in a month's time to hear our next episode. Once again, thanks for listening to this episode of the Wolfram Student Podcast.
More from Guy

Cheryl Strauss Einhorn | The Human Edge: Smarter Decisions in the Age of AI | Talks at Google

Rachel Glennerster | Innovation and the Center for Global Development | Talks at Google

Rebecca Winthrop | Rethinking the Purpose of Education in the Age of AI | Talks at Google

Dr. Robert Wachter | A Giant Leap: How AI Is Transforming Healthcare... | Talks at Google






