I need to build the following functions in matlab
y1=sign(x)
y2=tanh(x)
y3=(x)/(x+1)
The x-range is 5.5 with an interval of 0.1. The y-plot range should be between -1.5 and 1.5.
Each graph should have a designated x and y axis and a legend in the lower right corner.
The only thing I can not understand is to adjust the range of plots. Ive tried editing the actual figure, but all that seems to be is to distort the graph. Is there a command in Matlab that will allow me to adjust the range of the y-axis plot?
Another thing that I still do not understand is adding a legend, I can do this after creating the figure, but I think that this should be done using the matlab command.
source
share