Finding and Graphing Tangent Lines to a Curve in Python
Using Python to find the equation of the tangent line to a curve and graphing the result
Problem: Plot \(x^3+y^3=3xy\) and the equation of the tangent line at \(\left(\frac{2}{3},\frac{4}{3}\right).\)
Python Code:
from sympy import *
x,y=symbols('x y')
eqn=x**3+y**3-3*x*y
matplotlib notebook
peqn=plot_implicit(eqn,(x,-3,3),(y,-3,3))
dydx=idiff(eqn,y,x)
print('dy/dx=',dydx)
m=dydx.subs({x:2/3,y:4/3})
print('The slope of the tangent line is',m)
tanline=4/3+m*(x-2/3)
print('The equation of the tangent line is y=',tanline)
peqn.extend(plot(tanline,(x,-3,3)))
peqn.show()
Open Python Notebook File
Using Python to find the equation of the tangent line to a curve and graphing the result
Review of the limit definition of a derivative and calculating the derivative
Implicit differentiation and physics applications of derivatives
Review of the limit definition of a derivative and calculating the derivative
Review of derivatives and tangent lines to functions and vector equations
Review of the limit definition of a derivative and calculating the derivative
Review of derivatives and tangent lines to functions and vector equations
Review of the limit definition of a derivative and calculating the derivative
Derivatives and tangents to curves
Finding a tangent line to an curve defined implicitly
Finding a tangent line to an curve defined implicitly
Finding the equation of a tangent line to an implicit function
Implicit differentiation and physics applications of derivatives
Review of the limit definition of a derivative and calculating the derivative
Review of derivatives and tangent lines to functions and vector equations
Using the limit definition to find derivatives of functions and vector functions
Review of the limit definition of a derivative and calculating the derivative
Review of derivatives and tangent lines to functions and vector equations
Review of the limit definition of a derivative and calculating the derivative
Derivatives and tangents to curves
Finding when the tangent line to a function is horizontal in Python
Using Python to find the tangent line to a parametric equation and plot the two graphs
Review of the limit definition of a derivative and calculating the derivative
Graphing a line without using technology
Graphing a line without using technology
Writing a function for the value of an item depreciating linearly over time
Finding the solution to a system of linear equations by graphing
Graphing the solution set of an inequality with two variables
Graphing the solution set of an inequality with two variables
Graphing the solution set of system of linear inequalities
Finding the exact value of the instantaneous rate of change
Finding the exact value of the instantaneous rate of change
Finding the equation of the tangent line to a function using the limit definition
Explaining the definition of logarithmic scale and double-log plots
Explaining the logarithmic scale and a semilog plot
Derivatives and vectors with some physics applications
Tangent lines to parametric equations and related rates examples
Review of limits and derivatives of inverse trigonometric functions
Review of limits and derivatives of inverse trigonometric functions
Derivatives of parametric equations and tangent lines
Reviewing the chain rule and the derivatives and limits of trigonometric functions
Approximation and Newton's Method, and limits and derivatives of exponential functions
Limits at infinity and asymptotes, along with physics applications
Limits at infinity, asymptotes, and tangent lines
Differentials, linear approximations and quadratic approximations
Approximation and Newton's Method, and limits and derivatives of exponential functions
Derivatives and vectors with some physics applications
Implicit differentiation and finding tangent lines
Derivatives of exponential and logarithmic functions and the exponential model
Derivatives and vectors with some physics applications
Derivatives of exponential and logarithmic functions and the exponential model
Tangent lines to parametric equations and related rates examples
Finding the equation of a tangent line to a function containing a logarithm
Finding the points on a parametric curve where the tangent line is horizontal or vertical
Finding the tangent line to a parametric curve
Finding the tangent line to a parametric curve
Finding where a function has horizontal tangent lines
Finding where the tangent line is horizontal or vertical for a parametric equation
Finding the equation of a tangent line to a parametric curve
Using a linear approximation to approximate the value of a function
Finding the tangent line to a parametric curve
Finding when the tangent line to a parametric curve is vertical or horizontal
Derivatives and vectors with some physics applications
Tangent lines to parametric equations and related rates examples
Reviewing the chain rule and the derivatives and limits of trigonometric functions
Review of limits and derivatives of inverse trigonometric functions
Derivatives of parametric equations and tangent lines
Approximation and Newton's Method, and limits and derivatives of exponential functions
Limits at infinity and asymptotes, along with physics applications
Limits at infinity, asymptotes, and tangent lines
Differentials, linear approximations and quadratic approximations
Approximation and Newton's Method, and limits and derivatives of exponential functions
Derivatives and vectors with some physics applications
Implicit differentiation and finding tangent lines
Derivatives of exponential and logarithmic functions and the exponential model
Tangent lines to parametric equations and related rates examples
Solving a system of two linear equations in two unknowns by graphing
Graphing a piecewise function using Python
Using Python to numerically estimate a limit, graphically estimate a limit, and find the exact limit
Using Python to plot a parametrized curve and its tangent line at a point
Solving a multistep word problem in Python and graphing the resulting function
Discussing how to write the equation of a line through two given points
Review of limits and derivatives of inverse trigonometric functions
Writing the equation of a line that passes through two points
Finding the slope of a line through a pair of points
Writing the equation of a line with an undefined slope and a given point
Writing the equation of a line with a zero slope given a point
Graphing a line without using technology
Determining the change in y as x increases for a line
Determining the change in x as y decreases for a line
Determining the slope of a line given points containing a variable
Finding linear functions for the cost, revenue, and profit of a business
Finding the linear cost function for a company
Finding the linear revenue function for a company
Finding a linear demand equation
Finding a linear supply function
Answering questions about a demand and supply word problem
Finding the change in y as x increases for a given line
Writing a linear function representing the depreciation of a car
Explaining how to graph linear inequalities
Graphing two linear inequalities
Sketching the solution set and finding the corner points for a system of linear inequalities
Using a graph to find specific values of a function
Finding the piecewise-defined function for a given graph along with its domain and range
Identifying the parent function and transformations for a given graph
Identifying the parent function and transformations for a given graph
Identifying the parent function and transformations for a given graph
Identifying the parent function and transformations for a given graph
Drawing the graph of a transformed function given the original graph
Evaluating compositions of two given functions and the graph of a third function
Using the Horizontal Line Test to determine if graphs represent invertible functions
Finding limits from the graph of a piecewise function
Determining where a piecewise function is continuous from its graph
Finding the slope of a secant line to a given function
Determining where the derivative of a function does not exist from a graph
Finding and evaluating derivatives using values given in a table
Finding the derivative of a function that requires logarithmic differentiation
Using implicit differentiation to find the derivative of a function
Using implicit differentiation to find the derivative of a function
Finding the rate water is flowing into an expandable sphere given the rate a sphere is growing
Finding the rate of change of profit given the rate of increase for sales
Finding how fast a ladder moves up a wall as the bottom is being pushed
Solving a related rates word problem for the rate of change of a cell's radius
Solving a related rates word problem on blood flow and the Poiseuille equation
Using logarithms to transform a power function into a linear function
Writing a non-linear function for the graph containing two points on a double-log plot
Using logarithms to transform an exponential function to a linear function
Writing a non-linear function to represent the line graphed on a semilog plot
Explaining the Sandwich (or Squeeze) Theorem with a graphical example
Solving a limit at infinity using the Sandwich (or Squeeze) Theorem
Finding the equation of a line through two points
Finding the equation of a line through two points
Finding the equations of parallel and perpendicular lines
Finding the equation of a parallel line
Identifying the parent function and transformations of a function
Identifying the parent function and transformations of a function
Determining the properties of a rational function and graphing it
Determining the properties of a rational function and graphing it
Graphically verifying if two functions are inverses
Restricting the domain of a function so it is one-to-one and has an inverse
Determining algebraically the inverse of a function
Determining algebraically the inverse of a function
Determining algebraically the inverse of a function
Determining properties of an exponential function
Determining properties of an exponential function
Determining properties of an exponential function
Identifying the graph of an exponential function
Determining properties of an exponential function
Determining the graph of a logarithmic function
Determining the graph of a logarithmic function
Determining the properties of a sine function and graphing it
Determining the properties of a cosine function and graphing it
Writing the equation for a sine function to match a given graph
Writing the equation for a cosine function to match a given graph
Adding and subtracting vectors graphically
Finding the properties of a transformed tangent function and graphing it
Using a graph to evaluate a function
Determining if a function is even or odd
Cartesian equations and parametric equations of curves
Review of limits, continuity, and the Intermediate Value Theorem
Derivatives of exponential functions and the exponential model
Mean Value Theorem and using derivatives to find the shape of curves
Properties and derivatives of inverse trigonometric functions
Evaluating limits of functions
Evaluating Limits of Functions
Continuity of Functions and the Intermediate Value Theorem
Derivatives of trigonometric functions and using the Chain Rule
Derivatives of trigonometric functions and using the Chain Rule
Properties and derivatives of inverse trigonometric functions
Using derivatives to find properties of graphs
Using derivatives to find properties of graphs
Converting parametric equations into a Cartesian equation and graphing
Finding the distance between a point and a line using scalar projection
Finding a Cartesian equation for a parametric equation and graphing it
Find the Cartesian form and sketch the graph for the parametric equation of a line
Using the graph of a function to sketch a graph of its derivative
Finding the derivatives of compositions of functions from their graphs
Finding the derivative using implicit differentiation
Finding the derivative using implicit differentiation
Finding the derivative using implicit differentiation
Finding the derivative using implicit differentiation
Finding the derivative using implicit differentiation
Finding the derivative of an implicit function
Finding the derivative of an implicit function
Using logarithmic differentiation to find the derivative of a function
Using logarithmic differentiation to find the derivative of a function
Finding the point when the tangent line to a function has a particular slope
Finding the linear approximation for a function
Finding a number that satisfies the conclusion of the Mean Value Theorem on an interval
Finding a number that satisfies the conclusion of the Mean Value Theorem on an interval
Determining the properties of a function from the graph of its derivative
Using a linear approximation to estimate the value of a function
Finding the derivative of an implicit function
Finding the derivative of an implicit function
Converting parametric equations into a Cartesian equation and graphing
Converting parametric equations into a Cartesian equation and graphing
Converting parametric equations into a Cartesian equation and graphing
Converting parametric equations into a Cartesian equation and graphing
Finding the area of a region bounded by two curves
Cartesian equations and parametric equations of curves
Proving facts about the derivatives of vector functions including the product rule
Calculating slopes of tangent lines to parametric curves
Derivatives of exponential functions and the exponential model
Mean Value Theorem and using derivatives to find the shape of curves
Properties and derivatives of inverse trigonometric functions
Properties of inverse trig functions and the derivative of arctangent
Evaluating limits of functions
Evaluating Limits of Functions
Continuity of Functions and the Intermediate Value Theorem
Proving a piecewise function and a polynomial are continuous
Using the limit definition to find a derivative and proving the power rule
Proving the Product Rule and the rule for the derivative of a difference of functions
Proving facts about differentials including a product rule
Derivatives of trigonometric functions and using the Chain Rule
Derivatives of trigonometric functions and using the Chain Rule
Examples involving the tangent line to an exponential function and finding the derivative of hyperbolic cosine
Using implicit differentiation to solve a problem and to prove the power rule for rational exponents
Properties and derivatives of inverse trigonometric functions
Proving the derivative of ln(x) and the power and product rules using logarithmic differentiation
Using derivatives to find properties of graphs
Using derivatives to find properties of graphs
What the derivatives of a function tell us about the shape of its graph
Proving L'Hospital's Rule and using it to evaluate limits
Optimizing values in word problems
Proving and then applying the Fundamental Theorem of Calculus
Showing how an equation in three dimensional space represents a plane
Identifying the equation of a hyperboloid and sketching its graph
Identifying the equation of a cone in three dimensions and sketching its graph
Finding a vector equation for the tangent line to a three-dimensional vector function
Finding and sketching the domain of a function of two variables
Finding and sketching the domain of a function of two variables
Sketching the graph of a function of two variables
Sketching the graph of a function of two variables
Sketching the level curves of a function of two variables
Sketching the level curves of a function of two variables
Describing the level surfaces of a function of three variables
Evaluating a double integral over a given region
Evaluating a double integral over a given region
Evaluating a double integral and sketching the region of integration
Changing the order of integration for a double integral
Evaluating a double integral by reversing the order of integration
Setting up double integrals of Type I and II to give the volume of a solid under a surface
Evaluating a double integral over a circular region by changing to polar coordinates
Evaluating a double integral by changing to polar coordinates
Evaluating a double integral by changing to polar coordinates
Converting a double integral to a double integral in polar coordinates
Writing an iterated integral in polar coordinates that gives the volume of the solid that lies below a paraboloid
Writing an iterated integral in polar coordinates that gives the volume of the solid bounded by a cone
Writing an a triple integral over a given solid as an iterated integral
Evaluating a triple integral over a solid bounded by given surfaces
Writing an iterated integral that gives the volume of a solid
Evaluating a triple integral over a solid bounded by elliptic paraboloids
Writing a triple integral as an iterated integral in cylindrical coordinates
Converting an iterated triple integral into cylindrical and spherical coordinates
Using an iterated integral in spherical coordinates to find the volume of a solid
Evaluating a triple integral for a given solid by writing an iterated integral in spherical coordinates
Finding the slope of solutions and the critical points of a differential equation
Introducing functions of several variables and level curves
Evaluating and then finding and sketching the domain of a function of two variables
Finding and sketching the domain of a function of two variables
Sketching the level curves for a function of two variables
Sketching the level curves for a function of two variables
Sketching the level curves for a function of two variables
Explanation of partial derivatives for functions with more than one variable
Finding the partial derivatives of a function
Finding the partial derivatives of a function with two variables
Example of finding a partial derivative of a function with two variables
Explaining tangent planes for functions of two variables and how to calculate them
Determining if a list of vertices in a graph is a path, a circuits, an Euler path, an Euler circuit, or none of the above
Explaining that a graph is a collection of vertices and edges
Drawing a graph to depict a bus route
Counting the vertices and edges from a graph
Identifying the adjacent vertices in a graph
Finding two different paths between vertices in a graph
Determining if a list of vertices in a graph is a path, circuit, Euler path, Euler circuit, or none of the above
Determining if a list of vertices in a graph is a path, a circuits, an Euler path, an Euler circuit, or none of the above
Determining if a list of vertices in a graph is a path, a circuits, an Euler path, an Euler circuit, or none of the above
Determining if a list of vertices in a graph is a path, a circuits, an Euler path, an Euler circuit, or none of the above
Determining if a list of vertices in a graph is a path, a circuits, an Euler path, an Euler circuit, or none of the above
Explaining Euler's Theorem on when a graph has an Euler path or Euler circuit
Finding the valence of each vertex in a graph
Explaining Hamiltonian Circuits and paths, the Method of Trees to find them, and the number of Hamiltonian circuits for complete graphs
Determining if a graph has a Hamiltonian path, Hamiltonian Circuit, or neither
Determining if a graph has a Hamiltonian path, Hamiltonian Circuit, or neither
Determining if a graph has a Hamiltonian path, Hamiltonian Circuit, or neither
Determining if a graph has a Hamiltonian path, Hamiltonian Circuit, or neither
Using the method of trees to find all Hamiltonian circuits of a graph starting at a given vertex
Determining if a graph is a complete graph
Determining if a graph is a complete graph
Determining if a graph is a complete graph
Determining if a graph is a complete graph
Finding two spanning trees for a graph
Introducing functions of several variables and level curves
Explanation of partial derivatives for functions with more than one variable
Explaining tangent planes for functions of two variables and how to calculate them
Explaining the format and possible solutions for a system of two linear equations
Explanation of graphs for data and which are appropriate for categorical or numerical data
Explaining the notation used for statistics and parameter for mean, standard deviation, variance, proportion, and slope
Solving a system of linear equations and giving a geometric interpretation of the solution
Determining how many solutions systems of equations have without solving or graphing
Solving for a coefficient so that a linear system has exactly one solution
Solving a system of two linear equations in two unknowns by graphing
Solving a system of two linear equations in two unknowns by graphing
Solving a system of two linear equations in two unknowns by substitution
Determining if a graph represents a function and finding the domain and range
Writing the equation of a line passing through two points
Writing the equation of a line through two points in slope-intercept form
Writing the equation of a graphed line in standard form
Performing basic numerical calculations in Python
An introduction to installing and getting started with Python
Creating symbolic expression in Python and then factoring, expanding, and simplifying the expressions
Solving equations symbolically in Python and interpreting the results
Defining variables in Python and using the variables in equations
Plotting an expression in Python and finding a numerical approximation for the solution
Solving definite and indefinite integrals in Python
Using Python to find the absolute maximum and minimum of a function on a closed interval
Using Python to simplify a difference quotient and find a derivative using the limit definition
Using Python to approximate a definite integral using left endpoint Riemann sums
Using Python to find the intervals where a function is increasing or decreasing
Finding derivatives in Python and solving for the rate of change of a force
Using Python's list comprehension tool to find several higher order derivatives of a function at once
Using for loops in Python to generate a recursively defined sequence
Using Python to calculate the partial sums of a series to estimate the value of the series
Using Python to numerically, graphically, and analytically find the limit of a sequence
Using Python to find the radius and interval of convergence of a power series with the Ratio Test
Using Python to identify the region between curves and then evaluate the area of the region
Using Python to calculate the amount of work done in moving a spring using Hooke's Law
Using Python to calculate the work done in pumping the liquid from a tank whose ends are semicircles
Finding the volume of a solid of revolution in Python
Video 29 in a series of Python instructional videos
Writing a linear equation of profit from a business word problem
Explaining the main three forms for linear equations
Discussing properties of linear functions
Discussing the types of linear graphs including horizontal and vertical lines and their properties
Solving a linear equation algebraically and showing how this relates to the graph
Solving a linear equation algebraically
Solving a linear equation algebraically and showing how this relates to the graph
Explaining the format and possible solutions for a system of two linear equations
Solving a system of two linear equations using a TI-84 calculator
Solving a system of two linear equations using a TI-84 calculator
Explaining the graph and properties for the parent function of quadratics
Explaining when a quadratic equation does not have a real solution
Discussing parent functions of rational functions and their properties
Explaining the general properties of even and odd root functions
Solving equations with even roots and checking the solutions
Properties of exponential growth and decay functions
Properties of the exponential function with base e
Explaining how to solve equations with power and exponential terms
Explaining the basic properties of logarithmic functions
Using double integrals to calculate the weight of a plate given its density and size
Evaluating iterated integrals over the same region but with different orders of integration
Writing and then solving an iterated integral for a given region
Explaining the main three forms for linear equations
Discussing properties of linear functions
Discussing the types of linear graphs including horizontal and vertical lines and their properties
Explaining the format and possible solutions for a system of two linear equations
Properties of exponential growth and decay functions
Properties of the exponential function with base e
Explaining the basic properties of logarithmic functions
Introducing functions of several variables and level curves
Explanation of partial derivatives for functions with more than one variable
Review of limits, continuity, and the Intermediate Value Theorem