Open in TheBrain

Imaginary Numbers Are Real [Part 10: Complex Functions]

Welch Labs

308K subscribers

SUBSCRIBED

Supporting Code: https://github.com/stephencwelch/Imag...More information and resources: http://www.welchlabs.comImaginary numbers are not some wild invention, they are the deep and natural result of extending our number system. Imaginary numbers are all about the discovery of numbers existing not in one dimension along the number line, but in full two dimensional space. Accepting this not only gives us more rich and complete mathematics, but also unlocks a ridiculous amount of very real, very tangible problems in science and engineering. Part 1: Introduction Part 2: A Little History Part 3: Cardan's Problem Part 4: Bombelli's Solution Part 5: Numbers are Two Dimensional Part 6: The Complex Plane Part 7: Complex Multiplication Part 8: Math Wizardry Part 9: Closure Part 10: Complex Functions Part 11: Wandering in Four Dimensions Part 12: Riemann's Solution Part 13: Riemann Surfaces Want to learn more or teach this series? Check out the Imaginary Numbers are Real Workbook: http://www.welchlabs.com/resources.

Caption author (Turkish)

E

Caption authors (Portuguese (Brazil))

Vini e Digo CHANNELCalvin Suzuki

Caption author (Chinese (Taiwan))

阿諾桑

Caption author (Russian)

Denis Khakimov

Caption authors (Spanish (Latin America))

00:08

So what is this?

00:10

We solve this shape back in part one and proceeded to not talk about it for like ten episodes

00:16

And at this point i really wouldn't blame you if you thought this was some science-fiction designed to get you excited about doing boring algebra problems,

00:23

But before we chalk this up to unnecessary special effects, let's remember where the shape came from.

00:31

We began our conversation in part one with an equation that appeared to have no solution: x2+1=0.

00:37

And after all the work we've done so far you can probably see how to find the answer algebraically:

00:43

subtract 1 from both sides of the equation and take the square root resulting in x equals plus or minus i, done.

00:50

So that's cool, but to really make sense of out shape from part one we need to dig a little deeper and talk about functions of complex variables.

00:58

The kinds of functions most of us are used to the functions of real numbers have inputs and outputs that can be visualized using a single dimension.

01:06

This means all our x values that are in a single number line and so do our y values

01:11

it seems pretty reasonable then that if we want to figure out how x and y are related

01:15

we should put our x number line facing one way on a piece of paper and put our y number line on the same piece of paper just facing the other way.

01:23

This form a two-dimensional grid known as the Cartesian Coordinate System

01:28

apparently invented by Rene Descarte in the 16th century after watching flies crawl around.

01:33

The Cartesian Coordinate System is a super powerful tool for understanding the relationship between two variables.

01:40

The Cartesian Coordinate System is powerful because it allows us to take abstract ideas like functions and turn them into something our brains can grasp much more intuitively - shapes

01:50

By giving each point on the plots very own coordinates Descarte was able to bring together the two largest areas of mathematics at the time - algebra and geometry.

01:59

This greatly aided early efforts at classifying functions by Newton and others

02:04

and today the Cartesian Coordinate System shows up everywhere helping us do all kinds of things like spot trends in data.

02:11

So that's all fun and wonderful but the Cartesian Coordinate System does come with a disclaimer: it only works in two dimensions.

02:18

This limitation becomes a real problem when we start to think about functions of complex variables.

02:24

These functions taken complex numbers for their inputs and for the most part also output complex numbers.

02:30

This means the numbers we put in and get out of our function and no longer fit on number lines

02:35

we need two complex planes to keep track of our numbers: one for our input and one for our output.

02:42

This raises an important question if when visualizing these function but we're really interested in is the connection between the input and output.

02:49

How do we visualize what's happening on both planes simultaneously?

02:54

We could try to fit our input and output planes together somehow as we did with our number lines for real valued functions.

03:00

But we quickly run into a pretty serious issue.

03:04

As you likely know the universe we live in has three spatial dimensions, so there's no way to fit the four spatial dimensions we needed to a single structure that our brains can comprehend, we simply run out of dimensions.

03:16

Fortunately there are some very clever ways to see the relationship between two complex variables,

03:22

but before we can get to these we need to think about the mathematics of complex functions.

03:26

Even though using separate planes for our input and output is not a perfect solution,

03:30

this approach can still help get us started.

03:33

Let's try it out with our original function f(x)=x2+1.

03:37

Before we begin let's make a quick variable change to make things easier down the road

03:42

we'll change the name of our input variable from x to z and call our output variable w.

03:48

Since z and w each have a real and imaginary part,

03:51

let's go one step further and give these parts names.

03:55

We'll let z=x+iy, so x represents the real part of z and y represents the imaginary part.

04:02

We'll also let w=u+iv.

04:05

Just as we can use tables to keep track of our inputs and outputs for real valued functions we can also use tables to keep track of our inputs and outputs for complex functions.

04:14

However we now need four columns to keep track of our four variables: x, y, u and v.

04:21

We can now experiment with our function f(x)=z2+1.

04:26

If we plug in a complex number to our function for example z=1+i, we can do a little algebra and obtain our result: w=1+2i.

04:36

Planning our inputs and outputs we see that the point 1+i on our input plane was pushed or mapped by our function to 1+2i in our output plane.

04:45

Let's plug in a fet more points here and see if we can find a pattern.

04:49

If we test points along a straight line in our input space

04:53

we see that in our output space are straight line is transformed into a curved line, interesting.

04:58

As you can imagine plug in points like this can get pretty tedious.

05:02

To speed things up let's let the computer do it for us and instead of having our computer just map certain points, let's have it map all the points.

05:10

We'll take advantage of the fact that the image you're seeing is just a collection of pixels that happen to be arranged on a grid.

05:18

We'll use some code written in the programming language Python to move every single pixel in our input space to its proper location in the output space.

05:26

To make this work we'll assign each pixel in our input video a complex number that correspongs to its location on the complex plane.

05:35

We can then let our code take care of the tedious work of moving each pixel to its new location ad dictated by our function z2+1.

05:43

Our code will move points exactly as we did by hand before.

05:47

If we have a blue pixel at the 1+i location on our input graph

05:52

then this blue pixel will be moved to the 1+2i location on our output graph, because (1+x)=(1+2i).

05:59

We saw before that our function warped a straight horizontal line into a curvy one,

06:05

so it should have some interesting effects on our video.

06:08

We'll include some reference markers on top of our input and output planes to keep track of our numbers,

06:12

but we won't transform these pixels.

06:15

All right, ready?

06:17

Let's start by drawing some simple lines.

06:19

A horizontal line along the positive x-axis turns out to be somethins pretty similar in our output space.

06:25

But what about a line along the positive imaginary axis?

06:29

This line appears to have been rotated. As we add more lines we begin to see a pattern.

06:35

Our family of straight lines is turned into a family of curved lines. Cool! Right?

06:40

So we found one pattern but how is this pattern explained by our function z2+1?

06:46

And more importantly, how does this fir with everything else we've learned about complex numbers?

06:52

What else would be interesting to draw in our input space to test our mapping?

06:56

What shape would you draw to learn more about what our function is doing?

07:01

Next time more shapes.

07:03

Thanks for watching!

English

Attachments