CHAPTER 06.03: LINEAR REGRESSION: Linear Regression with Zero Intercept: Example

 

In this segment, we're going to take an example of linear regression, but we're going to take an example which is a special case, a special case where the intercept is 0.  So you are trying to develop a relationship between y versus x, with a1 being the slope, but there is no intercept.  A good example of that can be, which we're going to just do in a little bit, is that if somebody gives you stress versus strain of some material which is linearly elastic.  So you may have some data points which you have chosen for stress versus strain, and we know that the slope of the stress versus strain curve will have to go through the origin here, if there are no residual stresses of course, and then the slope of the line of the stress versus strain will give us the Young's modulus.  So this E which you are seeing here is the Young's modulus, it's the elastic . . . it's one of the elastic moduli of the material.  So let's go ahead and see that how we're going to go about finding out the relationship between stress and strain, and be able to find out what this Young's modulus of a composite material is, and we know that the regression model has to go through the origin.  Now, we know that when y is equal to a1 x is the regression model, and we are given data points x1, y1, x2, y2, and so on and so forth, then a1 is nothing but the summation of the multiplication of the x and y values, i is equal to 1 to n, divided by the summation of the x values, which are squared, from 1 to n, that is the formula which we have for a1. So all we have to do is to multiply each x value with y value, add them up, square each x value, add them up, and that gives us the value of a1. So let's go ahead and take some numbers, and we'll take an example, take numbers for our composite material. We are given stress versus strain. The strain is given as a percentage, and stress is given as megapascals.  Again, we had about twenty data points or so, but for the sake of brevity, I'm only taking six data points from the experimental data, real life experimental data. So these are the six strains which are given to use, keep in mind that the strains are given as a percentage.  The stress is given as 0, 306 megapascals for this one, 612 for this one, 1835 for this one, 2767 for this one, and 2896 for this one. So I will have to take this particular data to be able to find out what the Young's modulus is. And what I'm going to do is I'm going to convert this data into the basic units, I'm going to use this as a non-dimensional, meter per meter, and then stress I'm going to just put it in pascals.  It's a good idea always to convert your numbers into the basic system of units, whether it's SI or USCS system of units, that way you don't have to be concerned about whether you are making the right change of units and things like that.  So since this is a percentage, this will get divided by 100, so I'll have 0, 0.00183, 0.0036, 0.0102, 0.015, and 0.0156.  So those are the strain values which you have, and since the stresses are given in megapascals, I will convert them into pascals.  I'll get 0, 306 times 10 to the power 6, 612 times 10 to the power 6 pascals, then 1835 times 10 to the power 6 pascals, 2767 times 10 to the power 6 pascals, and 2896 times 10 to the power 6 pascals. So I have just basically converted your data into the base system of units for the SI system. And now, in order to find out the Young's modulus, I know that sigma is equal to E epsilon is the regression model which I want to best fit to these six data points, and I know that the Young's modulus, E, will be nothing but the summation of the sigma-i times epsilon-i values, i is equal to 1 to 6, because I have six data points, divided by the summation of the square of each of the strain values, and again, I'll be adding all of them, all the six values there.  So that's what I need to calculate to be able to find out what the Young's modulus is.  So let's go ahead and see that what those numbers turn out to be. So my first summation is from i equal to 1 to 6, sigma-i epsilon-i.  So the first number is 0, and first strain is 0, the second stress is 306 times 10 to the power 6, and the second strain is 0.00183, plus all the way up to the last number which I have, which is 2.896 times 10 to the power 6 times 0.0156.  So there are several other data points which are in between here, three of them, so I'm just showing you the first, second, and the last one which you have to add, by simply multiplying each stress quantity by the corresponding strain quantity, and this number here turns out to be 1.082 times 10 to the power 8, that's what I get as the value there.  Then summation of, i is equal to 1 to 6, epsilon-i squared, which is simply squaring each stain value, and adding them up.  So let's suppose the first strain value is 0, so I'm going to square it and add it up, the second strain value is 0.00183, so I'm going to square it up before I add it up, and then the last one which I will have, there will be three more, and the last which I have is 0.0156, and I square that one up.  And this summation of all the squares of each individual quantity turned out to be 5.887 times 10 to the power -4.  So that's what I get, so this is the summation of the sigma-i epsilon-i, and this is the summation of the epsilon-i squared, so those are the only two quantities which I need in order to be able to calculate the Young's modulus.  So the Young's modulus will be this quantity here, which is the summation of sigma-i epsilon-i, so let me write it down, just for completion, i is equal to 1 to 6, divided by the summation of, i is equal to 1 to 6, epsilon-i squared.  So the numerator is 1.082 times 10 to the power 8, the denominator is 5.887 times 10 to the power -3.  So those are the two values which I need, and I get here to be 1.837 times 10 to the power 11 pascals here, those are the units of the Young's modulus, and that gives me 183.7 gigapascals as my Young's modulus, if I convert it into the units which you generally see for Young's modulus. So that's what turns out to be Young's modulus of this particular composite material of which we had taken six strain data . . . six stress versus strain data points. And that's the end of this segment.