How to generate a surface by a function defined by two sentences?

I would like to generate a graphic like this:
(I'm using >> [X,Y]= meshgrid(0:0.01:1,0:0.01:1);
surf(X,Y,X.*Y);
colorbar. To generate this figure).
But for a function defined by two sentences:

Answers (0)

Categories

Find more on Graphics Object Properties in Help Center and File Exchange

Products

Release

R2021a

Asked:

on 21 Jul 2021

Commented:

on 21 Jul 2021

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!