Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 14
Default Formatting complex number display

Hello there in never never land.
Can someone help me in formatting complex numbers.
How do I get the following simple "complex" function to display as "-1+0i",
rather than
-1+1.22514845490862E-016i ?
function : =+COMPLEX(COS(PI()),SIN(PI()))
--
Lewis
Engineering Solutions

  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 11,058
Default Formatting complex number display

Why not just test the size of the imaginary part and if it is really, really
small force the display of 0?:

=IMREAL(A1)&IF(ABS(IMAGINARY(A1))<0.0000000001,"+0 i",IMAGINARY(A1))

will display:
-1+0i
if A1 contains:
=+COMPLEX(COS(PI()),SIN(PI()))

--
Gary's Student
gsnu200702


"Lewis" wrote:

Hello there in never never land.
Can someone help me in formatting complex numbers.
How do I get the following simple "complex" function to display as "-1+0i",
rather than
-1+1.22514845490862E-016i ?
function : =+COMPLEX(COS(PI()),SIN(PI()))
--
Lewis
Engineering Solutions

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
when certain number is typed in a cell to display a message Wanna Learn Excel Discussion (Misc queries) 8 September 18th 06 02:27 PM
How to display results to certain number of significant figures Coeliac Excel Discussion (Misc queries) 1 January 10th 06 12:04 PM
Conditional Number formatting? Scott Dawson Excel Discussion (Misc queries) 5 December 20th 05 12:46 AM
Phone Number Formatting Brant Nyman Excel Discussion (Misc queries) 5 August 25th 05 06:56 PM
Why won't my conditional formatting display in the cell Cashius War eagle Excel Discussion (Misc queries) 3 February 15th 05 08:38 PM


All times are GMT +1. The time now is 11:44 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"