Hey guys, I'm at Cheyenne Mountain State Park and in a few hours here, there's a blizzard coming in. You could probably bear that, that was probably 20 miles an hour, but it's going to get up to gusts of 80 and probably 4 to 6 inches of snow. So my slide is in, everything's inside. I've got food and water and I'm going to take you guys with me while I ride through this storm. Hey guys, it's Robin. The sun has just come up. It's about 7.30 here in Colorado Springs. Out my window it's like a freezing rain. The wind is kicking up a little bit, but I know the worst of it is starting in about 2.5 hours. They call it like a bomb apocalypse or a bombageddon. I guess there's something about the air pressure that's happening today that makes this a perfect storm for wind and snow. So of course, if you're in high winds, you want to try and get some kind of cover. That's why I'm down here in this lower spot and you want to face into the wind like I am right now. Hopefully the wind doesn't change, but on this mountain it changes all the time. But when the Ranger came by yesterday, I have a borrowed car out here that I was borrowing while I was in town. I'm using it as my tow car here. And the guy came and said for the tow car and for the RV, that when the winds come to crack the windows on both sides just a little bit even though it's a blizzard, otherwise the windows will blow out. And the boy is coming over here. He's a little freaked out right now. Come here buddy. Want to say hi to the people?  He does great. But the wind, I mean, obviously in all the shaking does freak him out. They say this is going to be the worst blizzard to hit Colorado in 20 years. I am just on the cusp of where it's going to be really bad and not so bad. So fingers crossed, I don't get hit too bad. And nobody in here that is with me has any problems like being blown over and yours truly included. So let's see what happens. You know, I would never ride out a storm like this if I didn't absolutely have to.  I mean, I could barely get here. The wind was so bad. And then once I was here, there was no leaving the storm was coming in. I'm here and I'm happy to be here. And I think it's going to be just fine. Right? So this is me and here's the blizzard warning. It's 44 right now, but it's going to start raining here in a little bit. And then the temperatures are going to plummet. Let's see what I'm looking at. Oh, snaky and Thursday it's going to be four degrees, you guys. Do you see that? Man, I'm really hoping to get out of here Monday, but I have to go over a mountain pass no matter what I do. So for right now, all I'm going to do is concentrate on writing this out because this is not going to be fun. It's about 11 o'clock here and now is when it's going to get really bad. It is definitely blowing and I am shaking and it's a blizzard. I think right now it's about 40 miles an hour of the wind, but it's going to be getting up. So fingers crossed, everything's going to be okay and everyone in here is going to be okay. Okay guys, it's getting bad in here. I've been watching the news coverage. I still have a TV, which is good. I-25 is a major highway here and it's closed from Colorado Springs where I am. All the way to Longmont and almost to the Kansas border, which is hours of the highway. There are accidents everywhere and where I am, there is thunder snow. It's not good. It looks like I'm going to hit some wind in the 90s. Holy cow, I almost couldn't shut the door to get back in here. So they're moving RVs that are facing the wrong direction because there's danger of them blowing over and the highway is closed. I can't believe I just saw another RV pulling in here. I bet they're really happy to be off the road, but you guys, I almost couldn't get the door open or shut. It is no joke out there and I'm going to crank the heat in here. Even if I have to put on shorts and a tank top because I think we might lose power. I talked to my neighbors. They had a terrible time on the highway. It is a mess out there and right now the TV stations are knocked out and there are a lot of people in town that don't have any power. I wasn't able to talk to my mom that lives in Colorado Springs on her home phone. So right now I'm heating it up in here and trying to get all my devices charged. It's going to be four degrees tomorrow and I'm a little bit worried about freezing because I think I might lose my electric power, but I do have a generator, but my tank heaters work on electric. So by the way, if you guys are ever stuck in anything like this, one thing I do want to tell you just from my insurance experience that they mentioned on the news, I think it's super important. If you are trapped in a storm like this, like an RV just sitting, make sure that your tailpipe doesn't get clogged because you can get carbon monoxide. Oh, oh, carbon monoxide poisoning. Oh my God. Oh my God.   I had a couple of clients that died that way when I was in insurance. Oh my gosh, you guys. See how it starts to turn purple? That's around 2 p.m. today. That's when the wind speeds get up over 75. So that's going to be super fun. Oh, that's not good, you guys. It's actually going to be turning pink, which means the speed is getting up over 95 here this afternoon. So keep your fingers crossed for me and everybody else that's here. Wow. Oh my God. So seriously, I can, ah, my right tires are being lifted up off the ground.   I know this isn't the worst of it. It's going to get worse for two more hours and it's not stopping until tomorrow morning. I'm going to stop for a sec, which is usually bad. You guys, I'm freaked out a little bit. I'm not going to lie to you. I would never be here in March. March is a terrible time to be in Colorado in an RV. I asked my mom why she couldn't get sick in the summer. She said sorry honey.  Poor guy.  It's all fun and games until somebody gets blown over, right? Oh my God. Oh yeah, there's definitely some thunder snow happening. There's lightning outside, like big flashes of light. So executive decision. I'm actually going to pack up a bag and jump in the car that I have out here that's borrowed and just drive a couple of blocks up to the visitor center to ride out the next three hours because there is some danger that I could flip. I am being lifted up off the ground. So I'm going to keep the heat running in here. I think the boy's going to be okay. But just, you know, better safe than sorry. So I have gotten in my little tow car here. Thanks George for letting me borrow your car. So I am headed over to the visitor center. There was one block for me and it's closed. I'm literally hiding out in the men's bathroom at Cheyenne Mountain State Park. So here's what happened. I was being lifted off the ground. So I called the ranger station and I said, hey, things are getting pretty nasty out here. Is this about the wind speed where you see RVs flip? And they said, yeah. They said, if you feel better, just come down to the visitor center and hang out. It's open till four. Well, I looked at the satellite and the wind was going to get worse until four and then it was getting better. And I thought, you know, there's a fireplace there. Just grab your stuff. I've got a car. It's right up the road. At least there was a visitor center right up the road. I opened up the door to my RV to get in the car and my RV door blew backwards and broke. And I almost couldn't get it shut. Both hands sliding backwards on the ice. I got the door shut. There was a faint click. I hope it's shut right now. I couldn't see it after that. I literally could not see the door. I couldn't see the RV. I jumped in the car and I drove up to the visitor center and it was closed. I thought somebody else came in here.  So I turned around to come back up to this bathroom and I parked and I opened up the door to the car that I borrowed and it blew off the hinges. Sorry, George. I'll fix it. Up the hill, like a hundred yards from my RV. I can't see it. I'm staying away from the windows because it's like a hurricane outside. And I wouldn't be surprised if I see more people in here in a minute because it's bad. I've got about four hours to write out inside of this bathroom before I can go back to my RV and I hope the door is shut and I hope the boy is okay. I have no idea if my RV is still standing, if my door is wide open, but I'll tell you guys, it sounds like there's a train coming. So I had to show you guys what I just saw in the toilet stall. This is a brick building, a solid brick building, but I want to show you guys what the water in the toilet looks like. And this is how much the wind is going inside of this brick building. This water inside the toilet is shaking like that just to give you guys an idea of how windy it is. Well, you guys, I'm exhausted. I made it back to my rig after hiding out in that bathroom. It finally got up to the highest winds and my rig hadn't flipped over. I could see it down the hill, but I will tell you guys that my back tires moved at least a foot. I still can't see it because of the wide out, but when I pulled into my spot, I was straight. Now the front of my rig is straight, but the wheels are turned and my back end moved at least a foot, maybe two feet on the ice, which isn't actually a surprise because when I tried to leave that bathroom shelter, I was literally pushed standing up on the ice where I was propelled forward and then I had to take shelter on the side of the building before I could make it to the car. And I'm sorry to say that the car that I borrowed, the door is dented because when I opened the door, a gust of wind hit it and the door opened so quickly that the door actually bent. And there was a broken piece inside my RV door when it caught a gust of wind and so it didn't shut all the way when I left and I had snow in here because it was open about half an inch. It's still 75 mile an hour gusts here tonight, but at this point I'm so tired. I'm like, okay, flip me. I'm exhausted, but I'm lucky I still have power here. I do have a hookup. A lot of the places up here don't have power. There are 1,100 stranded cars where I am in Colorado Springs. I saw some local news coverage. It looked like the apocalypse had hit. It was just cars everywhere. I guess people didn't see the news that this storm was coming and no drivers, so they can't plow the roads because it's full of cars and the workers can't get the power fixed because they can't climb up the poles to fix it. Yeah, I'm ready to get out of here and give back to some better weather. I would never in a million years do Colorado in March in an RV, but I guess this bomb cyclone hit eight states. In happier news, Kahlua, check. Coffee, check. And pretty soon there will be some whipped cream on this bad boy. Cold weather doesn't always suck. Oh, yeah. I survived you guys and everything is good. I did have some damage.  And a couple of my outdoor bins, because of the wind, the hinges had a problem. I fixed them. Part of my door broke a little bit. No big deal. I was able to fix that as well. And to answer some questions, I know I'm going to get. No, I couldn't stay at my mom's. Her neighborhood does not allow it. I needed a hookup so that I could use the tank heaters because it was getting down so low in temperature. No, Doug was not with me. He couldn't get up because the highway was closed and it was actually closed for two days. I am glad that I bailed and went and spent some time in the bathroom because there was a semi right down the hill that blew over. And I definitely moved about three feet. My front tires were in the same spot but turned and the back of my rig had moved about three feet. The car that I borrowed, the door blew backwards and the actual metal hinges were half-pride off the frame of the car. So I have to get that fixed. All in all, it's okay. Everybody here was okay and I'm okay. I have no idea where I'm going because the weather, as you can see, changes here like every 20 minutes and I have to find a window to get over a mountain pass. But wherever I go, I'll take you guys with me. Thank you as always for watching the videos. Subscribe if you haven't already. Give me a thumbs up. Share it with your friends. Everybody have happy travels out there and be free.


So my name is Nick Cowan. I'm the CEO of the Gibraltar Stock Exchange and we got involved in the crypto space about a couple of years ago We were asked to help a company structure and launch the world's first as a back security match the performance of the Bitcoin So we had to sit down with our regulator We had to go on a bit of a journey took us some time, but we got the product away We launched it and that really took us into the space then in 17 We saw the explosion of the the ICO market the government's bringing in regulations from January to regulate distributed ledger technology operators So we thought as the stock exchange of Gibraltar We should try and bring some leadership and governance to this whole ICO space So we've opened the Gibraltar blockchain exchange which kicks off in January in terms of being open for business and GBX is simply this we're bringing governance and best practices to the ICO space using a rule space system So we are we are now fully engaged in the crypto space When the government announced in May 17 a framework for regulations there were nine principles I don't think anybody in Gibraltar quite realized how much interest Demand from companies looking at Gibraltar that they would be and we've just been you know overwhelmed by the interest in us So with our wrecks coming into place in January We've already seen a number of applicants looking to get licensed from January ranging from Exchanges fellow exchanges cryptocurrency exchanges banks asset managers players in the space custodians So we see I think Gibraltar having an incredibly exciting few years ahead of it being one of the first movers So for us is the exchange well, we've got two things GBX will be the utility token exchange which we're launching in January and then during 18 We're gonna be looking to put Gibraltar stock exchange the main exchange Completely on the blockchain using distributed ledger technology.  You can trade securities on a digital exchange Your utility token you can come to GBX. So we believe we have extremely exciting and attractive opportunity but also offering to help stakeholders, issuers, investors meet in a digital marketplace 50 years ago my granddad used to get paid in cash on a Friday and then they started to say You know what? We're gonna actually give you a check and there was just what are you talking about? This is paper and then 10 years later. We're not gonna give you a check We're actually gonna put the money directly into your bank account You can imagine that sort of transformation. I think wherever whatever happens in the future There's a transformation probably over the next five to ten years because cryptocurrencies at the moment They are not mainstream. They're not available. My mom doesn't know how to open a wallet I'm only just learned how to open a wallet It's gonna take I think another 10, 10, 20 years But you know what? I do believe there will always be fiat because until I think the technology supports The cryptocurrency space and the volatility starts to slow down Then I think there will always be an area of suspicion particularly from you know The older generation about what is this new digital currency that basically comes with a code So I think I don't think you'll have one of the other But I do believe they'll blend over time and it'll become a lot more acceptable and mainstream For a method of payment. I think that there has to just be more acceptance of it You know, I think what you're seeing now is you know, my background is trading So I've lived through a bubble an 89 in Japan I lived through a bubble in the dot-com boom in the States and for something when I said earlier that the Bitcoin asset back security When we launched that asset back security, that was August 16. It was $400 now as a $10,000. I think it touched 10,000 yesterday. Correct me if I'm wrong That is not sustainable. You can't have something go up 25 times in a year. So what you're seeing now I think is in terms of the demand for Bitcoin You're seeing a fear of missing out and people are saying, you know what?  I now have to pile in I think in terms of the protocol It's an I'm not a tech guy, but I think because of the in some ways there are limitations of the protocol I think what you'll see is fellow Ethereum based blockchains where you've got the ability to smart contract I think that they will continue to emerge over the next 10 years But I think it sounds a Bitcoin, you know, I keep saying I've missed it It's probably gonna be $100,000 in a year's time and I'll just be kicking myself and saying I'm an idiot But 25 times sustainability per annum. I can't see that carrying on We sold 25% of our business this year to a Asian fintech company and they're Singaporean, they're Hong Kong and They're younger, fitter, better-looking and wealthier than I am. They keep saying you're so old What do you know about blockchain? Why are you in this space? You're just an old trader What are you doing? And that's been I think the the most interesting thing that actually I used to say listen I always try to learn from people older than me I'm now that old person and in fact it's turned around because actually now I'm having to learn from people younger than me So I kind of missed out on both counts. I clearly haven't taught anybody anything but it's a what what I think is amazing over the last few years is The transformation from fintechs being young to actually as you're seeing a Development going more mainstream. I was in a country in Asia last week I spoke to 500 people and the average age was 60 and they were all cryptocurrency traders So I was the youngest in the room. So that's a that obviously something's changing


We're 15 years into America's longest period of conflict, and soldiers are still deploying to Afghanistan and Iraq. It's easy to forget that the front line extends from the mountains of Afghanistan to the skyscrapers of New York City. For many Americans, the Big Apple is a place to visit, but for some, it's home. There's smoke billowing out of the World Trade Center. Sean, what happened next? You know, you've never seen anything like that in the world before. It's like the east side, and it blows into the building with the flames. One day, everything that was New York changed. Good evening, I'm John. And the threat continues to be a reality. And confusion right now in Manhattan after an explosion in Chelsea. That guys only have to be right once. We can be right 999 times, but that one time we're wrong, you know, a lot of people can die. I left for Port Meade, Maryland, and began our drive to New York City. I haven't been back to the city since 2014, when I was stationed at Port Hamilton. I was on a special duty assignment, still on active duty. I didn't wear the uniform day-to-day, and my main transportation was the subway. And every once in a while, I would see a soldier, and I would have to go up to them and just kind of shake their hand and kind of talk about the Army a little bit. But the one thing that I've always wondered, what are they doing here? These soldiers are with the New York National Guard and join Task Force Empire Shield. For the next few days, I'm going to get a chance to embed with these guys and find out what it takes to protect America's biggest city. If someone didn't know, why is there a soldier in the middle of the train station? We get that question many times, as we all know, New York City is the number one terrorist target in the world. It's the financial capital of the world, it is the cultural capital of the world. But we're there to deter and detect terrorism, and we're there as the call of the governor. And this Task Force works together with other agencies to accomplish its mission. Everybody from Department of Homeland Security, NYPD counterterrorism, Port Authority police, Samtrak police. But we're always in the loop on what's going on in the planning stages and of course in the execution stages with our partner agencies here in the city. Which is something you would never have prior to September 11, 2001. So I mean, the advantage is that these soldiers most of them live in New York City? That's correct. The vast majority of Empire Shield soldiers either grew up in the city or right outside the city. So they have a vested interest.  Sergeant Vega, a native New Yorker and former New York City police officer, has been on the Task Force for three years. So again, this is our Penn Station. This is one of the main hubs that we patrol here for the Joint Task Force Empire Shield. Yeah, I heard it's one of the busiest places in New York City. One of the busier places in New York City and the reason for that is from one side of Penn Station, you have the Long Island Railroad. All the folks coming from Long Island into the city to come to work as you can see. And from the other side of the station, you have what's called the Patrick. Those come from Jersey. How many people, how many soldiers do we have on the ground here? Roughly. Every day you have an average between 15 to 20 soldiers spread out through the station. And of course, we're trained to look for certain things. Here, if you work here long enough, you know what we call work noise. You're used to a certain type of noise every morning. Like a baseline? A baseline of people coming in. So, you know, we listen for things, we look for things. You automatically hear it, you feel it, and somebody will come and tell you, hey, there's something going on over there, something going on over there. After work, Sergeant Vega invited us to his home in Chelsea where he lives with his wife and two kids. We sat down with his wife, Theta, to find out what it takes to be an Army spouse. When you met him and he told you, I'm in the Army, what did you think? He wasn't only in the Army, he was also in YPD. So you get both worlds, and it's like, okay, so as in YPD, he's in the streets, anything can happen to him any day. And then in the Army, the fact that he can get called to go away any day or any time. So, it's kind of nerve-wracking. What worries you? Well, one of the concerns I have is, like, he's always gone one year for a home month. Out of the year, he's gone a home month, which is actually happens to fall on our daughter's birthday. So he misses her birthday every year. Every year? Every year. And now that she's older, she actually questions him and says, why can't you at least not go one time to spend his birthday with us? So... How old is she? She's 11. What do you guys tell her? She understands that he's in the military and that he needs to go for training in the event so that he's prepared for any tragedies that may happen. But as a child, you really don't always understand. You have to support them and what they want to do. And I support him 100%. It's just heart of the family. Sergeant Bagan and his family are one of many who defend New York, and their backgrounds are as diverse as the city itself.  Until they kick me out. My mom brought us to this country when I was a teenager. And we struggle a lot. And I thank God the opportunities that this country has offered me and my brothers are endless. And that would have never happened in my country. So I'm thankful and grateful for that.  The first time I saw this guy, he had an old rag in his hand, and he was cleaning the memorial dedicated to the firefighter who lost their lives. Have you done rolling? You call me a broad chaser and a man. And I thought he was talking to himself, but the closer I got, I realized that this guy had a message. Seven days in a week, seven letters in New York, seven points in Miami's crown, seven continents can be found, seven red stripes in the American flag, seven buildings the World Trade Center had, not just two towers. Everybody's got a story to tell. The 9-11 affected all of us in different ways. America's a melting pot, a gumbo soup. You don't see it? Please let me help you. The whole world saw those pictures, but in reality, those pictures did no justice as to what this place looked like. September 11, 2001, Tuesday. First week of school, New York from Jersey, Connecticut. Primary Tuesday. I was actually, I worked at the New York Pioneer. All the smoke was coming up to 14th Street. You could smell it. And from that moment on, I just picked up and I left. I was like, I need to go pick up my son from school. It beats like this. Dedicated to those who fell, that's the past. And to those who carry on, they're the future. May we never forget all day some and some gave all. It really changed many of us. History, don't live in mystery. Some will listen, some must learn. Is there a silver lining to this whole thing? Yes. We're bigger, we're better, we're stronger, we're more modern, we're more educated, we're more savvy when it comes to how to deal with terrorism. And overall, we've just become a better city because of it. It's been 15 years since 9-11. It's changed everything. But with the strength of these soldiers and the resiliency of the people of New York City, I can't wait to see what comes next.


In this lecture we're going to get to something very important and actually quite a bit of fun, curvature. I'm going to import everything that I need, first of all for curvature.   Let's look at curvature. Curvature tells us how much the direction of the velocity vector changes per arc length of a motion path. Now think about this a little bit. Actually I think when I show you this little picture it'll make more sense.  Now imagine it travels at the exact same speed. If it looks on this pedometer it stays. Yeah at the bottom here it's a very gentle curve and we see at each point these little orange points we see the velocity vectors, instantaneous rate of change there at a constant speed though. Those two will be the same magnitude, they're just different directions. And the car won't slip from the road I suppose there but if we get to the top here there's quite a sharp bend. Quite a sharp bend. If the car doesn't slow down it might even go off the path. It might even leave the road. And if you look at these two orange dots at the bottom and these two at the top, the arc length between these two now this is just a hand drawing. This is not 100% discovered. Imagine the arc length, the distance. If I just travel along the blue line from that one to that one and from this one to this one is exactly the same. If I look at these two green velocity vectors and I look at these two red velocity vectors there's quite a bit more change in the velocity vectors these two red ones as opposed to these two down here. So for the same arc length, for the same length of this blue bit that length equaling this length up here there's a lot more change in this velocity vector from that little bit of arc than from this little bit of arc. Curvature tells us this rate of change of a velocity vector let's make it a unit velocity vector. So I take that vector and divide it by its magnitude so just imagine these are just unit vectors. So it's a rate of change in those unit vectors per arc length.  So it's got nothing to do with the pace at which I'm travelling there. This is a rate of change of those tangent velocity vectors make them unit vectors per arc length not per speed or per velocity or anything like that. That gives us curvature. You can just intuitively see that this curvature there's more curvature here than there is down here but we need a mathematical way to say how much curvature there is. First of all before we get there we need to define this tangent normal vector. What does that mean? It means the velocity vector at that point divided by its norm. So that becomes a unit vector in the direction of that instantaneous velocity vector and I'm going to call that we're going to call this T. We call it the unit tangent vector. I should say I hope I didn't call it something else before. The unit tangent vector. So it's a tangent to the path there and it's a unit vector. Now pay particular attention later on we're going to learn what the tangent normal coordinate system is. We know what the Cartesian coordinate system is but one of the body coordinate systems is the tangent normal coordinate system that you're going to learn a lot about and for that you need this. You need this unit tangent vector. It is nothing special. It is the unit vector in the direction of the velocity vector at any point and there it is. Really nothing difficult. Let's do an example. I've got four times the cosine of T in the x direction of my C coordinate system and four times the sine of T in the y direction and if I just print that to the screen I shouldn't do that. Otherwise Python is not going to execute any of my code. There we go. Four times the cosine of T and four times the sine of T in the x and y directions. I remember my old friend this arc length equation. It is the definite integral in going from some initial to some final time of the square root of the first derivative square of the other component with respect to u. That's usually how we write it. Let's do that. Imagine we have this position vector in time. This is going to trace out a little arc for us. We can see it's going to be a circle but anyway it's going to trace out an arc this position vector as time goes on and between two bits of time I want to know what the arc length is. What the arc length is. That means I'm going to do integration here so I better break up this one into two separate computer variables. I've called it r underscore x and r underscore y. That's just the four cosine T there. Four times cosine T there, four times sine. So I've just broken it up. I'm going to get the first derivative because I need the first derivative squared. So I'm getting the first derivative of each of them. My integrand is now the square root of this one squared times the other one squared. This is a long way and now I just want to integrate my integrand with respect to T going from zero to T and that will give me the s of T. If I were to run that I get this I know from my trigger identity this is going to be one so I can say simplify s of T just using normal python and that leaves me with four of T. So my arc length going from zero to T is just going to be so that's very simple to do. I know I can this is a quick reminder actually how to do arc length. Very easy to do from this equation here. Now let's define curvature. It's given this Greek letter kappa and it is the norm so it is a scalar of the rate of change of the unit vector with respect to arc length dT dS Look again. How much this unit vector changes which we've just introduced here the unit tangent vector. How much it changes per arc length. For that bit of arc length there's not much change or at least not as much as look at these two red ones. I mean there's a huge difference if they both normal vectors I mean there obviously the magnitude is the same but there's a huge change in direction. There's more curvature there than there is there. So that's how we define this. There's a rate of change of this unit tangent vector per arc length. Can we get a better equation for this because that's not the kind of derivative that you'll just be able to do. It's very easy look at this. There's my definition kappa equals this norm of dT dS. If I were to take the first derivative with respect to T of the T of T this unit tangent vector and I just do it like this is dT dS times dS dT. Now I've got to be a bit careful there. This really only works in two dimensions but later we extrapolate it to three then don't be too concerned about it. Just think I'm doing implicit differentiation here. So it's dT dS times dS dT and in two dimensions it's really like you can cross out these two dS's and you're still left with dT dT dT dT dT dT capital T dT. Don't worry about that. In other words if I get dT dS on its own I take this dS dT and I bring it to the denominator on this side so that would hold simple algebra for all this upside down A for all dS dT not equal to zero I can't divide by zero so dS dT is arc length divided by time that's the speed so it can't be zero speed that's what I'm saying just being mathematically rigorous there. So kappa now remember dT dS is kappa so kappa is this but I know that dS dT is the norm of the r prime of T. Speed is just the norm of the velocity vector in other words kappa is the norm of T prime of T divided by the r prime of T so we've just seen how to do T remember T is just the unit velocity vector so it's the rate of change of the velocity vector by the norm of the velocity and that gives us kappa so it's a very simple setup there go through it again really there's nothing to it there's another equation for kappa which is sometimes a lot more useful I'm going to show you what it looks like but it's going to be a couple of lectures before I show you the derivation of the other form for now this is the one we want now let's look at an example so I'm just going to introduce these mathematical symbols AC and E to just represent some constants I have this position vector AT in X direction CT in the Y direction, ET in the Z direction that's linear and T linear and T linear and T so this is a straight line just think about it would a straight line have a curvature I bet you it doesn't I mean it's a straight line but let's see let's just make sure so V of T is going to be the first derivative of that which is simply AC and E what do I need well I need that's magnitude of velocity in my denominator I need the velocity which if I get I call speed it's just the magnitude of the velocity vector which is now just A squared plus E squared E squared remember what T was my unit tangent vector that was the velocity vector divided by its norm there we go that's my T of T T prime of T I just take the first derivative of that and that becomes my numerator which I'm going to call kappa numerator it's magnitude there simple enough to do so T prime of T is the first derivative of T of T and in the numerator I'm going to take its magnitude the denominator takes speed so kappa is just going to be kappa num divided by speed and if I were to run that lo and behold I get zero which is to be expected because the initial parametrized position vector was a straight line no problems there you can do this in a variety of ways you can give it different values you can do it all in one but if you go through it slowly you'll see this makes sense and this is one way to do it let's do another one for fun quickly so I have a much more complex path there some form of a spiral I need the velocity first of all of that velocity I make the unit tangent vector by dividing the velocity vector by its magnitude T prime would just be the first derivative of T kappa is just going to be TT prime's magnitude divided by VT's magnitude which was the speed and if I look at that the answer is going to be 1 over 10 now let me quickly so that gives us curvature let me quickly just show you there's a whole other way of doing it I don't know if I should really introduce this example because I'm not going to show you this equation and I'll show you right at the bottom what it looks like but we're going to derive it in a later video and sometimes when you're given something like the you're given different values in your problem to solve sometimes this alternate form more difficult form of the might be easier to use so for that I need not only velocity and position but I need acceleration also so I'll just get the acceleration vector same position vector as we had before I'm going to now take the cross product of the velocity and the acceleration vector and that's going to be the numerator or the numerator at least is going to be the magnitude of that I should say the denominator is going to be the magnitude of the velocity vector cubed to the power 3 and now if I get kappa I get this massive solution here and if I just simplify that again I'm going to end up with 1 over 10 so I do 1 over 10 with a simple equation there 1 over 10 with a difficult one there very difficult to run through here so you're not going to understand this until I show you the equation but just to show you there are two ways to get to 1 over 10 fun thing what is the radius of curvature let me just go back up radius of curvature is if I have the curvature here I imagine I can put a circle there this circle will have a much bigger radius there then this tiny little circle that will fit in but every point will have its own curvature its own radius of curvature radius of curvature is just the reciprocal of the curvature over kappa so for our previous example it was going to be no matter which way I do this was going to be 10 so radius of curvature at any point there remember now its going to be the same because this was a spiral initially so its going to have the same there's not going to be t the variable t is not going to appear in every spot its going to have the same radius of curvature radius of curvature is just 1 over the curvature let me get closer to this second example I'm going to show you the equation for it now but not how to derive it but let's imagine that we have a position vector and its parameterized by letting x equal to t that makes y equals the f of t I should say for this curve y for f of x if we then parameterize it to x equal t we're going to have this the r of t equals t and the f of t and let's make it in two dimension its in a plane so nothing is going to happen if I take the first derivative of that to get velocity the first derivative of t is 1 the first derivative of f of t with respect to t is f prime of t first derivative of 0 is 0 and there's the second derivative and lo and behold here we get to this other form of kappa it's the norm of the velocity cross acceleration I did it up there divided by velocity cubed so if I were to get this cross product of this and this divided by this I'm not doing the derivation but this is what it ends up with it is the norm of the second derivative of the f of t over 1 plus the square of f prime of t all to the power 3 over t so this is the other way you're going to do this parabola I'm just going to show you something quickly let's look at a parabola don't worry about that of course you'll have to memorize this if you don't learn how to derive it I'll show you the derivation in another video then you've got a lot of ways to calculate curvature so let me just introduce these symbols a b c and x and I have a function I'm going to call f the mathematical variable f is now function and the function is going to be a t squared plus b t plus c what is that? it's a parabola nothing other than a parabola now using this other format of getting the curvature let's just get f prime and f double prime in other words first and the second derivative of that parabola my numerator is f prime prime it's up there divided by 1 plus f prime squared times to the power 3 over 2 so that would be I hope I've run all of these have I? kappa is now this that is my curvature now think about it if you have a parabola what happens as x or t it's t versus y what happens if t goes to infinity well on the y axis that thing is going to climb almost straight up it's going to turn into almost a straight line and what is the curvature of a straight line this is kappa my curvature I'm just calling the curvature when t approaches infinity kappa dot limit that means I take the limit as t approaches infinity and lo and behold that curvature is going to be 0 that curvature is going to be 0 just think of a parabola as t approaches infinity it's going to go straight up in the air almost the curvature is going to be 0 so that's a lot of fun with curvature your introduction to curvature is really not that difficult you've got two equations three almost I should say although these other two are basically the same thing there if you take the cross product this is what you can end up with so you've got these two this one and the top one two equations now for curvature and you better still you understand what curvature is all about and simply the radius of curvature is just 1 over the curvature very simple


What's everybody Jason here for jazzy's case breaks calm we just sold out jazzy's 16 box baseball mixer This is pick a team number six and again features six boxes of tier one ten boxes of clearly authentic And we're gonna give away five hundred dollars in break credit if you buy two huh two or more teams So if you buy two teams you get entered into the giveaway you buy four teams You get two entries six teams three entries and we're of course the only buy one team you not be entered Talk to your names each win two fifty back And we'll do that randomizer at the end Here at the bottom I don't see who has what right there So here we go Here's everybody that bought in just a two-team R&B was which was Atlanta and Tampa Bay were not sold So these customers have a piece of those teams there right here Now we're Joe wrote down six on all them So these let you know they're from the same case and we'll start off with it clearly We'll end it with the tier one All right first one Got George Springer 11 of 25 tops tech autograph That is for the blue J's when a Patrick Cox One of five Austin Meadows for the raise How about that I imagine I was wander right there Well raise is part of the random number block spot one Greg. There you go. Very nice Alex Kierloff. That's to 99 for the Minnesota Twins Minnesota David Wong. All right next one We have a rookie there set the beer For the Arizona Diamondbacks Adam Kuperman with that one. All right after this box halfway through the first First product, which is clearly authentic a one of one Kyle Tucker How about them Astros moving on six straight years in the ALCS and that is going to Patrick with the Astros One of one Tori Hunter for the Twins Another one there for David Wong Dwight Gooden for the Mets another one there for Patrick Tristan McKenzie to 99 for the Cleveland Guardians. How about that comeback over the Yankees to one now Guardians chance to win it tomorrow and That is Cleveland David Wong and Milwaukee. That is Aaron Ashby rookie autograph Milwaukee That's going to David Wong Last box here to 99 Cedric Mullins That is for the Baltimore Orioles Travis found All right, well so far one hit for the race and R&B the rest were going out to straight-up customers now We're gonna go with tier one. I've got Logan Webb to 399 Stephen Strasburg to 149 for Washington You got Patrick Wisdom Otto to 299 and Johnny Hernandez to 299 Man, well first of all Rex. Let's take it one game at a time I got to win this game and then we'll see if they win the series, but there were to be that hypothetically Man a lot of bad blood's gonna happen there, dude. I see fights on fights on fights happening, dude It's not gonna be good. Honestly There is a lot of bad blood our next one You got Kettle Marta for Arizona Gavin Lux for the Dodgers to 299 and a Yon Moncada to 99 Chicago White Sox, that's Travis Dodgers that's Ryan, of course zone as Adam Cuperman Yeah, it would be definitely fun to watch though. All right next one We got Wilson Contreras Trey Ambergy for the Yankees and a Tom Glavin for the Atlanta Braves and That's R&B Atlanta Braves 192 So spot two is Nicholas Freddy Freeman off to a good start in this game. Yeah, maybe a Francisco Lindor Justin Verlander for Houston Mason Thompson at 299 and Keith Hernandez for the Mets Obi-Wan with the Nationals Mets Patrick. They had to have played each other. I just don't know if it's been a world series But yeah, they've had to have played each other And I think they rotate like every few years, right? I'm pretty sure they played each other The Yankees are coming to LA next year, so I know it's a big game a lot of people want to go to All right, Dustin Pedroia You got another Keith Hernandez at 299 And a Jake Berger to 299, but no, I'm pretty sure Rex. They have They rotate every few years. So I'm pretty sure that They don't play each other much. Well, it's it would be like interleague.  No, just two relics here All right, Chris Bryant Gary Sanchez for the Yankees. We got Alfonso Rivas and For the twins Tori Hunter Alrighty folks. Well, nothing super crazy out of tier one We did get a one-to-one out of clearly and out of five in clearly So definitely much better boxes there, but still always solid hits though regardless So let's give away some money then guys. Let's switch scenes and again guys To buy two or more teams you have a chance So only customers are bought in straight-up teams So covering with four. So that's two entries there Chad with three so that's unfortunately one entry chat, but good luck David with six so that's three entries And then Jay with two so that's one entry Open one one Nicholas just one Patrick with six that's three entries and then R&B's don't count Ryan with two Travis with three So Ryan with just one and Travis with just one And that should be it folks. So just a one and 12 shot or two and 12 shot. Let's get a roller Let's get a list roll One or two three times. Good luck one two three Boom three times three Patrick and David Wong congratulations 250 dollars back to you guys So I'll send that out to you guys right now appreciate it jazby's case breaks calm


Hello there, I'm Sandy Olnock and welcome to part two in my series on warm and cool greens. I'm going to do watercolor landscape today. In my previous video, I did what I think was probably one of my best explanations of cool versus warm when I talked about greens. However, for people like me, I am not a person who learns that way all that much. I've learned to teach that way because I've learned what people don't get when I explain my version of warm versus cool. So this video is going to be more of my gut explanation of warm versus cool. It's the way I think of it when I'm painting, because for me, painting on a swatch on a piece of paper and testing out colors and stuff, that's all well and good. And you definitely need to do that so you can learn your colors. But for me, the way I learned the best, meaning the way I figure out what actually happens in real life when I'm painting is by real life painting as opposed to blobs on a piece of paper. So I'm going to do this speed painting for you with worms and cools.  My warm green is going to be green gold. My cool green is cascade because the two of those play nice together. It can break out into some fun blues and do crazy things randomly. And green gold loves to just throw color wherever it feels like. It likes to just travel within other colors. And the two of them together make a really interesting tree line so that you get a lot of variety of colors because not only when you put the color down, like I'm just kind of blobbing it down, I'm getting weird kind of groupings of trees. But the colors also like to do that themselves. So the foreground, well, I guess the foreground and the midground are all going to be grass. So this whole field is full of sunshine. The sun is shining on all of it. So I want to have my nice warm color out in the field. I'm going to put some of the cooler color in the foreground because I want to add some grasses there. And I didn't want to have only that light color to mix against because I'm going to be going back in painting over that. And for my house, I wanted it to blend within the tree line too. I didn't want it to look like a sticker that was glued onto my painting. And the way that I keep from doing that is to paint while the sides of it are still wet. So I'm letting the brown mix into the trees because I can always go back in and add some darks to define that again. But it's going to help to pull some green into the house and pull some of the house into the green. Add a little bit of color onto the road here. Just a bit of yellow ochre and a little bit yellow ochre on the roof. Now remember, I've only dried this once so far. So I still have very wet pigment on the paper and I'm using thicker paint so that it won't run as much. And I wanted to add some taller trees into this. So I'm going to use the warmer color first because I want the sunshine to hit that tree and then I'm going to drop cooler color into it. So if what you remember is that warmer color is what you need where the sun is going to hit, then that might help to understand a little more about using warmer and cooler colors. Now it doesn't mean that all trees are going to have a warm flavor to them. There are going to be trees that will be bluish. That's just the color of the tree. So you don't want to use a warm color when it's a bluish tree. And vice versa, if you've got really dark shadows, you can use, believe it or not, you don't have to use a bluish shadow color, a cool one. You can use a warm one. It's OK. Whatever works for your painting is what you should be using. I just know there's so many people who panic about using the right, quote unquote, right colors. And honestly, there's no right and there's no wrong. It's art and it's all about what's going to work for your painting. So I'm adding a foreground to this. I wanted something to invite the viewer into the painting itself so that they don't feel like they're down at the end of the road and not welcome to walk down it and adding some detail in the front helps to give it that context for them. So the house doesn't feel so far away and then using some dark color around the sides of the house helps to define the edges of the buildings. And that sort of thing. So once it gets dry enough, then you can go in and add some of those details. I'm even going to paint over that brown with the greens because the brown still kind of sticks out a little bit. So doing a light wash of the green over top of the brown leaves it feeling brown because the water color is just going over top of water color. But it starts to pull it into the flavor of the rest of the painting. So adding a fence, of course, because what Homestead does not have a fence going up the drive, of course. And I made my my far right post a little bit too close, so I decided it was going to be a gate. So there you go, making decisions on the fly here is how we're rolling with this and increasing the shadow along that side of the fence. And next up is going to be to add a few details into the grasses in the front with some even darker color because as this dries more, I can add in more fine details. So few little indications of flowers or weeds or something. Just little details on that is going to help to, again, invite the viewer into the painting itself. And of course, there has to be down this. There has to be some grasses down the middle of the road. Isn't that on every single country road that there is? So next up, I have a few areas around the house that I wanted to sparkle up. I wanted to add a few areas of really strong contrast because in a painting or any artwork, the place where you have the brightest, whitest colors next to the darkest shadows that the two areas touching tend to be the things that draw the viewer's eye. And I wanted to draw the eye to the house. So I'm adding some details around it without making a line around the house.  I just wanted it to feel very natural. Going to put some trees in front of that other far away building. I don't know if it's a shed back there or something that I included and painted some tree trunks right in front of that. And then I'll put some details into the house. Just a few lines to indicate, you know, the structure itself and shadows underneath of the eaves of the house, et cetera. What I would like you to not take away from watching this video is that you need to go out and buy this warm green and this cool green. It is one thing if that is the color you want, if you happen to like this combination, please feel free. Links are in the doobly-doo as always. But there are so many warm greens and so many cool greens. And these are just the two that I happen to use today. If anybody ever tells you, you must get these colors, please take that with a grain of salt. You don't need to have all those colors. Look at what somebody's using. Are they using a warm or a cool? Is there something in your palette that you already have that's close? Can you push that color by adding a little more blue to it and make it more blue like theirs or put a little more yellow in it to warm it up? There's all kinds of adjustments you can make with watercolor very easily. If you enjoy color theory, please do go watch Monday's video about warm and cool greens part one. And I also want to give you a heads up to mark some dates on your calendar that are upcoming.  But with Etcher, they're going to join me here and we're going to talk about color and mixing. And I'm going to show you how to make these swatches and why I'm making them because I started doing something a little different so I could learn more about my colors. This live stream is the homework to get yourself ready for the class that's going to be on their website. So once you have your swatches done, I can shout out what kind of color you should get and you'll know exactly what to mix because you will have already done your swatching for that.  Bring your brushes, bring your paints and paint along with me. All right, I will talk to you guys later. I'll be back next week with a fresh video on a new subject. I wonder what it will be. I'll see you then.


Two people have been killed in a Russian attack on the city of Dnipro on April 19th. Six more have been killed in the city of Snellnikov, including two children, and 29 other residents of the Oblast have been injured. The five-story building in Dnipro was partially destroyed and on fire, potentially trapping people under the rubble. Two infrastructure facilities were damaged too. In Snellnikov, where private houses were partially destroyed and eight more were damaged. The region had survived another massive attack, with Ukrainian air defense forces shooting down some of the enemy targets, including nine missiles in the morning and two more overnight. However, some missiles still managed to hit their targets.In Pavlorad, an enterprise was damaged, while the cities of Nikopol and Marinets were shelled with artillery in the evening, resulting in damage to two private houses. The number of casualties continues to rise as the rescue operation is ongoing. The Russians also attacked the Nikopol district. In the evening, they shelled the town of Nikopol with artillery and Marinets-Romata overnight, damaging two private houses. Unfortunately, the number of the dead and injured will grow. We are continuing to clear the rubble of the damaged houses. Aid stations have been set up on the ground. Psychologists are at work. The police are accepting statements from those affected, Interior Minister Ior Klamenko said.


I'm Micah Wood. I'm known as WP Scholar on Twitter and my website, et cetera, et cetera. So what I do is I work on enterprise WordPress projects. And I do a lot of teaching and mentoring within WordPress and JavaScript. And so I live just east of Atlanta, and one of the things I've just started doing recently is actually posting WordPress development tips on my website. So if you're interested in daily or weekday development tips, be sure to check that out. So but today, I'm going to be talking about debugging in PHP. So the point of today's talk is to encourage you, if you do not do debugging in PHP, at least interactive debugging, to encourage you to do so. And to show you how you can get that set up quickly and hopefully as easily as possible. So how many people in here actually do interactive debugging in PHP? A few. OK. So for those of you that already do this, you may learn something, you may not. So first thing we're going to go through is just kind of the basic mental process, obviously, of taking a look at a bug, what kinds of things are involved. And obviously, the first step is to figure out what you're dealing with. You've got to identify the issue and understand what is going on. So obviously, to understand the issue, you'll have to know what steps you have to, what the steps are to reproduce the issue. So obviously, if this is a web issue, you're going to want to have a URL. And typically, you click here, click there, do this, do that. And then what were your expected results? So you go through these steps. What is it that you were expecting to happen as opposed to your actual results? So the interesting thing about expected results is I have a plugin in the WordPress.org repository. And it is designed for a specific purpose. And I've had people come to me and say, well, your plugin doesn't do this. It's not working. It's broken. But the reality of it is that their expectation of what the plugin did did not match what the plugin was intended to do. So expressing what you're expecting to happen is very insightful, because sometimes it's just a matter of, oh, it doesn't do that. So make sure that you get that information as well as what actually is going on. Kind of a quick and easy way of remembering the information that you need for a bug is, I did, I saw, I expected. So if you can remember that little phrase, I did, I saw, I expected. I did, ABC, I saw, DEF, I expected XYZ. Then you can easily report a bug and remember what all goes along with it. So another thing that's important to know is what workarounds there are. Sometimes knowing what the workarounds are will actually give you a lot of insight into what the issue is. So that's important. Obviously, any error messages that you run into, it's important to capture those. And of course, any environmental information. So browser, device, all of those different kinds of things, operating system, WordPress versions, plugin versions, et cetera, et cetera. So once you've identified the issue, the next step is to obviously be able to duplicate it. It's kind of hard to fix things that you can't replicate. So sometimes in the attempt to duplicate an issue, you realize that you don't have all the information. And you have to go back and really evaluate what's going on. So for example, I've had some issues lately where something's not working. Okay, well, it's related to caching. And well, we have caching on the production server and the staging server, but not on our local development environment. So duplicating this issue locally is going to require setting up caching, so on. So the next step is to isolate the issue. And this is where the true skill lies, right? So you want to be able to first of all have the domain knowledge and understanding of how WordPress works, how the plugins or themes that you're trying to work with operate, whatever it is that those things are trying to accomplish. So one of the things I've learned about debugging is you have to think like a kid. So when you come across an issue, you look at it and you say, why? And then you figure out, it's because of this. Why? You just keep asking why and why and why and why until you get no more answers. And then chances are you'll get to the true cause of the problem much faster. So be a kid, ask why a lot. So one of the things I do to try to isolate the issue and really get down to the bottom of it is determine what type of issue you're dealing with, right? So there's a bunch of different classifications that an issue could fall under. So there's the visual aspects where you've got HTML or CSS problems. You've got interactive, usually a JavaScript problem. You've got functionality issues where something's probably gone wrong with PHP. You've got data issues. A lot of times these are user issues, but sometimes they're related to MySQL. Environmental issues with the server, performance issues, security issues, caching issues. So if you can kind of classify where your issue falls, chances are you'll be able to understand much quicker where you need to go look. One of the other things you wanna do is try to determine the source of the issue, so in determining the source of the issue, I don't mean necessarily finding the exact line of code. But in kind of a first step of determining the source, you wanna figure out, well, is this actually in the theme I'm using? Is it in the plug-in? Is this a data issue? Is this something with the web host? Is it a third party API? Is this something that is actually a problem with WordPress core? So you wanna identify in a general sense where that issue's coming from. And obviously there are some debugging steps and things that you can do. Or I shouldn't say debugging, I should say troubleshooting steps, right? That you can do to kind of figure out where you should be looking. And then you wanna think about it very methodically, right? So typically, if you can figure out that the issue's coming from, let's say a plug-in, the next thing you wanna do is to if you don't have interactive debugging, typically what you would do is you would just kind of half it, right? Like you'd say, well, I think that this is happening before this point in the code, or maybe after that point in the code. And you could do a few tests and see if maybe you're still running the issue, if you just split things in half. So for example, there's a tool called get bisect. So it's a great tool, especially when you're dealing with who changed what and broke this thing. So if you use get, you do all your commits.  You say, this one works, this one doesn't. And then you can use get bisect and systematically go through and figure out exactly which commit the issue happened in. So that can really help you narrow down where the actual code changes were made and maybe what they relate to. But ultimately, one way or another, you can't beat actually jumping into the code and going line by line by line and looking at it and inspecting the variables and doing those kinds of things. And that's really what this talk is about, right? So we wanna use the scientific method, right? So you make an educated guess, you form a hypothesis, you figure out what you're gonna have to do to prove or disprove that. And then if you prove it, then you found the issue. If you disprove it, then you have to figure out what other possible causes there are. So as far as interactive debugging, kind of the standard tool, there are other ones, but this is the one that I use, it's called xDbug. It's a PHP debugging extension by Derek Rethans. And the URL there is actually for their install wizard. So the wizard is nice because what you can do is you can take your PHP info file or output, I guess, and you can just paste it in there. And it will tell you exactly what you need to do for your specific operating system distribution configuration to set xDbug up. However, if you follow my steps here. I didn't mention the link for the slides is on Twitter. So if you look right before this talk started, I posted those. So you'll have a link, all the links and things will be on the page where the slides are. So yeah, so it's got the install wizard, you can easily get that set up. But ultimately, if the process that I'm gonna explain, you won't actually have to go and set this up, hopefully. So one of the things that xDbug does at a very surface level, so if you just got it set up, it would do things like take your var dumps, which a lot of people have started, when they start PHP, they start with var dump, and that's their debugging.  So you end up with something like this, it's kind of messy, kind of hard to read. And it'll take it and turn it into something different, right? It's a little easier to read, and that is not the full benefit of xDbug by any stretch, but it's a start, right? So when you do use var dump, you at least get a better output. The other thing that it'll do is if you have an error, something like this, you get a little bit of information. And if you have a background that's black, you won't actually see this. So xDbug will turn into this. So it adds the call stack, it makes it bright orange, you can't miss it. And then, so it gives you enough information that if the error here at the top doesn't really make sense, or says it's related WordPress core, and you look through the call stack and realize it's related to a plugin, saves you a lot of time. So xDbug is nice, but when you pair it with PHP Storm, which if you don't have it, you should go download it. It's a great tool about, there was a survey done of this. I think it was like, it was somewhere between four and 8,000 just PHP developers, not necessarily WordPress developers. And about 38% of them were using PHP Storm, which was the majority in the survey that they did. So it's a really good tool, and a lot of people use it, and there's a reason for that. So if you use PHP Storm, you can go to this URL, and you can set up some debugger bookmarklets. So they have a little bookmarklet. You just drag it up to your browser bookmark bar, and you can click start debugger, and stop debugger, and it'll turn it on and off. Which basically sets and unsets a cookie in your browser for debugging. And then on the PHP Storm side, there's just a little button that looks like a telephone. You click that, and it'll start listening for debugger connections, right? And so this is their zero configuration debugging set up. So that's really all you have to do to get PHP Storms or something. So you have to have obviously a project open and running in PHP Storm. But then you have those bookmarklets that set the cookie, and then you push that button. And you go back to the browser and reload your page, and it'll start debugging, as long as the code is local, if it's not, and there's more set up. You can do remote debugging, but I won't go into that. So the benefits of having debugging in PHP Storm, and again, you can do this in other tools. Sublime, you can set it up. Sublime isn't so much an IDE as a glorified text editor. So PHP Storm is a full-fledged IDE. But what you can do is you can just set a break point, right? So wherever you want to pause the code, you just click over here off to the left, or to the right of the number on the line of code. And what it'll do is it will set a break point, and when you start the debugging, wherever you end up, it'll highlight it in blue, and you can step through line by line and go through the code. And so one of the things that you can do as you go through is you can view all the variables that are in the current scope. So if you're in a function and you have very specific variables that are available, you have those, but you also have access to the globals. So for example, if you submit a form, like save a post in WordPress, you can actually inspect all of the post variables that were submitted right there in the debugger, which technically you could do that in Chrome development tools, but when you're debugging, it's nice to have all this in one place. And you can also watch variables and functions. So you can say, I want to watch this very specific thing, or run this function and tell me what the value or output of it is, and it will do that. So here you can see an example of fetching a key or a value from an array, running a function, and running a method from a class instance that is currently in scope. So the other thing it lets you do is, aside from if you have an error, it gives you a call stack, well obviously if you don't have an error and you're just running through the code, you can still inspect the call stack and see what files and functions you've run up to that point. So if you realize that I think I see what the issue is, but I've already passed wherever that happened, you can kind of look back and see what functions are there. So that's PHPStorm and Xdebug. So one of the things that you can do to get up and running relatively quickly is to use VVV. And no, that is not the VVV logo. They don't actually have one, but I found something that looked good and put it up there. So with VVV, you use a tool essentially called Vagrant, and it creates a virtual machine and allows you to have a local development environment. So if no one has used that before, it's a great, easy way of setting up a local development environment. And what it allows you to do is also share that environment with other people. So everyone can have the same thing that they're working from. But the cool thing about VVV is that it actually has Xdebug already set up and ready to go. The only thing you have to do is turn it on. So all you have to do is vagrant SSH into the VVV instance. You run Xdebug on, and it turns Xdebug on.  And of course, the benefits of being able to turn it on and off is that if it's running, it will make things run a little slower. Although, on my machine, it's so minimal I usually don't even notice, but you can turn it off to make things a little bit more performant when you're not debugging. But it is important to know how to turn it on, because every time you shut down and reboot your VM, it will require you to turn it on. But one of the other things that you get from VVV, besides just the fact that Xdebug is there, is a tool called Webgrind. So when you use Xdebug, it can create these code profiles. And Webgrind actually allows you to view these code profiles in a nice format. And this is just a code profile. They actually have what they call code graphs. So it's a visual representation of all the functions that were called during a page load, and how many times, and in what order. So you see a box that represents the function that was called, and you see arrows that point to where that thing went from one function to the next. And you can see, I mean, it's usually massive. So it's not something you want to profile every page load that you do locally. But if you're trying to get to the bottom of a performance issue that is within PHP, it's a great way to go. So the next thing that you want to do is after you've kind of jumped into your debugger, you've stepped through the code, maybe found the issue. Obviously the next thing you want to do is fix it. So a few things related to fixing the issue. You want to make sure that you have truly isolated it. So you want to make sure that if you go to fix the issue in the way that you're thinking about fixing, you don't cause collateral damage. So if there's a way that you can refactor it so that it goes by the single responsibility principle that your function or method has got one thing that it's trying to do, it will help you in fixing this and or future bugs, but also setting up a regression test. So if you have the ability to do some sort of testing, whether it's PHP unit or maybe it's more of a front end bug and you want to do an acceptance test or something with code deception, you can do that. And that way, if somebody makes a change and breaks it again, you at least would pick it up automatically. And then finally, you want to make sure, obviously, that you've fixed the issue. So you want to go back and test it after you've made your fix and see that the issue is resolved. If it's obviously if it's not, then you'll want to go back and try again. So that is a very quick introduction. And I'm expecting probably more questions than I actually have a live demo. So I'm going to try for the live demo here and hopefully get some feedback from you guys in this debugging session here. So I'm going to see if I can switch screens real quick. Let's see. So I think I just need to turn off mirroring. There's my mouse. OK. Green just got real small. OK. So here is a, this is WP.com, so obviously. This is just my local development. WP.com technically redirects to WordPress.com, so I just decided to hijack it for local dev because it's short. So I use it, that's where my VVV primary development area lives. So basically, as you can see, there are two bugs. They could be the same bug. They could be different bugs. But nonetheless, there are bugs here that shouldn't be. So let's start by getting some input. If you were to start and figure out why this says bug and trying to get rid of it, where would you start? Edit post, hey, we got a bright one here. And lo and behold, we do have one bug in the post itself. You always got to weed out the user errors first. So we'll get rid of that one. Excellent. So now we only have one bug left. That was an easy one, data issue. And one thing that I've found with data issues is that if you ever find that you have a bug but it only is kind of isolated to one section or page on the site, a lot of times it's a data issue. Sometimes it's related to people entering in the wrong data and sometimes it's related to some weird processing or failure to migrate certain data. But that's usually a good indicator that you're dealing with a data issue as opposed to an actual code issue. So for example, if we left that in there, you'd find that Hello World has that in it. It would have two bugs, right? But if you go to any other posts, it would only have one bug. So that's how you know that would be a data issue. But now what we've got is a bug that we need to go and figure out. So if you were to step through the code line by line, where would be the best place to start? The template. So this is 2015. So I'm going to switch over to now just so you know, I've already technically clicked the start debugger in here. So it's actually the cookie is set. So we'll debug everything for us. So this is PHPStorm. And as of right now, we have the debugger not on. So this little button right here, if you just click that, it goes from red to green. And now it's actually listening for debugger connections. So what we're going to do is we're going to happen to WordPress content themes 2015. And if you know anything about 2015, ultimately the content is in these files here that are prefixed with content. And given that we are currently on a post, I believe. Yes, a post. So it's not a page. It's not a no content. It's not a link. It's not search. So it's got to be the fallback, which is content right here. So we're going to pop that open. And so when you take a look at this file, all we want to do is find where the content's output. So obviously this is where your domain knowledge, if you don't really understand enough about WordPress or the template hierarchy, and those kinds of things to be able to find where your starting point is, you want to make sure you learn enough about it to do that. But what we've got here is the content. So we can click right there. And that's going to set our break point on the content so we can step into that and see what's going on. So I'm going to switch back over here. I'm just going to reload this page. And now it's going to pause us right here in the code. So as you can see, the call stack over here is on the left. And it is actually going to show us all the files and functions that we've stepped through already. In the center, you've got your variables. So you can see the variables that are currently in scope. And since we're actually in a template, there's a bunch of global variables that are available. And then on the right over here, we're going to get rid of that, and that's not supposed to be there yet. There's watches, right? You can set watches. So at this point, what we really want to do is just step into the content function and figure out what's going on. So I've got my little shortcuts here. So I can step into that. So the first thing it's going to do is it's going to step us into the translation function because there are some things passed into the content that need to be translated. So I'm actually going to just step over that. So I could step into the translate, but I'm just going to skip by it. And then so there's the title. I don't really want to be in that, so I'm just going to get back out of that. So now we're in the content, right? So that's the function that's going to take place. And there's the get the content. And so this doesn't take forever. I'm going to nudge the movement through code towards the direction where I know the error is. But in this case, you could step through every single line and figure out what's going on. A lot of times when you do have bugs in WordPress is related to the fact that there are actions and filters. And when people use those or use those incorrectly, weird things can happen. So if you're in WordPress core, chances are, and you're stepping through that code, chances are that the problem actually isn't in WordPress core. Well, it is possible. If you're doing custom development and the issue came because of things that you created or other people on your team has created, chances are the issue is not in WordPress. So the most likely answer is to step in through the code and find places where you can tap into WordPress functionality via filters and actions and such. So we're going to intelligently step into this apply filters. So we're going to step into that. And so apply filters, being able to kind of debug through apply filters is kind of an art form to itself, I guess. There's a lot of stuff going on. I mean, hundreds and hundreds of actions and filters get registered. And at any given time, you could be looping through a lot. So what you can do, you can step through the code until you get to a point where you get into this do loop. And so right here, where it says callUserFunkArray, it's right before it executes some custom callback. So the callbacks that you normally register with addAction or addFilter, those are going to be called via this method here. So we can see that we're on the content tag. So it tells us what the name of the action or filter is that we're working with. And then, as you can see here, it's going to actually call the function, which is the callback function. So there's this v underscore array, which has the callback function and the number of accepted arguments. So what we're going to do is we're just going to take this function here. And we're just going to pull that on over here. So that's our callback function. We can span that out over there. So now we can actually see what our function is that's about to execute. And we can decide whether we really want to step into that or not. So run shortcode, and we'll step over that one. And then, so now we're in auto embed. So a lot of these are things that WordPress does, WP texturize, convert, smileys. So these are things that WordPress will do out of the box. So a lot of times, you don't want to step into those because, again, WordPress core chances are your problem doesn't necessarily lie with that. So we'll step through until we see something that looks suspicious. Aha, closure. There we go. So we have a callback here. That's a closure, accepts a parameter. Our debugger's not going to show it to us. So we're going to step into it. So we're going to step in. Ah, there we go. Content adds a bug at the beginning. So we found the issue. Now, what I'm actually going to do is figure out what I can do to get rid of this bug. So be nice if we could test to see if there's a way to get rid of the bug without actually having to change any code. So being able to test your hypothesis without actually changing code is a good way to go. No point in changing anything or in breaking anything unless you know for sure it'll work, right? So what I'm going to do is I'm going to set a break point right here on this if is true. Now, obviously we can tell that we have a callback here that's adding content, but we're going to pretend that the issue's a little bit more involved and just see what we can do to, you know, is there, is it really this thing, right? Like if we set is true to false, would the bug go away, right? So, and that should be the case. So what we're going to do is we're going to stop the debugger. We'll come back over here and reload the page. And so now, yeah, now we're at the point where it's actually doing this if is true. So one of the nice things about the debugger is that not only can you watch things, not only can you view the variables, but you can also actually edit the variables. So what I'm going to do is I'm going to find the variable is true, which is right here. And it's actually going to allow me to set the value, which I'm going to actually set to false. So when I do that, and then I step into the next line of code, it's actually not taking me into that if statement. So I'm just going to allow the code to finish running through, and I'm going to get rid of this, so it'll run all the way. And so now we can test and see, ah, our bug is gone, right? So we've managed to alter the flow of the code without actually editing the code to prove that our bug is now no longer there. So now, we know exactly what we need to do. Close all these files we don't need. So this is our bug, and if we could just change the value of is true to something else, our bug would go away. So we can set it to false, there we go. And then we can turn off our debugger and reload, and voila, so it's fixed. So that is some of the cool things that you can do with PHP debugging. So hopefully if you've not experienced this before, I would encourage you to go get this set up to where you can do that. And I am more than happy to help you get these things set up, whether it's your local dev environment, configuring X debug, setting up VVV, working with PHP Storm, actually debugging stuff. More than happy to do it, so if you catch me at any time, feel free to ask me about that. But, so we've got some time here, probably about 15 minutes or so I guess for questions or so. And then, so if, any questions? Yeah. So when you change it, as long as that variable is in scope, it will be set to whatever you set it to. So if it's a global variable like post, and you change the post ID, then you've changed it for essentially till something else comes along and overrides that. So, and one of the cool features that I did not demonstrate is that you can actually, let's say we have, so okay, well, we should probably set this to is false, right? So that the variable name matches up to this true value. And I'm gonna type in one hand here. There we go. So the cool thing that you can do here is that you also have the ability, let's say instead of actually changing the value of this, you wanted to actually force this code to run. So one of the things that you could do is you could come right here, get your debugger on, reload the page, okay? So you're at this point, and there's actually the ability to force step into a conditional. So I'm at this if clause, right? And false is false is false, so it's not gonna step in there if the value is false. But if you do a force step into, oops, it will actually jump you into that conditional, which it should have done. Let me see, make sure I have the right button. Force step into, yeah, so that one should, well, it worked earlier. Right, yeah, you can set the value so that the conditional matches and it goes into the code. And you should also be able to force it to go into that conditional regardless of the values. Right, exactly, yeah, so. Not quickly is it, can you commit those changes you made in that panel to files? Yeah, yeah, yeah, so PHP Storm, now technically I don't really use the version control capabilities of PHP Storm in PHP Storm. I actually use an external tool for that, just personal preference, but it will absolutely allow you to do that kind of thing. Why don't necessarily mean versioning, I just mean just quick command to like, you set that to false, if you wanted to commit that change to false, not necessarily commit like, you just wanted to change it, do you go and find the files and change it? When you say find the files and change it. You're changing it. So yeah, I mean, in this case, you know, Debugger spits me out into this file, right? As I step through it, it takes me to where that is. So I can change it here if I want to. I guess I meant when you changed the variable down at the bottom to at the beginning. Oh, down here. I got you, I got you. You would change that and that variable was set. You can change it from right there. So normally, yeah, normally the variables down there are all generated during runtime, so they could be completely different. At any given page load. Right. So it's not really smart enough to go back. Right, so it won't really do that, but yeah, typically, I mean, you could easily go to declaration, and I'll jump you to where that was originally defined, and then you could change it, but yeah. So any other questions? You said before the compute was already set in your browser. Right, yeah, yeah. So, yeah, so with the Ajax, as long as your debugger is running and you have a breakpoint set up, it doesn't matter whether it's an Ajax request, post a git, or whatever. Do you just have that set always listen first? Yeah, I mean, I generally, I generally when I'm working, I have some debugging I'm gonna end up doing at some point, and like I said, for me on my machine, it doesn't slow me down at all. So I usually just leave it on, but usually in the browser bar here, you know, you can hit stop debugger and it'll unset the cookie. So you can stop it from the browser side or from the PHP storm side. And those browser requests you got from the page? Right, from that webpage. So, but yeah, usually just once I click start debugger, that cookie is just kind of permanently set until I turn it off. And since it's just a cookie, I mean the cookie's not slowing anything down. So I usually just leave it on and then when I wanna turn off the debugger, got a little shortcut that'll turn it on and off up there. So, makes it real quick. Yeah, I'm just curious a little bit about the VVV cluster, what's the, what are that? Right, so VVV kind of started out as a 10-up project where they were creating a virtual machine for WordPress development. So, now it's kind of a standalone project and it is kind of maintained by a lot of people within WordPress because that's what it does. Yeah, it actually comes with, I think, four different copies of WordPress out of the box. Three of them are more if you're gonna be doing like WordPress core type development. And one is for general use, you know, throw a plugin, throw a theme in there, start creating and do whatever you want. So you could, yeah, there is, I think, it's a local.wordpress.dev, so you can actually go to that. Matter of fact, once you get VVV set up, it creates this really simple shortcut, VVV.dev, which gives you links to all the things that WordPress has, or that VVV has out of the box. So this local.wordpress.dev is, you know, the most recent stable version of WordPress, which I threw some stuff that doesn't work on there. So yeah, you get that out of the box and a few other copies, so if you wanted to do some WordPress core work, you could as well and have some of the built systems and things that go with that. But it does have a link to the VVV repository. It comes with PHP MyAdmin out of the box, so you can jump into that. It's got PHP MIMcachedAdmin, UpcachedStatus, things that you might be less likely to use, but the Webgrind, which is that tool I was telling you about, where it will allow you to take your code profiles and view them, and also potentially view them as call graphs, and then it also has your PHP Info here as well. So again, if you're not using VVV and you have to go set up Xdebug manually, let's say you're using WAMP or something like that, you could just get your PHP Info file, copy that into the Xdebug wizard, it'll give you step-by-step instructions on setting it up, and then usually it works pretty well without too much confusion, so. Any other questions? There's another add-on. Yeah, yeah, yeah. So yeah, yeah, the nice thing is with VVV, there's, if you drop in a few configuration files and you were to essentially create a new directory in the WWW directory in the NVVV, it'll allow you to actually add your own projects, right? So you could add as many projects as you need to, but there's, you can manually set it up or there's other tools that you can use that will allow you to quickly spin up a new project in VVV, and then the nice thing is what you can do is you can have a separate repository for that project, and those configuration files for VVV, which is like three files. They'll actually live in that repository, and so then you can just say clone this into VVV to anybody, and they can actually have the exact same setup that you've got without any hassle, so. Besides your debugging, is that one that you wrote? You saw it pretty, that thing that you wrote. One with two bugs on it, so. Oh, this thing here, which is, yeah. Yeah, hello world, that's something that you wrote. So, well, no, this is actually, this is default WordPress content, technically, so it's just the, say what? You put the two bugs in it. Yeah, I put the, yeah, I added it and added the bug. I guess what I'm getting at now, this is a remote site, just like you was looking at for the browser, can you get into the PHP code on a site that you do not code? You can. With the debugger. You can. There is a prerequisite that you actually need to have XD bug on the remote server to be able to do that, but you can do remote debugging, so you can actually, if you have a production server with XD bug on it, then you can actually use PHP Storm to remote debug through your code. Doesn't that serve to be your server? No. Unless somebody stuck it on there for you. Right, exactly. Which is, you know. Yeah, that's a great question for you. So it's, yeah, it's nice. So being able to do remote debugging is pretty cool, but. So you can't look at Facebook code or anything? No, no, no, yeah. I mean, they would obviously have to, have to have some of these things set up, and you would have to have SSH access to whatever it is that you wanted to work with, but with those two things, yeah, you can, you can remote debug, so. Any other questions? So, yeah, so the question being, is there a good tool or way of doing debugging performance issues with MySQL, basically, right? So, or I guess, MariaDB or whatever it is you're using. So, yeah, there is. So, at the simple to get started level, there's a few plugins, and actually if the link for the slides that I sent out on Twitter right before the talk, that actually takes you to my website, and it has not just the slideshow, but some additional links as well. So, there's a couple of plugins there that will actually surface within WordPress, the queries, and allow you to kind of analyze them on any given page load. It just kind of will always log them if you have that plugin in there. But you can, I use a tool for, I guess it's, they may have a Windows version, I don't know, but at least on Mac, I use a tool called Navicat for MySQL. And so, what this allows me to do is to, for example, if I go into VVV, I can see all the databases that I have in there, and then I can pop open any one of those and actually look at everything, but it also allows me to actually write a query. Yep, there we go. So, I can create a new query, and actually I can actually write my own query and run it, and it will tell me how long it took to run and all that kind of stuff. The thing you have to be aware of when you're doing database performance. So, tools like this, and you run a query, and you run that same query again, MySQL will actually cache the query, so you have to flush the cache to actually get results that aren't skewed. So, you have to be careful about that, but yeah, tools like this can allow you to play around with the query and add an explain or whatever to it and allow you to debug through that. But yeah, a lot of times, if you have a WP query or something where the SQL is generated and you don't necessarily know what that is, what I'll do is I'll take the debugger and I'll step through the code until I get to a point where that query is now available as a variable value, and I'll copy that, put it in here, and see what's actually happening and how if I change this or add that, will my results be different? Or maybe if I, you know, if there's a way I could optimize the query somehow, then I can go back and add a filter in WP query that would optimize it or change the outcome. So. And you plug it in here, do you have to clear your cache after this? So, well, MySQL itself has a cache, right? So you actually have, there's a function in MySQL that allow you to flush the cache, so. I'd have to Google it, I can't remember off the top of my head, but. I hope I have a very useful. So, but yeah, it's an actual MySQL query that you would run to flush the cache, so. So this is, yeah, if you're on Windows, there's something called Heidi SQL, which is free, and it does basically the same thing. There's MySQL tool bench, there's a bunch of them, some of them are open source, some of them are paid. So, so yeah, this is one that I found that works well for me, so. For Windows, yeah, it was Heidi SQL.  I could write it down, no problem. Yeah, H-E-I-D-I, right, yeah. So, any other questions? So, yeah, if anybody wants help getting set up with actual interactive debugging, just let me know. I'll be around, so I'm always happy to answer questions or help out. So, appreciate it.