Mathematica 9 is now available
Student Support Forum
Student Support Forum: 'Combine Plot and If' topicStudent Support Forum > General > "Combine Plot and If"

Next Comment >Help | Reply To Topic
Author Comment/Response
09/15/11 09:02am


I am combining the "Plot" and "If" functions and somehow the resulting graph is only in one style.

Mickey Mouse example:

Plot[If[x < 2, {x^2, x^3}, {x + 2, x + 5}], {x, 0, 5}, PlotStyle -> {Dotted, Dashed}]

What comes out of this command is a dashed graph, however since there are two lines I want Mathematica to draw one Dotted and one Dashed one and not both Dashed.

Thanks for your help


URL: ,

Subject (listing for 'Combine Plot and If')
Author Date Posted
Combine Plot and If Stefan 09/15/11 09:02am
Re: Combine Plot and If yehuda ben-s... 09/15/11 1:29pm
Next Comment >Help | Reply To Topic