MathGroup Archive 2006

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Plot equations and inequalities together

  • To: mathgroup at smc.vnet.net
  • Subject: [mg65332] Re: Plot equations and inequalities together
  • From: "dennis" <dwangsness at earthlink.net>
  • Date: Mon, 27 Mar 2006 06:55:57 -0500 (EST)
  • References: <e035gn$2cb$1@smc.vnet.net>
  • Sender: owner-wri-mathgroup at wolfram.com

Bonny wrote:
> I am not being able to plot graphs of equations and inequalities together,
> for e.g. (x==5 && y==10) || (x>5 && y==15). I tried InequalityPlot but that
> does not work; it plots only inequalities. Can anyone tell me a command (or
> a combination of commands or a graphics package) in Mathematica that I can
> use to plot graphs of equations and inequalities together similar to the
> example above?
>
> Thanks much.

The Boole function might be what you need.

DensityPlot[Boole[(x==5 && y==10) || (x>5 && y==15)],{x, 0, 20}, {y, 0,
20}]

seems to show your regions.  You might play around with PlotPoints, but
some, probably most, values for PlotPoints will miss your point and
line region.  To make your regions a little more easily hit on in a
plot you might replace quantities like x==5 with Abs[x-5]<some small
value.

Dennis


  • Prev by Date: Re: Writing prime factor decomposision in conventional form
  • Next by Date: Re: Writing prime factor decomposision in conventional form
  • Previous by thread: Plot equations and inequalities together
  • Next by thread: Sum problem