Ask Your Question

min(f,g) where f and g take two variables

asked 2012-04-19 15:52:55 +0100

sagemb gravatar image


Is it possible to create a function h(x,y) that would be the minimum (or maximum) of any two other 2-variable functions?

Like h(x,y)=max(f(x,y),g(x,y))? (this does not work)

This seems to be a rather useful function but I can't seem to find it.

any ideas?

Thanks N.

edit retag flag offensive close merge delete


Just for reference for those finding this, this is nearly the same question as ... which apparently you asked? (It says anonymous but you replied later.) I'm wondering if maybe we misinterpreted one of your questions and gave a less than useful answer.

kcrisman gravatar imagekcrisman ( 2012-04-19 23:05:28 +0100 )edit

1 Answer

Sort by ยป oldest newest most voted

answered 2012-04-19 17:57:40 +0100

achrzesz gravatar image

For example:

sage: h(x,y)=max_symbolic(x^2-y^2,y^2-x^2)  
sage: plot3d(h(x,y),(x,-1,1),(y,-1,1))
edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools


Asked: 2012-04-19 15:52:55 +0100

Seen: 700 times

Last updated: Apr 19 '12