Lecture 1: Overview (Discrete Differential Geometry)

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
[Music] welcome to discrete differential geometry in this first lecture we're going to give some motivation for the topics we'll study in this course and we're also going to look at one detailed example that illustrates a sort of game that will play to translate between geometry in the continuous mathematical setting and the discrete computational setting so this example is going to move a bit fast if you feel lost today don't worry because we're going to slow down and start from the very beginning in our next lecture so with that in mind why might we want to study geometry well perhaps one big reason is that geometry is becoming a bigger and bigger part of the world we live in so if we look back through history we got really good at recording images and sound and video and three-dimensional geometry is really the next natural step and we're now at a moment in history where devices for both acquiring and manufacturing 3d geometry have suddenly become very broadly available so here for instance we see a 3d depth scanner in this case that comes from a cheap video game console on the bottom right we see a 3d model a digital model being printed out on a 3d printer this video has been accelerated in time and we also have devices in between like augmented and virtual reality headsets that allow us to easily interact with three-dimensional data in new and interesting ways in order to develop all these applications in order to make use of this technology we need some pretty sophisticated algorithms for working with three-dimensional data so kind of at the core of this is geometry processing which is the natural generalization of traditional signal processing to three-dimensional data and a lot of the problems that you see in geometry processing resemble what you might see in traditional signal processing okay you might want to remove noise or up-sample or down-sample we also encounter new and different problems that really don't have a clear analogy in traditional signal processing so for instance taking a three-dimensional surface and parameterizing it over the flat plane that's very much a question not only of geometry processing but also differential geometry once you've built these basic signal processing tools on top of that you can do some more sophisticated analysis of three-dimensional signals so just like computer vision uses image processing tools to recognize faces and images or find correspondences you can ask very similar questions about three-dimensional geometry so for instance maybe i've scanned a person in in two different poses and i want to find which points or vertices on those two scans correspond right i just have a big long list of points and i want to know a certain point in the first list let's say the fingertip on one of the hands corresponds to some other point in the second list the corresponding tip of the corresponding finger right and you can think of all sorts of other kinds of shape analysis tasks whether it's clustering or partitioning a shape into meaningful pieces or detecting symmetries and so forth many of these questions have a very natural interaction with machine learning so rather than writing deterministic algorithms that make these kind of inferences how can we take a bunch of data and get the machine to learn or fit some model to this data that lets us make these same kinds of judgments or predictions and here is a place where differential geometry and discrete differential geometry play an important role because many of the network architectures that might work for traditional signals so very regularly sampled images and grids and so forth don't immediately translate to irregularly sampled irregularly triangulated surfaces or point clouds or other geometric representations so we really need to think about this data in a very different way another very important place where discrete differential geometry shows up is in physical numerical simulation right so every shape that exists in nature is well it's a piece of geometry and the way that this shape moves and changes over time is very much governed by geometric phenomena like curvature finally discrete differential geometry plays a really interesting and important role in architecture and design so for instance here is a prototype for a building based on a notion of discrete parameterized surfaces so quadrilateral networks that satisfy certain very precise geometric relationships and these are really opening the door to new ways of thinking about geometry that can not only be designed but they can also be easily manufactured or constructed finally although it's quite common to start with a continuous model and then discretize it to do some kind of computation or numerical simulation we can also use knowledge from geometry and discrete differential geometry to go the other way so you go out into nature and actually the phenomenon that you discover is inherently discrete maybe you have a lattice of carbon atoms or you have spins in some material interacting and you can take a step back and say okay even though at a microscopic level this looks discreet at a macroscopic level it looks kind of like continuous geometry so you can use this interaction between continuous and discrete to get a better understanding of what's going on okay so that's a lot of different topics what will we actually learn in this class well first and foremost what we're going to learn is how to think about shape right we want to think about shape mathematically we want to think in terms of differential geometry and also computationally in terms of geometry processing and the central idea of this course is that these two perspectives can be linked in a very very precise way we're not merely going to say that one approximates the other but we're really going to have direct analogs on both sides that are equally important another thing to say is that although we'll largely use two and three-dimensional examples to motivate our discussion in this course the reality is that shape shows up everywhere so for instance every time you have a constraint function f of x equals zero in any dimension you're effectively describing a manifold right so even if you don't set out to study geometry when you're solving some other problem you're solving an optimization problem or you're doing something else computational you often actually have manifolds and geometry sitting in the background and if you know about differential geometry if you have this tool set available you can often make much smarter decisions about how to treat those kinds of problems more broadly than the specific examples i gave today there are just tons of examples in computational biology industrial design computer vision machine learning architecture computational mechanics fashion medical imaging all sorts of things where geometric thinking geometric insight can really change your approach and we will see at least some of those as we go through the course okay so what won't we learn in this class obviously we can't learn everything there's a lot to cover there on the mathematical side there are many important viewpoints on differential geometry that we simply don't have time to cover different ways of working with surfaces different ways of describing manifolds i will at least try to point those out as we go through i'll say here's a bunch of different ways that people describe surfaces we're going to focus primarily on this one for this reason but that will at least give you some starting points if you want to explore more likewise there are tons of algorithms and data structures that we won't be able to cover right so depending on your particular goals and interests the specific algorithms that we cover in this semester may not be directly useful to you right for instance maybe you care more about point clouds and computer vision whereas we're going to focus primarily on polygons and applications in geometry processing the point here is not that you should leave this class with a specific library of algorithms that you're going to then plug into whatever you're doing but rather that by studying these concepts and these algorithms in depth you will really really learn how to think about shape on your own right so that the fundamental knowledge you gain here will easily translate to other contexts where you need to apply geometric knowledge okay so that being said just to give a sense of the kind of assignments you'll do all of your assignments will ask you to derive some geometric algorithms from first principles and so this will help connect the things you're learning in class to some concrete application and then you'll actually go ahead and implement these geometric algorithms in a code framework that will provide for you the specific assignments include just basically getting your hands dirty with discrete surfaces right so what are the data structures that you'll use what are the basic operations we'll then talk about discrete exterior calculus so a way of analyzing data on a surface that will extend and be used in all of our later assignments we'll talk about curvature evaluation how do you measure how much a curve or surface is bending at each point we'll talk about smoothing and curvature flow and fairing so how do you remove little bumps and wrinkles from surfaces like noise we'll talk about surface parameterization how do i take a three-dimensional object and map it to a two-dimensional domain where i can do certain kinds of signal processing how do i do distance computation really basic question i have two points on curve geometry how do i find the distance from one point to another and finally direction field design so tangent vector fields show up in all sorts of different uh scientific and visualization problems how do you control a tangent vector field on a surface or in how do you analyze it and break it into constituent pieces okay all of those ideas will become a bit clearer as we go through the course so before going any further we should probably define or try to define what is differential geometry there are a lot of good answers to that question i would say at its core differential geometry is a language for talking about local properties of shape for instance how fast are we traveling along a curve or how much does the surface bend at a particular point and so on and also for connecting those questions about local shape to global properties of shape so differential geometry talks a lot about local global relationships a very simple one would be to say okay i can measure how much the boundary of some planar region bends the curvature of the boundary and just by knowing that local bending information if i integrate or add up that bending over the whole boundary i can actually tell you something global namely how many holes are there in the domain okay so at a high level differential geometry could also be thought of as a way to apply tools from calculus talking about rates of change and derivatives and integrals to domains that are curved rather than flat in your vector calculus class you were studying objects in rn now you're going to study those same objects on curved surfaces curved manifolds differential geometry really is the modern language of geometry and physics and statistics and it's hard to overstate the impact that it's had on scientific and industrial development in the 20th century so if that's differential geometry what is discrete differential geometry to some people this sounds like a bit of an oxymoron if it's discrete how could i differentiate it okay well we'll we'll get to a deep understanding of that that question i would say at its core again discrete differential geometry is also a language for describing local properties of shape the difference is infinity is no longer allowed we're no longer allowed to talk about things like derivatives and taking limits and infinitesimals but rather everything we want to say must be expressed in terms of a finite number of lengths or angles these fixed quantities and what's rather amazing is that surprisingly little is lost in translation you can actually use discrete differential geometry to capture many of the same fundamental ideas about nature and the way that real shapes behave that you use traditional differential geometry for so talking about curvature and how the curvature of the whole boundary gives you the number of holes this is something that can be easily captured in a purely discrete language we don't need always to go to calculus to get at these core ideas and that's nice because this discrete language for one thing is often much easier to understand you need a lot less mathematical machinery to get to that point where you can state that theorem and it also often translates very well to computation right machines computers have finite storage they can do a finite number of operations and so in order to actually do calculations on geometry we need to express all this geometric knowledge in some discrete or finite way and for that reason discrete differential geometry is more and more becoming a modern language for geometric computing and as we saw at the beginning is having an increasing impact on science and technology in the 21st century okay so to connect these two pieces differential geometry and discrete differential geometry we kind of have this grand vision what are we what are we trying to do here we're trying to come up with sort of a rosetta stone that lets us translate traditional continuous differential geometry into a language suitable for computation that's kind of what we want to explore in this class and in the process of that exploration we're going to get a very deep understanding of the concepts that differential geometry is all about geometry itself is fundamentally not about the language we use to describe it geometry is not necessarily about derivatives it's not necessarily about finite sums of angles right it captures natural behavior out in the universe and by looking at it from these two perspectives the continuous and the discrete we get a real appreciation for what those more fundamental ideas are okay so this is getting really abstract and philosophical how do we concretely do this how do we translate ideas from continuous mathematics into discrete computation and fortunately there's actually a sort of game that you can play in discrete differential geometry a pretty straightforward procedure that you can use to at least try to cook up good discrete definitions so the way this works is i'm going to start out with some object i'm interested in let's say curvature and i just go ahead and write out all the definitions i know for that curvature in the smooth setting so in mathematics there are often many completely equivalent ways to characterize the same quantity or the same object then what i do is i try to apply each of these definitions to my discrete geometry so rather than applying it to a smooth curve or surface i apply it to a polygonal curve or polygonal surface and after working through some of the details i try to get a sense of which properties of the smooth definition are captured or faithfully represented by each resulting discrete definition and the kind of interesting thing that happens most of the time is even though these definitions i started with are completely equivalent in the smooth setting they all say exactly the same thing when i apply them to my discrete object i actually get several different possibilities right and then you can start asking okay of all these possibilities which one is best which one should i use which one should i actually apply in my algorithm something interesting that often happens is something called a no free lunch scenario you work out all these different possibilities and what you discover is none of them is perfect and beyond that it you can sometimes prove that it's impossible to get one discrete definition that captures all of the properties from the smooth setting so at that moment you really have to make a decision and ask which of these definitions which of these properties are most important for the task at hand let's say for the algorithm so we can make this more concrete by looking at a specific example so today we're going to look at a toy example of the curvature of plane curves what is curvature we've used that word a lot already today but what does it really mean well intuitively it tells us something about how much the curve bends okay and what we're going to do first is make that more precise by giving curvature a definition in the smooth setting then we'll play the game of discrete differential geometry to get several different possible definitions of curvature for a discrete curve for a polygonal curve and as advertised we'll discover that no single definition is truly the best we have to pick the definition that's best suited to the task at hand so as mentioned at the beginning today we're going to go pretty quickly through this example and don't worry about catching every detail we're going to start more slowly next lecture from the basics okay so we should pause for just a moment before we put all this work into developing discrete curvatures to ask why do we want to do this is this a valuable thing to do and the answer is yeah certainly there are all sorts of places in the world where we need to be able to talk about curvature measure curvature use curvature for instance this shows up in physical applications if i'm talking about the bending of a rod or the twisting of a rod curvature and something closely related called torsion play a really important role in image processing if i'm trying to segment interesting pieces out of an image i might look at the curvature of the boundary between two regions at a microscopic scale shape and function are intimately related so the bending and twisting of a protein might say everything about how it behaves in its environment generally curvature is used for all sorts of visualization and design and so forth okay so before talking about curvature we have to talk about curvature of what so we're going to talk about the curvature of curves in the plane and specifically we can say well in the smooth setting a parameterized curve is a map a function taking each point of an interval 0l on the real line to some point in the plane r2 right so if we assign a point to every point in that interval we get a curve in the plane and we can write that as gamma maps the interval 0l to r2 now we could add additional qualifiers here we could say that this map has to be continuous or differentiable or smooth generally we're going to assume that it is as nice as it needs to be to make the statements we want to make okay so just as a concrete example we can express a circle in the plane we usually think of this as just i don't know the set of points with unit norm well we can instead think of a circle as a parameterized curve taking the interval 0 to 2 pi to the circle via the map gamma takes s to cosine s sine s so it takes the two endpoints of that interval and puts them at the same location at 1 0. okay what about discrete curves well there are lots of different possible definitions we could use for a discrete curve basically a discrete curve would be any curve we could specify using a finite or discrete amount of information for now we'll say a discrete curve is a piecewise linear parameterized curve so more down-to-earth way to say that is well it's just a sequence of vertices gamma 0 gamma 1 gamma 2 and so on connected by straight line segments okay so we can also think of that curve as the image of a map gamma from an interval 0l into the plane it's just that over pieces of that interval this map happens to be linear or affine so a shorthand we're going to write gamma sub i means gamma applied to s i some point in that interval okay again a little example so a very simple example is a curve comprised of just two segments which we can think of as a piecewise map from an interval 0 2 on the rail line into the plane so over the first half of the interval we map s to s0 so we go along the horizontal direction on the second half of the interval we map to one s minus one we go along the vertical direction okay what else can we say about a curve well one of the most basic things we can look at are tangents to the curve informally a vector is tangent to the curve if it just barely grazes the curve okay that's not a very satisfying definition so how can we make this more precise we'd say more formally the unit tangent or maybe we just abbreviate this by always thinking of tangents as unit vectors the unit tangent of a parameterized curve is the map obtained by normalizing the first derivative of the curve right so we take the derivative of gamma with respect to s and divide by the norm of the derivative of gamma with respect to s now in order to do this we have to make one very important assumption which is that that derivative is never zero that the curve never slows to a stop and then starts back up again and that's something important to remember about parameterized curves a parameterized curve is not just describing the shape of the curve but it's also giving us some notion of speed of travel along that curve for that reason it's quite common to make an assumption about parameterized curves which is that they're arc length parameterized in other words that the derivative has unit norm at every single point so we don't have to worry about this kind of issue in that case we can just write the tangent as dds of gamma the change in position as a function of arc length here's a concrete example let's go ahead and compute the unit tangent of a circle so again we have our map gamma that goes from the interval 0 to pi to the plane how do we get the tangent well the first thing we should do is just compute the derivative of gamma with respect to s and okay hopefully you remember derivative of cosine is minus sine derivative of sine is cosine we get minus sine s cos s now we know we have to next divide by the norm of this derivative what's the norm well the norm is going to be cosine squared plus sine squared which is just one okay and so what that means is we already have an arc length parameterized curve which means the tangent t is just the derivative of gamma minus sine s cos s and when we plot these as vectors on the circle we get exactly what we expect we get these vectors that are barely grazing the curve what else can we say about this curve well we can look at its normal so informally a vector is normal to a curve if it sort of sticks straight out of the curve more formally we can say the unit normal or again we'll just generally assume we're always talking about the unit normal can be expressed as a quarter rotation j of the unit tangent in the counterclockwise direction and so here j just means we take the tangent vector t and we turn it 90 degrees counterclockwise okay to make this a bit more explicit we could say if we're in 2d coordinates x y we can write this quarter turn by just exchanging x and y and negating y why does this work by the way why is this a 90 degree rotation well one easy way to see this is if i take the dot product between these two vectors x times minus y plus y times x i get zero these two vectors are orthogonal okay concrete example let's compute the unit normal of our favorite curve the circle so if gamma again is our map from s to cosine s sine s on the interval 0 to 2 pi then we had the tangent minus sine s coses if we rotate this by 90 degrees what do we get well we get the normal is j t which equals minus cos s minus sine s and if we plot this on the circle what we see is a bunch of arrows that are all pointing in toward the center it's a little hard to see this because these are all unit vectors and they all have arrowheads meeting at the origin right but we get normals that are pointing straight out of the curve kind of like we said now one important thing to note here is that we could have adopted the opposite convention we could have said that we obtained the normal from the tangent by doing a quarter turn in the clockwise direction that would have also given us vectors that stick straight out of the curve neither one of these is right or wrong this is just a convention that we pick but what's important is that here and throughout the rest of our study of geometry that we just remember which conventions we picked and try to stay consistent with those conventions so eventually we'll have to pick conventions for the orientations of curves or edges or the sign of the laplacian and the way to keep yourself sane is to just pick some convention and stick with it for the rest of your life or at very least through the the rest of the semester okay okay so finally we've looked at the tangent we've looked at the normal we can get to the curvature of a plane curve and we've already said that informally curvature describes how much a curve bends so if we have this curvature here then the left part of the curve doesn't bend very much it has less curvature the right part of the curve bends quite a lot it has more curvature how can we be a little more precise about this well we could say that the curvature of an arc length parameterized plane curve can be expressed as the rate of change in the tangent so if we draw the tangent vector as we walk a little bit along the curve you notice in the flatter parts the tangent really isn't rotating very much whereas in the highly curved parts the tangent is rotating quite a bit right so we can write this more precisely by saying kappa of s is going to be the inner product of the normal at s with the derivative of the tangent the change in the tangent tells us how much the curve is bending by the way here and throughout these angle brackets are just denoting the usual dot product so the dot product of a b with x y is ax plus b y another way we could write this same expression is to say well for an arc length parameterized curve t the tangent is the same as d gamma d s so we can write this as the inner product between the normal n and the second derivative of gamma so that's our first kind of basic little idea about curvature is curvature is sort of a second derivative of the geometry another thing you might wonder here is why are we taking the inner product with the normal why don't we just take the norm of the second derivative of gamma can you think of a reason why we might prefer taking an inner product with a normal to just taking the norm well the reason is that when we take the norm of a quantity we lose some information in particular we lose the sign so what does the sign tell us here if i see that the second derivative of gamma is positive versus negative what is this telling me about the behavior of the curve well basically it's telling me is the curve bending to the right or is it bending to the left right i can have curvatures of equal magnitude in different directions and so by taking the inner product with the normal rather than taking the norm i retain that information about the curve okay so when we think about curvature it's very important to think of curvature as a signed quantity all right so now that we have a pretty precise definition of curvature we can start thinking about our main question how can we translate curvature from the smooth setting into the discrete setting we know how to define curvature for this smooth curve how do we define curvature for a polygonal curve that might actually show up in real data that we're working with okay well we come back to this idea that hey curvature is a second derivative so if we want to know the curvature of our discrete curve let's just write out the expression for curvature here i've written it in a slightly different way rather than n i've written j dds of gamma i'm taking the tangent and rotating it by 90 degrees then taking the inner product with the second derivative okay can we apply this definition to a discrete curve can we simply take derivatives first and second derivatives of our curve gamma plug it into this expression and get a useful meaningful value that tells us about how this curve is bending what do you think well if you think about this for just a moment you realize there's a pretty serious problem here which is that if we take the second derivative of different pieces of this curve we don't get a lot of useful information if we're on the middle of some segment then we have just a straight curve and the curvature is zero at vertices of the curve it's not really clear what the second derivative means classically this second derivative isn't well defined so we sort of get zero on some parts of the curve and infinity if you like at the vertices of the curve and that doesn't really give us a nice description of how the curve is bending so we're going to have to think about this in a different way how else can we characterize curvature in the smooth setting so that it translates nicely to the discrete setting okay when we do this when we come up with other definitions we have to ask ourselves well how do we know that we actually came up with a good definition we're pretty sure that the last definition was bad because well it was zero or infinity it didn't really provide us the the information that we wanted to know but there are many different criteria for what could make a definition good as well so one thing we might look for is that this definition satisfies at least some of the same key properties and theorems that we have about smooth curvature for instance we mentioned already that if we add up or we integrate the curvature over the boundary of our shape that'll actually tell us how many holes the shape has so it would be nice if our discrete notion of curvature gives us the same information another very basic thing we might ask for is that we get convergence that as we refine our discrete curve more and more and more and make it look more and more like a smooth curve we would hope that our discrete curvature would approach the curvature of the smooth curve right otherwise something really strange is going on and then there are also kind of practical things we might think about for instance is it efficient to compute this quantity can we just do it by looking at a few neighboring vertices on our curve do we have to do something much more complicated that becomes really important especially if we want to solve equations involving curvature and so on okay so let's go ahead and play the game of discrete differential geometry for curvature of a plane curve in the smooth setting there are several other equivalent definitions of curvature so rather than thinking of it as the inner product of the normal with the second derivative we can look at the turning angle the length variation the steiner formula the oscillating circle okay all four concepts that we'll look at in a moment right but all these four viewpoints in the smooth setting will produce exactly the same curvature value however because they give us different starting points it might be possible that we can apply some of these definitions to our discrete curve even though we can't take second derivatives so even though we can't take second derivatives we might easily be able to talk about things like length and turning angle and so forth okay and in fact it'll turn out that all four of these viewpoints can be applied to a discrete curve and will produce different curvatures that have different consequences so let's take a look at how that happens okay so the first idea is to say well our initial definition of curvature was the rate of change of the tangent in the normal direction and we thought of the tangent as a vector associated with each point however since we're working with unit vectors we can also think of the angle that the tangent makes with the horizontal so rather than saying curvature is the inner product of the normal with the derivative of the curve right what we can do is say all right at each point on the curve gamma of s we consider the horizontal direction i'll call that phi is equal to zero and the tangent will make some angle phi of s with that horizontal and so now we can instead write the curvature as kappa of s equals dds of phi of s how quickly is this angle changing as we walk along the curve that rate of change turns out to be the same as the curvature we defined before it's just a different way of writing it but you notice that there's no second derivative written down here at least not superficially so we might be in better shape when it comes to going to the discrete setting okay so it's true that we still can't evaluate the curvature at vertices of a discrete curve right we have this angle that suddenly jumps at a vertex so we don't immediately get an answer but let's consider what happens over a short segment of a smooth curve so if we go from a point gamma of a to a point gamma of b the tangent rotates by some finite amount right and so we can say the integral of curvature cap of sds is equal to okay let's just plug in our definition for kappa we said that's the derivative of phi with respect to s what is the integral of the derivative well that's the fundamental theorem of calculus that just says it's the difference phi b minus va so what i know is that the total curvature along that segment is just a difference of angles and this is good news because a difference of angles is something i can easily evaluate for a discrete curve right so if phi b is the angle of the second segment and phi a is the angle of the first segment with respect to the horizontal then i know that whatever the curvature looks like in between it integrates to phi b minus va in fact one way to think about this is to say well you know this curve this discrete curve where did it come from maybe it was sampled from some smooth curve to begin with maybe there was all sorts of interesting stuff happening between point a and point b and even if i've lost all the information about exactly what happened between point a and point b this little argument tells me i can still know the total curvature between point a and point b so i really know exactly the total curvature along this little segment whatever it might have looked like okay so this is a really nice definition this this definition really works well for our discrete curve so we're going to say our first definition of discrete curvature is just this turning angle okay so if we have vertices gamma i minus one gamma i gamma i plus one and angles phi i minus one i v i i plus one then we're going to define theta as the angle between the segments from gamma i minus 1 to gamma i and the segment from gamma i to gamma i plus 1. okay and our first definition of discrete curvature at vertex i is simply this angle the turning angle by the way the reason that we're introducing two different symbols here theta and kappa is we're going to use theta again later on in a different way right so kappa is really saying what we think of as curvature and theta is saying just the name of some particular angle on our curve okay so we already start to see a pretty common theme in discrete differential geometry which is that many quantities that we want to think about in the discrete setting are much more naturally thought of as little integrals of pieces of the geometry rather than the pointwise values right it's a lot easier to take integrals than to take derivatives when we have something that's not very differentiable okay so here in particular we're saying the discrete curvature is giving us the total change in angle rather than the derivative of angle and as it turns out this information is still totally useful in doing the kinds of things we want to do with curvature and curves the reason is we're still getting pretty local information we're taking an integral over just some tiny piece of the curve right so we're really getting a description everywhere along the curve of how much it's bending all right so that's nice that gives a pretty good definition of discrete curvature are there other ways to get a definition of discrete curvature well here's a useful fact about curvature from the smooth setting roughly speaking the fastest way to decrease the length of a curve is to move it in the normal direction with speed proportional to curvature why might this be true well here's a little bit of intuition in flat regions of a curve if i move in the normal direction that doesn't really change the curve length right on the other hand if i have a highly curved region let's say i have a small circle and i move out in the normal direction actually the length changes significantly i get a large change in length per unit length of the original curve and so in general if i want to increase or decrease the length of the curve as quickly as possible again i should move in the normal direction with speed proportional to plus or minus curvature okay so a little more formally let's consider an arbitrary change to the curve gamma we have some fixed curve gamma and we're going to displace it by a function eta so at each point we're just going to move in some direction given by eta and also eta is going to be zero at the endpoints of the curve right so we start out with this curve gamma and we do some displacement by some amount epsilon in the direction ada okay then it turns out that the derivative of the curve length with respect to epsilon meaning how much we're displacing the curve is equal to minus the integral over the curve of the inner product of eta with the curvature times the normal right of the variation times the curvature times the normal so if we stare at this equation and ask which eta should we plug in to make the change in length as big as possible well we should line that change up with kappa n with the curvature times the normal okay so what does that mean for our discrete curves in fact all of this becomes a lot easier to talk about in the discrete setting how do we figure out the motion that will increase the length of the curve as quickly as possible well we can just take the gradient of the length of our curve with respect to the vertex positions okay so to kind of go through this step by step let's actually just consider a single line segment first between points a and b right and say the length l is just the distance between b and a what motion of the point b should i make to most quickly increase the length of that segment just intuitively where should i move b so that the segment gets longer as quickly as possible okay hopefully it's not too hard to see that i should just pull b away from a i should go parallel to the segment from a to b the vector from a to b and i can also ask how much does the length change for a unit motion along that direction well if i move by a unit distance then i change the length by a unit amount and so from that i can deduce that the gradient of length with respect to a motion of b is just the normalized vector b minus a over l a vector that's parallel to the segment and has unit magnitude okay so now if i want to know the motion that most quickly increases the total length of our discrete curve we can just sum up the contributions of each segment if i have this discrete curve and i want to know how should i move gamma to increase the length of this curve as quickly as possible well okay i can look at its neighbors i know that i really only have to consider gamma and its two neighbors because when i move gamma i right i'm not changing the lengths of any segments other than those two segments touching gamma i and i already know what the gradient is for each of those segments right they're these unit vectors parallel to the edges and so i know that the gradient of the sum of these two lengths is just the sum of the gradients of these two lengths okay so using some simple trigonometry we can also express the length of the gradient in terms of the exterior angle theta this this angle that we introduced before and the angle bisector n just the normalized sum of those two vectors we work through all this and we say okay then the gradient of the total length of the curve is just 2 sine theta i over 2 times n i no reason you should know that just a little calculation okay so let's take a step back how does all of this discussion help us define discrete curvature well remember again that in the smooth setting the gradient of length is equal to the curvature times the normal hence our expression for the discrete length variation provides a definition for the discrete curvature times the discrete normal see all i did there was i took the smooth definition and i put the word discrete in front of each of the quantities that i need and then i ask myself do i know how to define each of these quantities in the discrete setting well discrete length i understand it's just the the sum of the edge lengths discrete normal i can use that angle bisector and then i kind of solve for the discrete curvature i know the length variation and so i know that the discrete curvature must look like this right that 2 sine theta over 2 n is giving me the length variation so therefore kappa must be 2 sine theta i over 2. okay not super important to follow all the details here other than to realize we took two different starting points in the smooth setting that are just as good they're equivalent to each other in the smooth setting one was the turning angle one was the length variation we worked through a bunch of details and then discovered that these two perspectives led to two inequivalent definitions of curvature in the discrete setting one is to say that the curvature at a vertex is just equal to this exterior angle or turning angle theta i and the other says that the curvature is twice the sine of half that angle now how can it be that both of these expressions describe the curvature of the curve i mean they both started from perfectly reasonable starting starting points well one thing we can observe is that at least for very small angles we get basically the same thing as theta goes to 0 well sine of epsilon is approximately epsilon right so 2 sine theta over 2 just becomes theta so at least if we have a nice refinement of the curve both of these things are giving us the same information they just disagree on what should exactly be the discrete curvature for a coarse curve right so then another natural question is well is one of these definitions better why would we want curvature a versus curvature b and are there other things we could do well to figure this out let's keep going okay so we have a third option something called steiner's formula steiner's formula is closely related to our last approach it says that if we move the curve at a constant speed in the normal direction then the change in length is proportional to curvature right so if i move like that then the local change in length has to do with the curvature you see that in a in the kind of the elbow of the curve where there was a lot of curvature the curve got a little bit squashed where the curve was kind of flat it just translated and so forth so we could say the length of gamma plus epsilon n is equal to the length of gamma minus epsilon times the integral over zero to l of the curvature and this statement will hold not only for the whole curve but for any small interval on the curve so the intuition for this formula is the same as before for a constant distance normal offset length is going to change in curved regions but not in flat regions okay so we can again try to use this perspective of steiner's formula to define discrete curvature so we can take our discrete curve and say all right let's offset this discrete curve in the normal direction by a constant amount see how much its length changes and that should tell us essentially what the curvature is how do we do this well the first problem is we again have a problem at vertices what are the normals at vertices how do we do a normal offset of our curve if we don't know what the normals well we can at very least offset individual edges along the normals we can break apart the curve and offset the individual segments okay but this is not yet really interesting because the new length in this case is always going to be exactly the same as the old length we didn't learn anything about how the curve is bending so what we could do is we could connect up the curve in some way right make some kind of connection between consecutive segments now we have a new curve we can measure its length and use that length to understand something about curvature question how how should we connect these segments together to get a continuous curve well there's not just one way as usual there are actually several natural ways to connect these offset segments one way is to connect along a circular arc of radius epsilon another is to connect along a straight line and another way is we could extend the two segments until they meet at a point okay so that gives us three different new curves if we now compute the total length of these curves we get after some additional work that the length when we use the circular connections is equal to the original length minus epsilon times the sum of exterior angles theta at the vertices if we connect by straight lines we get that the new length is equal to the old length minus epsilon times two sine theta over two haha that sounds familiar and if we connect by extending the segments we get that the new length is the old length minus epsilon times two tan theta over two okay so how does that tell us about curvature well again steiner's formula says the change in length is proportional to curvature hence we get yet another definition for curvature by comparing the original and offset lengths in fact we get three definitions of discrete curvature because we have three ways of connecting and two of these are going to be things we've seen before if we connect by circular arcs then we get the turning angle again if we connect by straight lines we get the discrete curvature that we saw by doing length variations and if we connect by extending the segments until they meet we get a new discrete curvature involving the tangent of half of the angle interesting okay so another really important thing that we notice here is we arrived at the same curvatures or at least two of the same curvatures in multiple different ways so when you first start with this exercise everything feels kind of arbitrary okay i plug in some perspective i get a formula does this really mean anything but what you'll find is that over and over again in discrete differential geometry as you try different perspectives and different ways of getting your discrete definition sometimes the same definition or definitions show up over and over and over again and that's usually a pretty good sign that you're on to something real something canonical okay but let's keep going here and consider one last definition based on the osculating circle so the osculating circle for a smooth curve is kind of saying okay i'm going to look at a point p and i'm going to consider all circles that pass through that point p i want the one that gives the best approximation of my curve one way to think about this is to say consider two points one to the left of p and one to the right of p these three points together define a unique circle and as those two neighbors approach p kind of at the same rate i converge to this circle this oscillating circle the curvature of the curve it turns out is then the reciprocal of the radius one over r now in the smooth setting this curvature is exactly the same as the curvature we defined using the second derivative it's the same as the curvature coming from length variation it's the same as the curvature coming from steiner's formula and so on what happens in the discrete setting okay well a natural idea is to just take three consecutive vertices on our discrete curve and draw a circle through them and then say well why not let the discrete curvature be the reciprocal of the radius again with a little trigonometry we could also write this as 2 sine theta meaning the same exterior angle as before divided by w the vector between the point on the left and the point on the right okay so again we get some expression involving theta okay so after all this work after looking at these different perspectives we end up with four inequivalent definitions for discrete curvature it's a little weird because the four definitions we started out in the smooth setting were all perfectly equivalent they were exactly the same right but we don't have one true definition for the discrete curvature and so we have to ask ourselves well which one should we use right i'm still confused i'm still lost this is fascinating but at the end of the day how do i evaluate the curvature of my polyline right and the answer always is pick the right tool for the job for a given application which properties are most important to you and maybe how much computation are you willing to do all these kinds of things once you have an understanding of that you can pick which of the definitions you'd like to use so for instance if you were doing physical simulation if i'm working on a fusion reactor i might care about energy if i'm designing a spaceship i might care about vorticity and so i'm going to pick the discretization that preserves well either energy or vorticity depending on what i want to do how does this work out in a geometric setting what kind of trade-offs do we have in geometric problems well there are a lot of different trade-offs and we'll see a lot of this as we go on through the course for the moment let's look at just one particular problem or one particular thing that we might want to simulate which is this idea of curvature flow so curvature flow just takes a initial curve maybe a noisy curve and it pushes the curvature around to smooth out the curve to reduce the curvature at each point and this shows up all over the place for instance we already talked about segmenting an image you might also be trying to find patterns of cuts on surfaces for cutting them up and fabricating them let's say you're making a volleyball out of flat pieces of material and you want some nice straight curves that are easy to cut you might for surface want to map that surface to a canonical domain like the sphere so that you can easily map between different surfaces this is something you can do with curvature flow or you might just want to remove noise from your data you have a noisy 3d scan and you want to push the surface around to smooth out little bumps and wrinkles so let's just look at a very simple version of curvature flow in the plane the most classic curvature flow is something called curve shortening flow where a closed curve moves in the normal direction with speed proportional to curvature so we can write curve shortening flow like this the change over time of the curve gamma which is now a function both of arc length s and time t is equal to the curvature at that point at that time times the normal at that point at that time okay and what does this look like well if we start with this curve on the outside which has some kind of sharp corners we run curvature flow then over time it's going to tend toward this tiny little circle in the middle it's going to shrink to this nice round point so this flow you can prove it has some nice properties one is that total curvature remains constant throughout the flow one is that the center of mass does not drift from the origin and the other is that up to a rescaling of the curve the flow is stationary for circles so once you reach a circle it'll just shrink uniformly okay can we get a discrete curvature flow that has these same three properties well let's see so we can approximate curvature flow on a discrete curve by repeatedly moving each vertex a little bit in the direction of the discrete curvature normal right so i could say at each vertex i the new position gamma t plus 1 is equal to the old position gamma t plus some small time step tau times some discrete curvature kappa times the discrete normal n okay and we get something that looks very similar right we start with this curve on the outside with interesting curvature it tends towards something more circular and small however no choice of discrete curvature is going to simultaneously capture all three properties of our smooth flow and we can just check this out empirically we run a numerical experiment on this curve and we measure these different quantities so we can look for instance at the total curvature over time according to these three different definitions the turning angle kind of by construction always has exactly two pi of curvature the the tangent turns around by one whole turn as we walk around the curve with these other definitions using sine and so forth this was lost this very very basic property of curves was somehow lost by these definitions and it looks like the total curvature is changing which is crazy a closed curve always has curvature 2pi however if we measure the drift of the curve from the center okay now definition b does better if we consider the length variation well drifting away from the center doesn't help you change the length so you should just stay put and if we consider the condition of roundness okay does a circular curve stay fixed circular curve meaning all vertices on a circle well actually only definition d keeps this fixed and so we see that we have these three properties that we wanted to satisfy we have these three curvatures that we could use and in this case each one of them only gets one of the three properties and in fact you can show under certain reasonable conditions that it's impossible to come up with a definition of discrete curvature that satisfies all three of these properties simultaneously you have a so-called no-free lunch theorem so this idea of no free lunch is quite common right beyond even our little toy problem there are many examples in discrete differential geometry where this shows up for instance in physics you might want to come up with numerical methods that preserve energy and momentum and something called the symplectic form well sorry it turns out you can't do all three at the same time when you're doing geometry we'll see that we get no free lunch theorem for something called a laplace operator which will be super important for our algorithms and applications and so on so this is all fascinating right mathematically this is kind of interesting but i want to take a big step back here and say you know why do we play this game at a more practical level playing this game basically just leads us to new approaches to geometric algorithms new ways of thinking about how to solve the problem how to measure a quantity how to solve an equation right because we have this rich set of different smooth perspectives it gives us a lot of different possibilities of how we might cook up an algorithm and those algorithms can look very very different depending on which road we start traveling down okay and usually these are also conclusions we can't get to by just thinking about discrete geometry it's really mixing the smooth and discrete perspectives that lets us consider all these rich and interesting possibilities so we're going to see a lot more of this as our course continues just to give a brief course roadmap to give a sense of how the next set of lectures is going to go we're going to start out really with the basics and talk about combinatorial surfaces or put more simply we're going to talk about meshes how do we describe the connectivity of a piece of geometry and what are data structures that we can use to encode that connectivity then over the next series of lectures we're going to build up our basic language for talking about differential geometry and that's the language of differential forms and exterior calculus so this language has a few components one is exterior algebra which you can think of as kind of a little extension of the linear algebra that you've already studied rather than just talking about points and lines and planes we have in some sense higher degree objects okay then we're going to talk about differential forms we're going to talk about how the objects from exterior algebra can be used to talk about measurement and how we can talk about derivatives and integrals of those kinds of measurements and why do we do all this well it's all leading up to something called discrete exterior calculus which is a machinery for talking about measurement and quantity on meshes that's going to let us make it really easy to translate ideas from smooth geometry into mesh algorithms okay using that language we're going to be able to talk in a very nice way about the geometry of curves in both the smooth and discrete setting and also surfaces in both the smooth and discrete setting so we'll spend some time getting a handle on those important objects and from there we're off to the races we can start talking about all sorts of interesting and useful properties of curves and surfaces and various algorithms that we can run we'll talk about ways of describing curvature we'll talk about the laplace beltrami operator which is fundamental to all sorts of equations in geometry and physics we'll talk about geodesics so basically about how to go from one point to another in the least amount of time we're going to talk about conformal geometry homology and homology maybe some additional topics don't worry at all if these words sound intimidating right now we're going to step through each of these one by one and build up the basic knowledge that you you need to understand them starting really with nothing more than introductory linear algebra and vector calculus okay we're also going to use lots of applications and hands-on exercises to come to terms with these objects and i think that by visualizing these things and playing around with them you'll really get a deep understanding of what all of this means okay so that's it for today see you next time
Info
Channel: Keenan Crane
Views: 59,244
Rating: undefined out of 5
Keywords:
Id: 8JCR6z3GLVI
Channel Id: undefined
Length: 67min 45sec (4065 seconds)
Published: Thu Feb 04 2021
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.