Tagged Questions

Questions about using complex numbers in Mathematica. This includes basic arithmetic, functions of complex numbers, plotting complex functions, and dealing with branch cuts.

learn more… | top users | synonyms

-2
votes
1answer
46 views

Why is it so complicated to simplify a complex conjugate? [closed]

My question is very simple. I would like to multiply a complex number by its conjugate. Unfortunately, this seems to be extremely complicated in Mathematica. Consider the very basic example: ...
0
votes
0answers
28 views

Simplification of a complex-valued expression with purely real components

(I'm including all the information here, as I'm not sure how much of it is necessary to solve the problem. For a tl;dr skip to the bottom) I've been working on a problem involving calculating ...
0
votes
1answer
41 views

How find solve the equation complex conjugate? [closed]

Tried solving it with every function I know but couldn't z*=z^2
0
votes
1answer
71 views

How to find all roots of a complex number [duplicate]

Finding all roots, and I know there are four f them, of this (1 - i)^(1/4) Not only real, but imaginary as well
1
vote
1answer
49 views

Rationalize complex numbers

What is the best way to rationalize complex numbers, if not both the real and imaginary part are actually rational? According to the documentation, Rationalize ...
0
votes
3answers
71 views

Plot Complex Function [duplicate]

I want to have a 3D plot for the following function: (1.6 - 0.005 I) E^(-0.5 p^2 + ( 2. I) p q + (6.5 - 11 q) q) p and q from -10 to 10 Is there any way?
2
votes
1answer
37 views

A question about expanding complex functions of real arguments

I have the following problem. There is such an expression as: P[x_,y_] := z[y] E^(I beta x) + Conjugate[z[y] E^(I beta x)]; The variables ...
0
votes
0answers
54 views

ComplexExpand does not treat everything as real number

ComplexExpand does not treat everything as real number?? Please read the following simple example ...
7
votes
3answers
362 views

How do I plot the images of oriented curves under complex transformation?

I'm working on a complex transformation sketch that I'd like to create via mathematica. I'm working with the function $$w=z^2\tag{0},$$ where its real and imaginary parts are $u=x^2-y^2$ and $v=2xy$, ...
17
votes
1answer
666 views

Mobius transformations revealed

Mobius Transformations Revealed is a short video that vividly illustrates the simplicity of Mobius transformations when viewed as rigid motions of the Riemann sphere. It was one of the winners in the ...
1
vote
1answer
83 views

Real and Imaginary parts of solutions to a complex linear ODE system

Consider a complex linear ODE system $x'=Ax$, where $$A=\left( \begin{matrix} 0&1\\ -2&-i \end{matrix}\right). $$ One can first find the eigenvalues and eigenvectors using ...
0
votes
0answers
78 views

Differential equations with a complex variable

Is Mathematica able to handle ordinary differential equations where the variable itself is complex? I am looking for solutions of ODE systems of the form $$\left\{ \begin{align} i\frac{da_1}{dt} ...
2
votes
2answers
118 views

Listplot imaginary part of complex numbers

I have the following list w={{0.01,99 +0.00001414 I},{0.15,6.6370108 +0.003144129 I},{0.25,3.9515722 +0.00854493297 I},{6,0.10041 +0.28132187 I}} and I want to ...
4
votes
1answer
109 views

Optimizing a function containing a complex exponential

I've noticed the following significant different in performance for different formulations of the same function: ...
4
votes
2answers
93 views

Can't solve equation having complex coefficients

Why can't Mathematica solve $\quad\quad\frac{1-i}{\sqrt{2}}=e^{i \alpha } \tan \left(\frac{\beta }{2}\right)$ with the restrictions $\alpha \in [0, 2 \, \pi)$ and $\beta \in [0,\pi]$: ...
1
vote
3answers
80 views

Selecting a specific complex number from a list

I have a formula which is producing a large (hundreds of elements) list of complex numbers of the simple form $x+iy$. However I'm only interested in the one value which satisfies the conditions: ...
1
vote
4answers
174 views

How to extract only real solutions from the result of Solve

For Example, I have the following polynomial equations: $$ \left\{ \begin{array}{ll} \dfrac{2025 (208 x+5 (y-3446))}{52 (y+90)^2}+\dfrac{300 (8 x-21 y+1920) (y-80)}{7 (x+30)^3}+\frac{300 (80 x-21 ...
1
vote
1answer
67 views

How to solve the warning problem and obtain real roots without imaginary part?

I am trying to solve a equation with Newton's method via FindRoot, and the codes are: Define the functions: ...
1
vote
1answer
84 views

Plot sets in the complex plane [duplicate]

I just want to know if there's a way to plot sets in the complex plane. For example $$A=\{z\in \mathbb{C},z+e^{z}=0\},\\A=\{z\in \mathbb{C},\Re(z)+e^{z}\geq0\}.$$
3
votes
1answer
97 views

Express a complex function $f(z)$ as $u(x,y)+iv(x,y)$

How can I write a complex function $f(z)$ in the form $u(x,y)+iv(x,y)$ using Mathematica? Re and Im do not work, because they do it for complex numbers, not functions. For example, if I try ...
1
vote
1answer
131 views

Check for holomorphy of a function

Given a (rather complicated) function H(z), what is the best approach to check symbolically whether it is holomorphic? What I tried is checking explicitly the ...
1
vote
1answer
92 views

How do I solve for the real and complex parts of an equation simultaneously?

If I were to have an equation, say something similar to... (1-Sqrt[x - I y])/(1+Sqrt[x - I y]) = A + I B Where I = Sqrt[-1], is there a way for Mathematica to ...
2
votes
2answers
159 views

Contourplot of complex Roots

Suppose I have this equation: $$ z^2 + 3z + (x^2 + y^2) = 0 $$ I want the real and complex contour plot of $z(x,y)$. Analytically, the real/imaginary boundary is separated by condition $x^2 + y^2 ...
7
votes
2answers
257 views

Does FindFit support complex numbers or doesn't it?

Inspired by this previous question: Findfit doesn't give the good fit; Changing the starting values will not change the results. Consider the following complex-valued dataset. ...
1
vote
1answer
111 views

Simplifying complex expression with Mathematica

I want do get the imaginary part of Exp[I*t]/(1-Exp[I*t]) I've tried to do this Im[ComplexExpand[Exp[I*t]/(1-Exp[I*t])]] ...
0
votes
0answers
58 views

Why does this integral have a complex result

I wanted to find the normalization of distribution F2 . ...
3
votes
1answer
299 views

HarmonicNumber problem

I am looking for all the roots of HarmonicNumber, in the domain [-30, 1] and [0, 6000] for the real and imaginary parts, respectively, and where the parameter ...
0
votes
2answers
109 views

Absolute value and argument of a complex expression

I would like to find the absolute value and the argument of the expression: $ x + \sqrt { x^2 + y^2 } $ under the assumption that the absolute values of $ x $ and $ y $ are equal. I have written: ...
1
vote
1answer
83 views

Real and imaginary parts of a complex number

I would like to find the real and imaginary parts of $x + y$ in terms of polar coordinates. Here is code: ...
0
votes
3answers
103 views

Displaying the roots of a complex function using ListCurvePathPlot

I have the following algorithm: ...
0
votes
1answer
58 views

How to evaluate Floor[1/2 + Arg[z]/(2π)] with Re[z] > 0

I want to do a series expansion of an expression containing Gamma functions with specific arguments. An example is the following: ...
-2
votes
1answer
93 views

how draw root locus in mathematica 9 for a special case

my closed loop transfer function is: H(s)=2exp(-q)/(1+exp(-2q)) q=sqrt((a+k*sqrt(s)+s)*s) , s=sigma+jw how can i draw root locus of H(s) as 'a' changes for ...
3
votes
1answer
145 views

Riemann surface for cubic root

I'm trying to generate Riemann surfaces of higher order. I read How to visualize Riemann surfaces?, and the subsequent documents. I'm able to reproduce the surface using polar representation, but I'm ...
2
votes
1answer
173 views

Differential Equation in Complex Plane and Parametric Plot

I would like to solve $dx/dt=\sqrt{1 + (I x)^3}$, where x is complex, for some initial condition like $1 - 5 I$ and plot the imaginary part of the solution versus the real part. (A somewhat similar ...
1
vote
2answers
130 views

Complex differential equation

I want to solve $dx/dt=\sqrt{(1-x^2)}$, where $x$ is complex. When I solve it by hand and analytically for some initial value and draw the imaginary part versus the real part, I obtain an ellipse, as ...
0
votes
1answer
104 views

Plot a real part of complex equation depending on a parameter

I would ask you to kindly provide me a way to solve this problem in mathematica way. Let the equation $z^2 + 9 -1.5 e^{- t z}=0$ where $z\in \mathbb C$ and $t\in \mathbb R^+$. In order to plot graph ...
0
votes
0answers
63 views

Complex integrals and residues

I have a question. I try to integrate this function: Integrate[Exp[I k z]*Exp[-Sqrt[k^2 - A^2]x]*Exp[-k^2*L^2/4]/Sqrt[k^2 - A^2], {k, -Infinity, -A}] But ...
0
votes
0answers
102 views

A power series expansion

Consider the function, $f(z) = z tanh(\pi z) log (z^2 + a^2)$ for some $a>0$. Now I am considering 3 different situations, $z = i(n+0.5) - i\epsilon + \delta - it$ for $n \in \mathbb{Z}$ and ...
0
votes
0answers
58 views

Polar Plotting in Complex Plane [duplicate]

How would I plot the following functions in the polar complex plane? $$ \phi={-k\over 2\pi r}cos(\theta_0-\theta) $$ and $$ \psi={-k\over 2\pi r}sin(\theta_0-\theta) $$ Please ...
0
votes
1answer
71 views

Trouble fitting an explicitly complex model with the TransformedFit package

This is follow up from a previous question in which @Oleksandr R. suggested the use of a package he developed for splitting a model and data into real and imaginary parts to avoid a problem with ...
0
votes
1answer
64 views

Can't Plot Fourier Series [closed]

I have been trying to plot fourier series but the plot is allways empty. I guess there is something wrong in my code but i dont know exactly what is it. Looking here for some previous ...
-2
votes
1answer
158 views

How to solve a non-linear equation?

I am trying to solve the following non-linear equation: $\frac{i e^{-x^2} \sqrt{\pi } x}{K^2}+\left(-0.131251-0.0379031 x^2-0.0151154 x^4-0.0100462 x^6+0.5 \left(0.00273859 +0.0400003 K^2\right) ...
0
votes
0answers
74 views

About how Mathematica understands the branchcuts of the complex logarithm [Part 3]

One understands that for the function $\log(z^2+a^2)$ Mathematica implicitly puts the branch cuts to be starting at $\pm ia$ and going up/down respectively on the imaginary axis. The phase of this ...
1
vote
0answers
46 views

Conjugate of InterpolatingFunction?

From NDSolve, I got this: {{a1 -> InterpolatingFunction[{{0., 40.}}, "<>"]}} What would be a sensible approach to ...
0
votes
0answers
51 views

Always the same problem with Conjugate [duplicate]

I want to compute something like : ...
0
votes
0answers
724 views

Fastest way to create a NxNxNxN dimensional matrix

I have a function that outputs a complex number Func[x_,y_]:= blah blah; I have constructed a table of all possible values of this function. ...
0
votes
0answers
77 views

How does Mathematica understand branchcuts of the complex logarithm? [Part 2]

I observe that the answer generated by the first integration is not in any simple way related to the next two answers. (some simple jump of i 2\pi across the branchcut of the logarithm is not helping ...
10
votes
1answer
619 views

How does Mathematica understand branchcuts of the complex logarithm?

Say I have the function $f(x) = x \tanh(\pi x) \log (x^2 +a^2)$ where $a$ is some positive real number. Then it seems to be me that Mathematica when given such a ...
0
votes
0answers
37 views

Chopping pure Imaginary numbers [duplicate]

I would like to be able to Chop complex numbers and display only the non-zeroed real or imaginary part when applicable. Chop alone works just fine if the non-negligible part is only the real part. ...
1
vote
1answer
106 views

FindFit::nrlnum What am I doing wrong?

I have a model called qobs: ...