MATLAB Answers

gunmo gu

Plot f(x,y) = (x+y+xy+1) / xy = 0

Asked by gunmo gu
on 7 Jun 2016
Latest activity Answered by Ahmed
on 16 Sep 2018 at 19:13
 f(x,y) = (x+y+xy+1) / xy = 0

Hi, How can I plot 2D of the function above on MUPAD or Note ? It is simple 2D x, y space but I couldn't figure it out.

Thank you.


Sign in to comment.

2 Answers

Answer by Star Strider
on 7 Jun 2016
 Accepted Answer

You can do that with the Symbolic Math Toolbox and the fcontour function, setting ‘LevelList’ to a vector of zeros:

syms x y
f(x,y) = (x+y+x*y+1) / (x*y);
fc = fcontour(f);
fc.LevelList = [0 0];

See the documentation on fcontour for details.


Thank you for your help. I have another Question

1. How can I show X Y axis,....... 2. How can I add another function on Same figure ?

Use the hold function.

See the documentation on hold for details.

Sign in to comment.

Answer by Ahmed
on 16 Sep 2018 at 19:13


Sign in to comment.