Plot (sin(x)*sin(x))/x
Title
Question
It gives an error "name 'x' is not defined."
I used the command -- plot(x, (sin(x)*sin(x))/x)
Python-3.4.3 Using-plot-command-interactively 08-09 min 10-20 sec
Answers:
This error usually means that you have not initialised the variable x and are directly trying to reference the variable in your code. please initialise the variable x using the linspace command as demonstrated earlier in the video.
Login to add comment