Ask Your Question
0

How to get an integer from a complex expression?

asked 2012-02-17 17:33:35 +0100

this post is marked as community wiki

This post is a wiki. Anyone with karma >750 is welcome to improve it.

Hi, (22/3*sqrt(2)*sqrt(3) + 485/27)^(1/3) + 1/9/(22/3*sqrt(2)*sqrt(3) + 485/27)^(1/3) + 20/3 equals 10. But how can I get 10 as an integer, as the complex expression has more complex solutions?

edit retag flag offensive close merge delete

Comments

1

Can you explain what you mean by "get 10 as an integer"? you can use n() to get 10.

Shashank gravatar imageShashank ( 2012-02-17 18:17:24 +0100 )edit

I still don't get it. What do you mean by 10 as an integer. ((22/3*sqrt(2)*sqrt(3) + 485/27)^(1/3) + 1/9/(22/3*sqrt(2)*sqrt(3) + 485/27)^(1/3) + 20/3).n() = 10.00. What do you want to use the answer for?

Shashank gravatar imageShashank ( 2012-02-17 22:29:10 +0100 )edit

Thanks for your reply. The complex expression is the solution found by solve, and from theory I know the answer must be an integer. I can use *.n() but that is a real/complex number coincidently equal to 10. What I'm looking for is a solution which is really an integer e.g. is_integer should be True.

Rolandb gravatar imageRolandb ( 2012-02-21 03:05:08 +0100 )edit

1 Answer

Sort by ยป oldest newest most voted
0

answered 2012-02-20 10:58:43 +0100

this post is marked as community wiki

This post is a wiki. Anyone with karma >750 is welcome to improve it.

You can get 10 by .rhs() (it stands for "right hand side"):

((22/3*sqrt(2)*sqrt(3) + 485/27)^(1/3) + 1/9/(22/3*sqrt(2)*sqrt(3) + 485/27)^(1/3) + 20/3 == 10).rhs()
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

Stats

Asked: 2012-02-17 17:33:35 +0100

Seen: 421 times

Last updated: Feb 20 '12