I would like to plot a function on Matlab
$|x_1+2x_2|+|x_1|$ constraint to $|x_{1}| + |x_{2}| = 1$
I was searching but it has constraint with absolute and with two variables. Can anyone help me?
I would like to plot a function on Matlab
$|x_1+2x_2|+|x_1|$ constraint to $|x_{1}| + |x_{2}| = 1$
I was searching but it has constraint with absolute and with two variables. Can anyone help me?
Copyright © 2021 JogjaFile Inc.
Given by the Matlab program below :
which has 2 parts,
one for the first equation as a surface plot of $z=f(x_1,x_2)$ looking like an inverted roof, and
one for the representation of the second (superimposed) constraint as another surface that can be considered as a "chimney" intersecting it (the underlying 2D curve with equation $|x_1|+|x_2|=1$ is the square with vertices $(1,0), \ (0,1), \ (-1,0), \ (0,-1)$).