Ask Your Question
0

'Graphics' object is not callable

asked 2021-10-29 09:40:28 +0100

CyrilleP gravatar image

updated 2021-10-29 11:07:18 +0100

tmonteil gravatar image

Sorry to ask anonymously a question but I cannot recover my account (...@...). . Why

var("x_2 z")
sol1=solve(4*x_1+ 3*x_2==z,x_2)
show(sol1)
obj1=sol1[0].substitute(z=10).rhs()
show(obj1)
plot(obj1,(x_1,0,100))

leads to 'Graphics' object is not callable ?

edit retag flag offensive close merge delete

Comments

Apart from the fact that i have to add some var("x_1"), it works well for me.

tmonteil gravatar imagetmonteil ( 2021-10-29 11:00:53 +0100 )edit

1 Answer

Sort by ยป oldest newest most voted
1

answered 2021-10-29 11:22:12 +0100

rburing gravatar image

updated 2021-10-29 11:24:58 +0100

Probably you have accidentally used plot (or solve or show) as the name of a variable in a piece of code that you didn't include here, so that the name no longer refers to the built-in function.

So don't use that name for your variable.

edit flag offensive delete link more

Comments

Thanks. I feel so stupid.

CyrilleP gravatar imageCyrilleP ( 2021-10-29 21:33:08 +0100 )edit

Don't worry, it happens to the best of us. You can also use from sage.plot.plot import plot to get the usual plot back in an active session. To discover that statement I used import_statements("plot").

rburing gravatar imagerburing ( 2021-10-29 21:41:07 +0100 )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: 2021-10-29 09:39:40 +0100

Seen: 1,079 times

Last updated: Oct 29 '21