If you're seeing this message, it means we're having trouble loading external resources on our website.

If you're behind a web filter, please make sure that the domains *.kastatic.org and *.kasandbox.org are unblocked.

Main content

Dependent & independent variables

We introduce independent and dependent variables: how to identify the independent/dependent variable in a given setting, and how we write equations with the dependent variable by itself. Created by Sal Khan.

Want to join the conversation?

  • blobby green style avatar for user 2201375
    This is confusing
    (6 votes)
    Default Khan Academy avatar avatar for user
    • piceratops ultimate style avatar for user Ananta
      It depends whether a variable is dependent or independent. In the video, he presents two scenarios:

      scenario 1: you want to buy a certain number of apples
      scenario 2: you have a limited budget.

      In the first scenario, the number of apples (a) is the independent variable, but in the second one it's the total cost (c) since you decide how many apples or how much your budget is, the dependent variable depends on your decision of the independent variable.

      Here's another analogy, a dependent variable is like a passenger in a car, and an independent variable is like the driver. The driver (the independent variable) determines the car's direction and speed, while the passenger (the dependent variable) goes along for the ride. In the same way, the value of the dependent variable depends on the value of the independent variable.
      (2 votes)
  • blobby green style avatar for user Jimenez,jafet
    how did get the apples
    (3 votes)
    Default Khan Academy avatar avatar for user
  • aqualine ultimate style avatar for user H3V1.
    wait, if the independent and dependent variables are interchangeable, how do we know which to label as which (idk if that made sense)?
    (3 votes)
    Default Khan Academy avatar avatar for user
  • starky tree style avatar for user shadun29
    are you a person
    (1 vote)
    Default Khan Academy avatar avatar for user
  • blobby green style avatar for user Elnemr, Amar
    Does the independent come before the equal sign or after
    (1 vote)
    Default Khan Academy avatar avatar for user
    • mr pink green style avatar for user David Severin
      It depends on which form of equations you are talking about. Often, many forms isolate the dependent variable (which usually ends up on the left side of the equation) such as y=mx+b (linear) or y=ax^2+bx+c (quadratic). Thus, in general the dependent is isolated on the left and the independent is on the right.
      (0 votes)

Video transcript

- [Teacher] Let's say that you love to eat apples, and you are going to buy a apples, so a is the number of apples, number of apples, but you also have a budget, so you have to care about costs, so let's say C is equal to the total cost, and let's say that the price of an apple is $2, so $2 per apple. There's several ways that we can express the relationship between the total cost and the number of apples. One way is if we solve for the total cost, and we say, okay, the total cost is gonna be $2 per apple times the number of apples, so it's going to be 2a. Another way that we could rewrite this if we were to divide both sides of this by two, we would get that the number of apples is equal to cost over two. These are equivalent expressions I should say these are equivalent equations, but the way they've been written, make it useful for different scenarios. For example, on the left-hand side here, it's really easy to try out different As and then think about how that will affect the cost, and so when it's written like this, we would call the variable that it's easy to try out different values, we would call that the independent variable, independent variable, and then the one that we are essentially solving for that we then spit out a value after we compute using the independent variable, you call that the dependent variable. You could view it as, look in this situation, the cost is dependent on the number of apples you choose to eat. Now, when we wrote it over here, this looks a little bit different. Now the number of apples is solved for, and we compute how many apples based on the cost, so this would be a scenario where you have a budget and you tell me what the budget is and I could tell you the number of apples. So in this situation, C is the independent variable, and since we have solved for a, a is the dependent variable. This is useful if I give you a number of apples and you want to know the total cost, and this is useful if you have a certain cost and then you want to find out the number of apples.