My piecewise function graph is not showing
Mostrar comentarios más antiguos
I'm trying to plot the the function below, here is what I have
f(x) = 2x x ∈ [0, 0.5]
2x − 1 x ∈ (0.5, 1]
syms x
f(x)=piecewise((0<=x)&(x<=0.5),2*x,(0.5<=x)&(x<=1),2*x(-1),6);
fplot(f(x));
grid on;
Respuesta aceptada
Más respuestas (0)
Categorías
Más información sobre Assumptions en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
