How can you write sgn[Im(z)] in fortran?

  • Topic: Fortran 
  • Thread starter Thread starter nnnnn
  • Start date Start date
  • Tags Tags
    Fortran
Join the discussion
Registration is free. Start your own thread to ask a follow-up.
2 replies · 3K views
nnnnn
Messages
5
Reaction score
0
How can you write "sgn[Im(z)]" in fortran?

Hello everybody;


How can you write "sgn[Im(z)]" in fortran? , then what do

you need to add in the header?

also what does "sign(a,b)" mean?


Much Thanks in advance
 
Physics news on Phys.org


I'm not sure how your compiler will handle SIGN with complex numbers. It may be useful for you to keep track of the real/imaginary components separately in different variables rather than using a single COMPLEX variable.

If it does work with complex numbers though, then great.