Ask Your Question
0

Am I not inside the domain ?

asked 2014-11-11 01:33:58 -0500

jpapot gravatar image

updated 2014-11-12 00:07:39 -0500

x=var('x')
f = Piecewise([[(0,pi/2),-1],[(pi/2,pi),2]])
plot(f(x),(x,0,pi))

**?

ValueError: Value not defined outside of domain.

?**

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
1

answered 2014-11-11 02:49:22 -0500

ndomes gravatar image

Plotting a piecewise function is different to plotting 'normal' functions.

f = Piecewise([[(0,pi/2),-1],[(pi/2,pi),2]]) 
f.plot()
edit flag offensive delete link more

Comments

Thank you so much Danke sehr, ndomes Merci !

jpapot gravatar imagejpapot ( 2014-11-11 06:03:00 -0500 )edit

If that was the correct answer, then please click the little check mark near it so that people coming to this question can find it easily. Thanks!

kcrisman gravatar imagekcrisman ( 2014-11-11 08:32:28 -0500 )edit

Your Answer

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

Add Answer

Question Tools

Stats

Asked: 2014-11-11 01:33:58 -0500

Seen: 93 times

Last updated: Nov 12 '14