Placeholder Image

字幕列表 影片播放

  • Good morning.

  • A quick sound year Looking at audio room.

  • Good morning.

  • Happy cutting train day.

  • It is me, Dan.

  • I was like, taken back by the fact that I had to start.

  • I thought I had another 30 seconds.

  • Um, there there's a lot to say, probably as there often is on.

  • And I'm, you know, while you are watching the coating train.

  • Perhaps at this point that you just be called the nature of cocaine trade.

  • Because I am just still slogging through making Theo examples in the nature of code book.

  • And that's what I'll be continuing today.

  • Do you have some ideas for things in the next few weeks?

  • A month or two, where I will hopefully take a break from nature of code.

  • But I would like Thio by June and kind of get through the entire book.

  • We'll see if that happens.

  • But before I do any of that at all, I have to test something you might I don't know if you noticed something slightly different about me and No, no, not the haircut.

  • There can I had last week.

  • Same haircut.

  • No, not this sweater that I don't think I've ever warned.

  • before, Although have worn this shirt, it's something else I will.

  • I will wait for a few minutes to see if anybody can notice something else.

  • That's maybe a little on while I'm waiting.

  • I will take a brief moment to thank the sponsor of today's coating train.

  • Dash lane dot com Dash is a password manager.

  • If you don't have a password manager, you should have a password manager and I would.

  • Dash line is one that you could try.

  • And if you go to dash dot com slash coating train, you could get a 30 day free trial of their premium service.

  • And then also, if you choose to purchase the people service a 10% discount and everybody's got it.

  • The chat already everything?

  • Yes, yes, new glasses, but not just new frames, which hopefully you oh blue reflect.

  • Okay, so that's interesting.

  • Let me address that.

  • So the lenses are really what I'm here to discuss because something quite big changed, Which is these air progressives.

  • I've been having a lot of trouble reading, really for the last year or two, and I would have to take my glasses off to read.

  • And so the options as I understand them.

  • What?

  • Besides all sorts of like laser eye surgery options, Uh, were thio.

  • Just get a second pair of glasses so I would switch if I'm going to read.

  • But that's sort of silly because I could just take them off to read, which I've just fine doing.

  • Um, that was that.

  • Well, the other option was just do nothing.

  • But the third option was get progressive, which I now have, and I have to say, I mean, I've only had them for think I got them on Tuesday.

  • So I mean, like, for about 48 hours in, and I'm having quite a difficult time with them if I'm being perfectly honest, although I'm much more used to them today than I was yesterday or the day before, But I know of anybody watching were also young and youthful with your excellent eyesight.

  • Just wait.

  • Just wait until you get to be me and you need these What I wouldn't really rises your because of the way the lenses progress for distance and reading.

  • There's some distortion on the sides.

  • We're gonna create that progression.

  • And so it's My peripheral vision is less.

  • It has a smaller cone vocal.

  • What's the thing?

  • Flash frustrate.

  • My frustrating of kitchen is smaller, but the good news is I mean oh, for you the viewing audience.

  • Because I know your favorite part is me reading random numbers.

  • I'm looking at the chat here, Um, and this I could just do so easily.

  • Now reading is quite phenomenal and I wasn't really able to before.

  • So we're gonna do a reading of the ceremonial reading of the random numbers with my new progressive lenders and people had mentioned there's a blue, um and so I did get I did.

  • I don't know.

  • Maybe this is silly, but I did get the blue light filter in them, which, hopefully is not going to be too distracter caused, like, weird reflection in me making these videos.

  • But we'll find out field of you.

  • Thank you.

  • I have a problem.

  • I can't remember words anymore.

  • I think it's related to the fact that I did present lenses.

  • It's get stuffs all going downhill may go watch my always say, like all those videos are so old, they're out of date.

  • I think I had was like I was much more with it Then you go back to the old nature of code videos.

  • 12,931.

  • 52,107.

  • 92,823.

  • 39,994.

  • 74,677.

  • 99,470 What?

  • 54,000.

  • 65.

  • 54,980.

  • 96,256.

  • 8823.

  • 25,479.

  • 70,820.

  • 39 6 79,294.

  • 93,170.

  • 34,460 The music is a bit loud.

  • Okay.

  • Thank you.

  • That's useful to know.

  • That's a Oh, my goodness.

  • It certainly is sorry about that.

  • No wonder everything seemed off.

  • Uh, sorry about that.

  • I'm fixing.

  • Why is blue filter useless?

  • No, I think it is useful.

  • I'm just Sometimes I what wonder?

  • Like, what's this?

  • What's the real science behind blue light filtering and what studies have been done?

  • And how effective is it?

  • How bad is blue light?

  • How effective is the filtering.

  • But you know, And you know, one thing that I try to do is you know, I really get myself like I should give myself, like, eight PM limit, but nine PM I try after 9 p.m. I try to look at no phone, no screens, nothing.

  • I'm watching a movie or whatever, but, um and I don't want the fact that I have a blue light feel sort of Give me an excuse if you like.

  • Oh, now it's 10 o'clock at night.

  • I could play Pokemon.

  • Go on my phone.

  • Not that that's what I play.

  • I don't play that No, that's like That's like, so two years ago.

  • And, you know, people in their forties don't play that anyway.

  • So why why would I be playing that?

  • No, definitely not.

  • Not like trying to get to level 40 or anything.

  • And I don't have like, yeah.

  • No, no, no, no, no, no, no, no.

  • That's somebody else.

  • It's 8 p.m. Here coincidently.

  • Yes, Sri on.

  • Turn this off.

  • You've got to get to sleep soon.

  • The blue light emanating.

  • It's not worth it.

  • The coding train is not worth it will be here tomorrow morning when you wake up and our friends, um I do use night shift.

  • Yes, I d'oh ideas nightshift Lucas, asking to use the night shift also used that which I quite enjoy it.

  • All right, I would like to get into it pretty quickly.

  • I'm ah, there's a little less of the hijinks these days on the coding train because I'm trying to I'm trying to be a serious teacher of content.

  • I'll be here till around noon.

  • Um, and that's that.

  • Let's see, what other kind of host, like my screen is like, distorted, especially Look, from left to right.

  • It's like a waving, bubbly thing.

  • Okay, but I'm gonna I'm gonna I'm gonna be fine.

  • All right, Let's open up the chrome browser.

  • Um uh and let me just mention one thing.

  • Um, I I'm really not mentioning this to ask anyone to buy anything or spend any money.

  • I just want to let you know what's going on.

  • Because some people have asked the coding train hoodies have hit the minimum number of orders to get made, so they will be on the way.

  • Nobody needs to buy any more, but I just wanted to mention that if you were interested.

  • I think maybe tomorrow I'm going to say, Hey, go ahead.

  • That's enough orders.

  • Send them to the goody maker.

  • Uhm And so I don't know that you'll be able to order them anymore after tomorrow.

  • So if you were interested in getting a hook quoting trade Hoody, I mean, hopefully we can put them up for sale again, or make them or make T shirts or something new next time.

  • But they do these air being done in limited runs in terms of how they're being made in the quality.

  • So if you were interested in one of those, um, now you're letting your last chance.

  • Um, okay, also, by the way, I put one of these mugs in the dishwasher here at work, and it got a little faded.

  • So if you have one of the mugs, he hand wash it and wash it.

  • Does anybody have one of these?

  • I don't have one of these.

  • If you have one of these, could you send me a picture of it or something sent to me on Twitter?

  • Social media, whatever discord joined the discord.

  • That's the other thing that I would like to mention the discord has been as far as I'm concerned.

  • A big success don't success is the right word, but has been really productive in that.

  • It's I don't know where to tell people to go to get help specifically related to the content of my videos.

  • There's lots of places on the Internet to get code help.

  • Some are, you know, they all have their pros and cons, and they're sort of vibes and different strokes for different folks.

  • The processing forum discourse, uh, discourse.

  • It's confusing is not discord, but discourse.

  • Start processing dot org's is a really excellent place to ask questions about processing and p five jest specifically on.

  • I would say there's a lot of crossover between the coding train community and the processing discourse, but if you want to engage with getting help from the, you know, laser focused coding train passengers, then the discord is the place for you to do that.

  • And if somebody I know that I saw Kobe's name pop up in the chat is composed, a link to joining the discourse, the discord in the in the YouTube shot, that would be helpful.

  • Um, now I also wanted to mention a couple of things.

  • Google Summer of Code.

  • Um, I think this will get me to the site.

  • I can't remember if I mentioned this or not, but the organizations have been announced.

  • Yeah, because this was announced before.

  • I probably did this last week, but Google Summer of code is a program that I participate in as part of the processing Foundation.

  • But there are over 200 I think.

  • Whoa!

  • Oh, no.

  • Over 686 over, however many years.

  • But there are a large number of other open source organizations that participate as mentoring organizations for Google Summer of Code.

  • And you, if you're a student, you have to be a student.

  • Unfortunately, or fortunately, you can apply to work with collaborate with making open source contribution to one of those projects over the summer and get paid a stipend.

  • So again, I'm not an official representative of Google or Google Summer of code.

  • All of the administration and application process and eligibility is handled through them.

  • I'm just here because it's a program that I participate in as a mentor and would love Thio encourage you to apply if it's something that interests you.

  • And to the extent that I can help with that or we can maybe we can open a discord channel for people who are questions about that.

  • That's something that I would be open to.

  • Thank you, Kobe, for posting the discord invite.

  • I should probably get a button like I have one button on my stream deck when I press it it both to two into the chat.

  • You know, I should maybe make one.

  • I need to get this stream deck with the with more buttons.

  • I need more buttons.

  • Oh, my God.

  • I just want I just feel like a giant panel of buttons.

  • That's my dream.

  • Um, all right, so that's that nature of code is what I'm gonna be doing that with other things I shouldn't make a list of you would be so helpful if I've just made a list of things that I wanted to mention as opposed to just try to remember them while I'm live streaming.

  • Just think about this for a moment.

  • Yeah, I thought of it.

  • All right.

  • So there's two things up and coming on this channel that are unrelated to the nature of code Well, everything's kind of related nature of code.

  • One is March 14th is Pi Day.

  • And traditionally I've tried to do something special to mark the occasion.

  • I will be I'm not available to live stream on Pi day, so I'm probably going to prepare something in advance to really be released on Pi Day.

  • But I don't have any idea what to d'oh.

  • So, um, if if, um you know, certainly I'll take suggestions in the discord, But right now, for better or worse, the system is a get hub Repo where you can if you have a suggestion for a top.

  • Oh, no.

  • Whoa, whoa, whoa.

  • Hold the presses.

  • We have a new member Ho's day.

  • He Oh, welcome for your membership.

  • Could train.

  • You have one random number, and that number is 94,000 544.

  • You are the sole owner.

  • I mean, I don't think we're ever gonna get to a 1,000,000 members.

  • That would be kind of nuts.

  • I will just ride off into the sunset if that happens.

  • Um, and thank you.

  • By the way, if you don't know, uh, let me see if I can find, um I'm gonna do this?

  • Um, I'm looking for There we go.

  • Perfect.

  • That's what I'm looking for if you're not aware.

  • And I'm sorry if you don't want me to be plugging this, it's too late for you.

  • You put this on the internet, I get the blood get without your permission.

  • Um, uh, Jose teaches a course called Interaction of Computational Design, and it seems like it's at Harvard, and all of the lectures are all online in this playlist.

  • Is this a learning playlist, or is it just a regular playlist?

  • You should get access to the learning playlist.

  • If it's not, it looks like a learning playlist.

  • So, um, check.

  • Uh, check this out.

  • Welcome.

  • Thank you.

  • Hello.

  • I was talking about something, huh?

  • Hi, day.

  • So back to this.

  • So if I go to a label, you won't be able to add your own label.

  • But I encourage you to file your issue with your suggestion, and then I will, or somebody else will add it.

  • But I'm just gonna see what's there right now.

  • So, um well, hi.

  • Day 2020.

  • Let's see, there's every year.

  • So you look at this every year, Dan does a couple cool.

  • Yes, thank you.

  • I am, As my kids tell me.

  • Very cool.

  • I'm the cool dad.

  • Definitely Every year tantas a couple cool coding challenges related to calculating, visualizing or using pi This year would be a good time to start a pipe.

  • Flint's No, no, no, no, no, no, no, no, no.

  • You can really make last year's pi Day challenges and fight on.

  • And also explained python today it is a really nice idea.

  • Dee dee dee dee dee dee dee dee dee dee.

  • Um um But, um, I'm not sure that that's gonna fit with my schedule and figure, but there's there's something there, um you know, actually, at my son's school not to keep talking about my kids today, but they're always on my mind.

  • They have a pie digit memorization contest.

  • So I wanted I was thinking, Is there a tool I could build that helps people memorize the digits of pi?

  • If you have any ideas about that, but it really anything that is a especially if it's like a beautiful geometric pattern algorithmic pattern.

  • That's what I really like to do for these kind of challenges on that relate to pie.

  • Um and the mathematics associated with pie.

  • Then please suggest that year, um, as a get hub issue or talk about it in, um um in the discord.

  • Otherwise I will be just baking a pie.

  • Oh, that's what I should do Clearly, I mean, because have you all seen the bone appetite?

  • You too, Champ.

  • I know I'm, like, really late on this, but it is just a chef's kiss.

  • I just wish that I could be like one of their cooking people, which I definitely cannot be.

  • There's no way.

  • But I aspire I can a spike in dream DT six, which I assume is the same d d d d D T T T T T t t has memorized 80 digits of pi I would like How did you do that?

  • Maybe I should just try to memorize them, But I think I don't think I could do a live stream, so I don't wanna be like a live pi day, Um, Lifestream this year.

  • But I do want to do just like a video.

  • Maybe I'll do it.

  • Is the cabana one or something like that?

  • Well, I'd be here on Talladega.

  • Yeah, maybe I'll just wait till talented.

  • So that's number one.

  • Number two is insanely, and I really don't understand how this is possible, but it seems as if this channel will soon have one million subscribers.

  • And I'm assuming that then the next day they're just like everybody will unsubscribe but you know, at least probably at least for a day on.

  • I kind of want to do nothing like just, like, keep going as I'm usually doing.

  • But people are asking, and maybe it is a nice thing to think.

  • Think of doing something special to celebrate that so I could use ideas.

  • I really want to do something with the original original.

  • I know I got to keep mentioned.

  • This told somebody If you live near like a rare bookstore or have some way off finding a copy of an original, I will pay.

  • I will pay for shipping.

  • I will purchase all these things I would very much like to purchase a original print of this 1,000,000 random number book.

  • I have found some listed online, but there's no way for me to authenticate them.

  • I've emailed and asked.

  • Mostly, I'm seeing them through Amazon listings, and no one will give me any real information.

  • And I don't feel like it's a good idea to spend a large amount of money to purchase something that I have no idea what it really is.

  • Okay, Welcome way.

  • Have a new members.

  • Oh, board with cutting trade on hit.

  • When your membership of the coating train you have one stickers eventually come find the next year.

  • It takes a while.

  • Oh, also your very own rated number 11,827.

  • A new member that I already now can't see in the chat anymore.

  • It was Adrian.

  • That is your random number.

  • You're the sole owner of the rand number 11,000 and 27.

  • Please write that down, because I won't remember.

  • I suppose a lot of the numbers appear more than once in this book, though, so might have an issue there.

  • That this is the 1,000,000 random digits doesn't mean the 1,000,000 unique random digits.

  • Ah, Okay.

  • Now eso that was that, um, ideas for any kind of special video for 1,000,000 subscribers.

  • Um, I would the other thing that's on my mind related Thio That was it.

  • Oh, yes.

  • I'll bring this up in the discord.

  • And maybe I am working on training a machine learning model to generate text based on all of the captions of all of my videos ever.

  • And I could use some help with that, so But that all of that will bring up in the disc order.

  • That's a separate thing.

  • All right.

  • Um, number files showed that 39 digits of pi would calculate the circumference of the known universe to the with of a hydrogen.

  • Adam.

  • Whoa, whoa.

  • Okay, that's intense.

  • Oh, my goodness.

  • Simon says Simon says that eyes calculating the rate that I'm getting subscribers and estimating that this might actually happen on Pi Day, huh?

  • Well, can you slow out, please?

  • I'm not ready.

  • April 1st, I think, is a much more appropriate day for me than pied a said that last week.

  • Okay, so I think I better get started.

  • It's 10 o'clock.

  • Half an hour should really be my limit of of shenanigans.

  • Let me go to the web.

  • Editor of P five.

  • Uh, wait.

  • Hey, where's my What's going on here?

  • Here we go.

  • Lou, this isn't Ashley.

  • Wonderful.

  • Got me logged into the coding train editor.

  • I have no idea what?

  • My password is matter.

  • Because I'm using naturally.

  • Okay.

  • 36 I think is the number I tend to use.

  • Let me go to where I left off last.

  • Mmm.

  • Whoa.

  • What is going on here?

  • Oh, by the way, this is a little This is kind of an aside, and maybe I shouldn't be showing this, but let's see if this works.

  • Um, I was helping.

  • A colleague is teaching a class about animation, and this is like an animation I think made is it made an illustrator known after effects, but using a library called, um, you think a library called La di da Js and these air some, like Lottie and p five examples actually don't know what I'm talking about, but I helped, but it's cool because, like, the whole animation is all just in this big like Jason file, And then I have p five, like playing it back, which is kind of cool.

  • All right, but that's something I would like to make some videos about this, um, with alone who I worked on this example with.

  • Okay, Coming back.

  • Thio opening my sketches, The one that I want to get Is this Here we go.

  • So this is where I left off.

  • This is the last, um, we last, uh, before I left armer rights.

  • We miss Adam RVs code.

  • We don't like the browser based editor.

  • Too bad.

  • I know.

  • I get it.

  • I get it.

  • Thank you for your feedback in your comment.

  • It's important for me to use this editor because it is a tool that I feel very invested in in helping it grow and for being something that is a really friendly, easy place for people to start to learn coding.

  • So when I do certain projects that really don't fit well with the web editor, I certainly will do things outside of it.

  • But I do feel like it is a useful tool for me to demonstrate the basic nature of code examples.

  • Um okay.

  • Ah.

  • Hello, Argentina.

  • People of Argentina.

  • Okay.

  • All right.

  • I think I'm trying.

  • I just trying to figure out where I wantto kind of begin with this.

  • All right, I am going to actually go through ups, and I don't want it down with this.

  • I'm gonna go further back.

  • Friction Forces one.

  • I think this is Yeah.

  • Yeah, this is where I'm gonna This is the example I'm gonna build on.

  • Okay?

  • I really am having trouble because I don't have peripheral vision.

  • So to see the screen over here to turn all the way to the side.

  • Um okay, um, I'm gonna need to start all my recording things, so let me do that, actually.

  • Now start recording.

  • Let me go here and set the multi quarter to go.

  • One thing I also want to mention is, um I've had a little bit of audio interference.

  • I'm noticed.

  • It must not be significant because nobody is ever says anything during the live stream released.

  • I don't catch it if you are.

  • If your nose is like a little almost like in, you know, the the sits, just, like, sort of like a high pitched hum that's like slowly fades in and fades out.

  • If you're hearing that, could you let me know?

  • But any point, um and I'm just trying to get the various chat things back up here, is there we go.

  • Okay.

  • And then I need the YouTube chat back up.

  • You can see that.

  • Oh, Simon is giving me some excellent suggestions about addition.

  • Hold things I could do, You know, I've got to move on to chapter three, but I I hear you, um, um, read the entire book online for free.

  • How nice.

  • Okay, um, and then I want to go to where am I?

  • Forces in chapter two.

  • Boy, this is going very slowly.

  • Um, and where am I?

  • Here we go.

  • Okay.

  • So this is what I'm going to be doing today.

  • I am going to go through, uh, this particular scenario an example.

  • I need a minute to pull myself together here.

  • And by the way, Oh, I don't want to show this diagram because this diagram is absolutely incorrect.

  • There's a major flaw in this diagram.

  • I think I can't remember if I fixed it or not.

  • And just not on the website.

  • But this our needs to be the distance between the centers of the body's not the edges of the bodies.

  • So I hate to show this.

  • I mean, one option is replace it later.

  • So maybe Max, you, uh, what we're gonna do today is I'm gonna leave this flawed diagram up, and then I will fix it an illustrator, and we'll just, like, replace that post even if the recording system isn't working, We don't have the separate green stuff.

  • Um, we can I'm pretty sure like overlaying a diagram should be possible.

  • Although I'm gonna, like, point to it and stuff like that that's gonna really mess this up.

  • But whatever.

  • We're gonna try our best.

  • We're gonna hope for the best.

  • Everybody, Um, that is an absolute mistake.

  • Um, all right, so if I'm making a brief list, I'm gonna, um, Does this overhead thing working?

  • No.

  • What happened?

  • My overhead camera.

  • So sad.

  • That's weird.

  • Well, I am going to let me make a list.

  • So the first thing I'm gonna do is just do attraction, and then I'm gonna I think in the same video, I can make an array making notes to myself here.

  • You know what?

  • Usually I typed these out.

  • Let me do that.

  • You can see it, right?

  • Because actually, I have it here.

  • Right.

  • OK, here we go.

  • All right.

  • So I've done all these already have these notes.

  • Um all right, so this is done.

  • So gravitational attraction plus array.

  • I think I could do that in one will file might change that.

  • I think that could be in one.

  • Then I'm going Thio do repulsion plus, um, like a kind of group behavior.

  • So instead of there being separate attractors, a separate a tractor and, um, movers or bodies, whatever you wanna call them particles, I'm gonna have them interact with each other and then I'll add, uh um and I think this could I think this could all be in one.

  • So I think hopefully this will be two videos where I do the implement the basic, uh, gravitational attraction.

  • Then I just switch it to repulsion and show I could make it a group behaviour and Wall Force.

  • And then I also have I should look like some of this is a little bit redundant content because last year I did attraction coding challenge.

  • Couldn't challenge 56.

  • I guess that's more than no, that's what three years ago.

  • Are you insane?

  • Have I really been doing this for this long?

  • That it felt like, Oh, that was just last year.

  • That was three years ago that I did the attraction and repulsion coding challenge.

  • Um, just look at the code.

  • Did I?

  • I'm hoping that I was using s six classes at the time I was or I changed it.

  • Um whoa.

  • Right.

  • Okay, so then there's also this, So I'm gonna refer to this coding challenge and also included in the playlist and are not loving the chat and my mind's air Exactly aligned here.

  • Um um our, uh don't forget to mention your coding challenge on attraction Repulsion.

  • Okay.

  • So, yes.

  • So, you know, a few years ago, I didn't feel like I had time to redo the full nature of code tutorial Siri's.

  • And so I just picked and choose little things and did them is coding challenges.

  • Many way makes more sense because I kind of make one video that has a whole lot of concepts all in it.

  • But this year I'm doing it differently.

  • And as soon as I do this, I can no longer see because this is the reading part.

  • Distance reading distance.

  • Whoa!

  • I'm dizzy.

  • Dizzy.

  • Coffee.

  • Okay, so that's there.

  • This is who's a cz uh, playlist.

  • Andi.

  • I mentioned pied anybody.

  • Anybody following the issues, money to buy the ideas.

  • Okay.

  • And then here I am, and then here I am.

  • All right.

  • Okay.

  • Um, let me just actually, you know, what I'm gonna do this.

  • Oh, boy.

  • Avoid duplicate triplicate duplicate.

  • Oh, did I mess it up?

  • Huh?

  • Hold on, everybody.

  • I mean, I might have messed up that other example.

  • And if I did, I just want to check real quick.

  • They could be defeated.

  • Oh, no, I left.

  • I might have liked change something, but Oh, yeah.

  • Okay, so this doesn't need to be in there and mover is fine.

  • OK, great.

  • That's fine.

  • I'm here.

  • Get rid of the edges function.

  • And oh, I did.

  • I also want mass.

  • Um, hold on.

  • I don't need edges.

  • I don't need this fancy, but I also want to get the idea of mass back in here, which I implemented in the previous one.

  • This stuff would be nice if I did this in advance.

  • So apologies.

  • Um drag.

  • So what I did in the previous one is added a mass.

  • Wait, hold on.

  • And then I calculated the radius based on the mass.

  • So that's gonna go in here, and it's gonna take 1/3 argument and then also, um, divide by mass.

  • And then at that and and, um, house.

  • What else?

  • What else I think then then I just need to give it a mass here, like five.

  • Okay, great.

  • All right.

  • 15.

  • I love the Wesley Crusher Reference to chat Right down.

  • By the way, Adrienne, thank you for your new membership.

  • I coincidentally, I happened to see your method to the YouTube chat.

  • But pi day suggestions, if you want me to see them, the discord or the get hub Repo is the best place.

  • Um, all right, but please talk amongst yourself about all sorts of Pi day ideas in the chat.

  • Um, all right, here we go.

  • Is there?

  • Oh, are you serious?

  • Oh, this is the worst.

  • Okay, the worst.

  • This is the terrible thing that I have discovered on the internet today.

  • That when I mean this might know I'm not signed in.

  • When you search gravitational attraction, this image comes up, which is from my book, which you would be great panache.

  • The stake in it.

  • Oh, look at this.

  • What a coincidence.

  • So, by the way, my The book is Creative Commons non commercial and Khan Academy with a bushel Youth thean correct diagram also, uh, has a basically duplicated version with a bunch of changes of the nature of code book.

  • Hopefully that I'm credited on here, but I think that I am and but I'm looking for Yeah, this is what I would look for.

  • Yeah.

  • Here we go.

  • All right.

  • I have such trouble getting started, but it is time for me to get started.

  • I got to get some stuff done today, not looking at my email.

  • If I wanted to, I could just pull pick up my phone.

  • I have progressive lenses, so I can see it really well.

  • And I could see if I have any important messages.

  • But what could be more important than what?

  • Nothing.

  • But the phone is going further away.

  • I see it out of the corner of my eye.

  • It's going over here.

  • I'm taking this coding train notebook taking the phone, put in the notebook on top of the phone.

  • It is going over there.

  • All right.

  • We can start having trouble.

  • Where?

  • Some encouragement, please.

  • Well, by the time we have started, by the time you hear me say that, never mind.

  • Huh?

  • Uh, okay.

  • Uh huh.

  • Stretch.

  • Everybody stretch if you're watching, and you can whatever works best for you to, like, move any parts of your body that you can move.

  • Stretch.

  • Oh, so Raul says, just heard the noise hearing the chirp.

  • What can I do about that?

  • All right, let me I have a suspicion that may be where this receiver is placed.

  • So I have an idea.

  • So thank you for telling me that you heard the chirp.

  • And now I'm hoping I moved some wires around.

  • Um, hold on.

  • There's one other wire that I should maybe move that could be having, like, some interference.

  • Okay, so hopefully that's going to do the trick.

  • You need the siege a time where I definitely d'oh!

  • Okay, happens when I do certain poses.

  • Go.

  • Could it be I don't have any.

  • Like, I don't have any other electronic devices in my pocket.

  • Could it be the zipper something?

  • This is the mike.

  • Well, all right.

  • All right, everybody, listen, listen.

  • Standing still talking, talking, talking, talking.

  • Does it happen?

  • What?

  • I'll do anything.

  • Do not have to do like coating.

  • Can you tell?

  • Okay.

  • Oh, it's 10 for this.

  • Is this is, um all right.

  • Hello and welcome to another saying that.

  • I mean, nobody wants to look up there watching the sequence, and I just keep thinking hello and welcome to I don't know what else to say.

  • All right?

  • No, I don't like starting with that way.

  • I It is time for Newton's law of universal gravitation.

  • So this is the final example that I will be demonstrating as part of Chapter two.

  • Although the concept of forces and how they are applied permeate throughout the rest of the videos that I intend to make.

  • But I'm going to wrap up this chapter by looking at the equation for universal gravitation that looks exactly like this and trying to see Can I take this equation and implement it in a P five jazz sketch?

  • That's good.

  • That's everyone I wanted to say at the beginning, Um, so that you and I, we're gonna sort of, like hope we can fix this.

  • Um, well, see, Well, I could always come back and, uh, re record or something.

  • Okay.

  • Me?

  • Just see here.

  • Here's the same formula with the diagram in the nature of code book itself.

  • So the idea of this law is that everybody, every particle, everything in the universe attracts every other thing with the force that's proportional to the masses of those bodies and inversely proportional to how far apart they are.

  • So the farther apart they are, the weaker the force, the closer they are, the stronger the force.

  • I did something very much like this in the first example is part of this Siri's where I had actually.

  • Look, let me put this here.

  • Um, all right.

  • Oh, it's my watch.

  • Is my watch doing it?

  • Okay, that's easy.

  • I don't need to wear this silly, overpriced pizza hunka exercise track egg surveillance couture.

  • Okay, well, I feel so free food.

  • What?

  • You're gone.

  • Uh huh.

  • All right.

  • So I I don't think it's worth me.

  • Wasn't really bad.

  • And, uh, is it really bad that I need to go back and redo the intro?

  • Or was it fine?

  • Like the glitch in this audio?

  • It's gonna end up in the edited version of this, but if it's just like a little minor home, big deal.

  • Did it happen again?

  • All right.

  • I'm gonna just keep going.

  • I heard it again.

  • Well, what could it be?

  • I wonder?

  • I guess I could change the Is it just the bell.

  • Find good.

  • All right.

  • All right.

  • I'm gonna I'm gonna I'm gonna keep going in the first.

  • In the first example in this chapter, I did something very similar to this idea of the law of Attraction.

  • I created a vector that points from the mover object to the mouse and then made that vector the acceleration of the mover object itself.

  • And it appears if it's this body like orbiting the mouse itself, I got there is sort of a problem with me.

  • Keeping my eye on the chat is it's very distracting and I lose my moment.

  • So I'm gonna just take a break from looking at the chat and I'm in a minute.

  • I'm gonna plow forward this because I shouldn't keep stopping and starting.

  • Hey, what's going on here?

  • I did something in the first example.

  • In this Siri's very similar where I took a mover object and created a vector that pointed from that mover object to the mouse itself and set that vector as the acceleration of the object.

  • So this was like attraction.

  • But I wasn't thinking about mass and I wasn't thinking about distance.

  • Let me try to diagram what it is that I want to dio.

  • I wanna have a new object that's called in a tractor.

  • So I'm not actually going to at this moment in Yeah, I just I realized something.

  • Um, let me diagram what I want to do in this video.

  • So I'm gonna simplify things and have this concept of an attractor object.

  • So the attractor object isn't a really body in the universe.

  • It's a fixed entity that doesn't that that attracts things to it.

  • But it cannot move, and it cannot experience forces itself.

  • Then I'm going to have the mover object with some given velocity and the mover object.

  • The attractor is basically the mouse from the previously, but the mover object is going to experience a force, a gravitational force that pulls it to the attractor.

  • And that force, which is a vector, is going to be equal to the massive one object times the mass of the other object divided by the distance squared.

  • And I put this in the wrong order, but also times G, which is the universal gravitational constant.

  • Now there's a very rial number that is this value in the universe as we know it.

  • But for us, in our fake p five or I don't want a fake pretend, but for us in our in our pretend p five canvas over.

  • That's where I understand what I'm doing now.

  • But for us in our pretend p five canvas, if I draw like a box around this G is just a way for us to kind of tune the world to have stronger gravitational attraction or weaker attraction forces.

  • And in a way, I could think of this G as a property of the attractor itself may be different.

  • Attractors have different constants, although to some extent that is taken care of by the mess.

  • But I have everything that I want.

  • I can make up stop stopping and starting Shipman.

  • So I need everything that's in this formula.

  • I need to figure out where is it?

  • Here.

  • So the massive one object well would be the mass of this mover object.

  • The mass of the other object would be the math of the Attractor.

  • So to some extent, the mass and G I could conflate these into one constant, but I'll keep them separate.

  • For now, distance is the distance between the centers of both objects.

  • So remember when I'm calculating a force I need two things.

  • I need direction and I need magnitude.

  • So this is really all of these numbers are talking about the magnitude.

  • How strong is that force?

  • How long is this arrow that I'm drawing here?

  • The direction is just ah, vector that points from the object being attracted to the attractor and so that I can get if you remember up that there's a bunch of times now with subtraction.

  • So the sub function for subtraction.

  • I could take the position of the attractor minus the position of the mover.

  • And that gives me a vector that points this way, said its magnitude to the results of this formula.

  • And voila, I have gravitational attraction.

  • Okay, so coming back to this example, I am going to now get rid of this acceleration calculation.

  • And when I run the sketch, I should just see this mover not moving at all.

  • I'm and in the main tap and in the main job script file where I have set up a draw.

  • I want to add an attractor so I'll create an attractor that also gets an X Y position and mass.

  • I'll say a tractor tracks mover and a tractor dot show.

  • Now, I'm just confused you for a second there because you might be thinking Wait, did I miss something?

  • Did you write in a tractor class?

  • And is this just gonna work right now?

  • Definitely not like when I run.

  • This is like, I have no idea what that is.

  • So this is the way that I work.

  • Sometimes it's a little bit of flawed making this tutorial videos.

  • This is probably example that I've written many, many times, So I had it just sort of right in my mind at the ready.

  • But sometimes it can be helpful to sort of sketch out what did how it is.

  • You imagine writing the code to operate an object before writing the class because now I have the instructions for what it is I need to write.

  • I need to make a class called a tractor.

  • The constructor takes three arguments.

  • It needs to have a show function, and it also needs to have an attract function that receives a mover object.

  • So all of these things are now at things that I can write into the attractor class.

  • I've already created another job script, file, a tractor dot Js which is empty.

  • So I'll put class a tractor in there then, right?

  • The constructor which, if you remember, required three arguments and x y and a mess.

  • The ex wile used for position the M l used for mass.

  • Let me write a show function just to draw it as a circle.

  • I'm now realizing I should calculate a radius based on mass the same way that I did in the previous examples with the mover.

  • So I'm just gonna grab this code which takes the mass, takes the square root, multiplies by 10.

  • I'll use the same convention and then So let's leave out the attract function for a moment.

  • Comment that out.

  • Move the mover to like, a little higher up in the campus.

  • Run it!

  • And what do I have?

  • No tractor is not defined.

  • Oh, I could never seem to remember to add the script tag when I have a new job script file and here we go.

  • All right, Now I see the attractor and the mover.

  • So the net I I would have been shot.

  • Now I see the attractor sub looking at the check.

  • Uh, now I'm seeing both the mover object and the attractor object.

  • Next step is just to actually write a function in the attractor object that resplendent.

  • Did you hear that loud noise?

  • You have a vector on the left side of feedback was bad when you were at the white hold on time out for a second.

  • The feedback was bad when you were at the white board.

  • Might be from the mic cable moving.

  • So what might cable moving?

  • You mean just like this?

  • Um And then you have a vector on the left side in a scaler on the right side.

  • Oh, yes, Yes.

  • Okay.

  • People are telling me that the noise is annoying.

  • I really saw I don't think it's an O.

  • B s problem because I think it's also in the audio track of the Have another system that records a backup of everything.

  • Zipper gets close to the mic.

  • I mean, that doesn't really make sense, right?

  • I mean, that's gonna make have noise.

  • But, I mean, I've done streams without zippers before.

  • Oh, you don't see me right now.

  • Bum Bob.

  • What do I do about this?

  • I think it's a It's mostly when my hand is near the Mike, My ring.

  • This hand.

  • Uh, I'm just I'm taking a pause for a second toe.

  • Figure out if, um, consort this out at all.

  • I'm trying to think Charger What charger, though, Okay, It's interference.

  • It's, um okay, well, yeah, it's fine.

  • You know, uh, I guess just let me know if it was particularly bad gain being too high.

  • You have that down.

  • I don't think it's feedback, though, but one thing I can dio is just turn off.

  • I do.

  • Let me just let me just check one thing for a second, okay?

  • It was really bad just now, huh?

  • People are telling my phone, but it's my phone so far away.

  • Um, I just wonder if I turned the audio monitoring off What's weird?

  • It's interesting, cause I'm not hearing it the way I think.

  • I just heard it.

  • Yeah, I hear it.

  • Oh, yeah, I hear it.

  • Okay.

  • Playing with the receiver.

  • Oh, yeah.

  • Okay.

  • That is really weird.

  • I was able to get it to move.

  • Such as a coincidence.

  • Yes.

  • You were watching a person move around trying to figure out if there's a way to trigger the audio interference.

  • All right, I have an idea.

  • I have, um I have another lab.

  • Mike.

  • Let me just try the other laugh, Mike, which I should in a 1,000,000 years ago.

  • So I'm muting myself for a minute.

  • Test.

  • 123 I think this Mike is working and doesn't look like it's crazy left.

  • Um, So the question is is there interference is better?

  • Worse The same test 12 huh?

  • I don't hear it too loud.

  • Okay, well, that's easy to fix.

  • Okay, that should have turned it down a tiny bit, and hopefully the interference will be gone.

  • We'll find out.

  • Uh huh.

  • Okay, so, um, if if you hear any audio issues, let me know, But I'm gonna assume that hopefully fixed it.

  • Well, it's 10.

  • 40 already.

  • I'm gonna be taking a break shortly.

  • Great.

  • I actually have 1/3 idea.

Good morning.

字幕與單字

單字即點即查 點擊單字可以查詢單字解釋

B1 中級

代碼的性質續。吸引,進入第三章! (Nature of Code Continued: Attraction and onto Chapter 3!)

  • 0 0
    林宜悉 發佈於 2021 年 01 月 14 日
影片單字