Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
can anyone think of an easy way to parse the real and
imaginary part of a complex number into two separate cells in excel (using excel or VB) 2.111+0.34i = 2.111 0.34 -2.11-0.34i = -2.11 -0.34 i thought of cycling through the word using mid function and checking for ascii values thanks |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
=IMREAL(A1)
& =IMAGINARY(A1) HTH Dana DeLouis "levent" wrote in message ... can anyone think of an easy way to parse the real and imaginary part of a complex number into two separate cells in excel (using excel or VB) 2.111+0.34i = 2.111 0.34 -2.11-0.34i = -2.11 -0.34 i thought of cycling through the word using mid function and checking for ascii values thanks |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
can anyone think of an easy way to parse the real and
imaginary part of a complex number into two separate cells in excel (using excel or VB) 2.111+0.34i = 2.111 0.34 -2.11-0.34i = -2.11 -0.34 i thought of cycling through the word using mid function and checking for ascii values There are worksheet functions for this -- IMAGINARY and IMREAL. You may need to check the Analysis ToolPak add-in to use them. HTH, Merjet |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Try this
Call ExtractRI("string value in here") Function ExtractRI(x As String) r = Val(x) i = Val(Right(x, Len(x) - Len(Str(Val(r))))) End Function Cheers Nigel "levent" wrote in message ... can anyone think of an easy way to parse the real and imaginary part of a complex number into two separate cells in excel (using excel or VB) 2.111+0.34i = 2.111 0.34 -2.11-0.34i = -2.11 -0.34 i thought of cycling through the word using mid function and checking for ascii values thanks |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
yeah, i should have thought of that
thanks -----Original Message----- Try this Call ExtractRI("string value in here") Function ExtractRI(x As String) r = Val(x) i = Val(Right(x, Len(x) - Len(Str(Val(r))))) End Function Cheers Nigel "levent" wrote in message ... can anyone think of an easy way to parse the real and imaginary part of a complex number into two separate cells in excel (using excel or VB) 2.111+0.34i = 2.111 0.34 -2.11-0.34i = -2.11 -0.34 i thought of cycling through the word using mid function and checking for ascii values thanks . |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Parsing Column of Numbers into 5 separate columns | Excel Worksheet Functions | |||
Parsing out text or numbers | Excel Worksheet Functions | |||
VBA complex numbers | Excel Programming | |||
Complex Numbers | Excel Programming | |||
Complex numbers | Excel Programming |