# Plotting the implicit function $y=\log_2(1+x\,y)$ [duplicate]

I want to plot the implicit function $y=\log_2(1+x\,y)$ as a function of $x$.

I tried with ContourPlot and NSolve, but I'm getting a lot of errors.

• Where is your try? – zhk Jun 15 '17 at 3:19

Something like this?

f[x_, y_] := y - Log2[1 + x*y];

ContourPlot[f[x, y] == 0, {x, 0, 5}, {y, 0, 5}, ColorFunction -> Hue]

• Perhaps, y - Log[1 + x*y, 2] instead. – bbgodfrey Jun 15 '17 at 3:43
• @bbgodfrey I think, it should be y - Log[2, 1+x*y]? What you say? – zhk Jun 15 '17 at 3:50
• Indeed, it should. – bbgodfrey Jun 15 '17 at 3:51
• @bbgodfrey Thx for pointing that out, otherwise, I could have suggested something wrong. – zhk Jun 15 '17 at 3:52

The straightforward approach works for me.

 ContourPlot[y == Log2[1 + x y], {x, 1, 100}, {y, 1, 10}]


Just to complete, solve the equation with respect to x, yeilding x=(2^y-1)/yand then use the parametric plot:

ParametricPlot[{(-1 + 2^y)/y, y}, {y, 0.1, 10}, AspectRatio -> 0.7]


Have fun!