Ask Your Question

Complex number norm

asked 2018-01-14 19:06:29 +0200

paradox gravatar image

I'm new to sage so sorry if this is a stupid question.

When I try to compute the norm of a complex number Sage doesn't evaluate it:

abs(sqrt(3) + I)

gives the exact same thing ( instead of sqrt(10) ):

abs(sqrt(3) + I)

What am I doing wrong

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2018-01-14 21:11:04 +0200

tmonteil gravatar image

You can further simplify as follows:

sage: abs(sqrt(3) + I).full_simplify()

Or use the norm function:

sage: sqrt(norm(sqrt(3) + I))
edit flag offensive delete link more


Thanks for your help!!!

paradox gravatar imageparadox ( 2018-01-29 19:14:51 +0200 )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

1 follower


Asked: 2018-01-14 19:06:29 +0200

Seen: 1,010 times

Last updated: Jan 14 '18