Hello community. I've struggled for a bit now with this.
I don't understand how I can get elementwise multiplication and addition to work here. The graph is not what it should look like when I run this program. I've tested with other software, such as Geogebra. Other than that, when I change the range from -5 to -10, the graph shifts with it.
I just don't see how to fix this problem. I would love help on this. Thanks.
values = -5:0.1:5;
f = @(x)(exp(1-2.*x).*(x+cos(2.*x)));