Questions tagged [complex]

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

Filter by
Sorted by
Tagged with
0
votes
0answers
13 views

Summation involving complex conjugate pairs

Consider the prime counting function $$\pi(n)=R(n)-\sum_{\rho} R(n^{\rho})$$ where $R$ is Riemann's function (link) and the $\rho$ are the non-trivial zeroes of the zeta function, taken in ...
1
vote
1answer
52 views

Bug in FindRoot?

...
2
votes
1answer
41 views

Solving complex trig quations - missing solutions?

{ Sin[Pi/2 + I*Log[2 + Sqrt[3]]], Sin[Pi/2 - I*Log[2 + Sqrt[3]]], Sin[Pi/2 + I*Log[2 - Sqrt[3]]], Sin[Pi/2 - I*Log[2 - Sqrt[3]]] } // FullSimplify ...
2
votes
0answers
38 views

Better way to treat branch cut problem in Mathematica

Currently, Mathematica treats function which has branch cuts; $\log(z)$,$\sqrt[n]{z}$, etc, by taking its principal value. This may cause a problem in Contour integration when the path of integration ...
0
votes
1answer
57 views

How to substitute by NDSolve solution to plot a new function

Assume I got some function by NDSolve , like y(t) ...
4
votes
1answer
84 views

Real and imaginary parts of complex logarithm

I need to obtain the real and imaginary parts of the below expression with Mathematica: $(- i a - m^2) \ln(\frac{i m^2}{2 a})$, where $a$ and $m$ are real. So we have: ...
2
votes
2answers
33 views

Convert string of tuple of numbers to complex number

I am reading complex number from a file which gives me a list like that ...
0
votes
1answer
38 views

No result returned on ContourPlot with specific relation

For reference, I am using Wolfram Mathematica 12.0. I am attempting to plot the complex subset defined by: $|z+6|+|z-6| =1$ where z is a complex number $z = x+ i y$. Utilising ContourPlot directly ...
0
votes
1answer
68 views

How to chop a complex number?

I'm solving some differential equations by iterating and I want to use Chop to get rid of noice smaller than a certain threshold. However, I found that Chop only "chops" the real part, not the ...
8
votes
3answers
857 views

Modify real part and leaves imaginary part unchanged

How can I flip the sign of the real part but not affect the imaginary part of a complex number: a+bi => -a + bi Example list: ...
1
vote
1answer
74 views

Contour plot of streamfunction

I am trying to obtain a graph similar to this one: ...
0
votes
0answers
35 views

Manipulate and Parametric plot not show anything.Why?

My aim was to map a semi ellipse to a semi-circle, for different values of ellipse parameters to a circle of different radius. So I have written a code in Mathematica. ...
0
votes
0answers
34 views

Plotting NDSolve function in complex coordinates

I have this system of equations: $- \ddot{z} + \frac{1}{g} \frac{\partial g}{\partial z} \dot{z}^2 + \frac{1}{g} \frac{\partial g}{\partial z^*} \dot{z} \dot{z}^*$ =0 , $- \ddot{z}^*+ \frac{1}{g^*} ...
1
vote
2answers
100 views

Linear fit statistics for a complex data set

I am having some technical and conceptual troubles in using NonlinearModelFit with a complex data set. I have a 2 dimensional array where the two positions are complex numbers, such that: ...
1
vote
3answers
75 views

Riemann surface of incomplete gamma function

Michael Trott in his book The Mathematica GuideBook for Symbolics, page 1003, has illustrated a nice way to visualize the Riemann surface of the incomplete gamma function $\Gamma[\alpha, z]$. To plot ...
1
vote
1answer
79 views

Plotting a function in 3 dimensions within a domain

In this paper: https://www.staff.science.uu.nl/~beuke106/HypergeometricFunctions/COGP.pdf Any help how to reproduce the plot in Figure:7 It’s the leading order of the complex function, Equation (...
-1
votes
1answer
112 views

Can I numerically solve these equation in Mathematica? [closed]

I have this couple of equations : $ \partial_\mu \partial^\mu z^i + G^{i\bar{p}} (\partial_j G_{k\bar{p}} ) \partial_\mu z^j \partial^\mu z^k + G^{i\bar{j}} (\partial_{\bar{j}} G_{k\bar{l}} ) \...
0
votes
0answers
37 views

Solving differential forms equations

I have this couple of equations in differential forms language: $ \Delta z^i \star {\bf{1}}+ G^{i\bar{p}} (\partial_j G_{k\bar{p}} ) dz^j \wedge \star dz^k + G^{i\bar{j}} (\partial_{\bar{j}} G_{k\bar{...
3
votes
1answer
119 views

how To Improve that ComplexPlot3D

I have in mind the result of ComplexPlot3D[Log[MittagLefflerE[1/2, z]],{z, -50 - 50*I, 50 + 50*I}, PlotPoints -> 300,PlotRange -> All] In particular, the ...
1
vote
1answer
36 views

Assuming x real, simplifying or refining Im[1/(x+i)] doesn't yield anything

I think it is straightforward from the title, Simplify[Im[1/(x+I)], x > 0] spits out, Im[1/(x+I)] while I would have ...
0
votes
1answer
27 views

Get Conditions for Variable to be Real

I have a complex definition of a few variables (that I got using s = Solve[1 - a x^2 - x^3 == 0, x]) and I now want to know under what conditions of "a" will each ...
0
votes
1answer
49 views

Remove +0Is from Root function

I'm trying to find the zeros of the eigenvalues (functions of $k_x$) of a self-adjoint $4\times4$ matrix H: ...
4
votes
1answer
100 views

Mathematica not simplifying rational powers in complex expressions

I have the following expressions and I would like to obtain a final result purely in the real domain. ...
1
vote
0answers
32 views

How to compute Bott-Chern operator ddc

I wish I could make Mathematica compute the $dd^c=2i\partial\bar\partial$ of a function depending on several complex variables. The question involves complex or Wirtinger derivatives (https://...
3
votes
1answer
86 views

Problem with complex eigenvalues in periodic Sturm-Liouville problem

I'm having trouble using NDEigenvalues to obtain the first few eigenvalues for a differential operator on the circle of radius one-half. $\qquad Lf(x) = f''(x)+ (-...
1
vote
1answer
54 views

visualizing branch cut of a complex function

I'm working in the plotting the branch cut of a complex function, namely: $w(z) = (2+z) \ln(2+z) - 2(1+z) \ln(1+z) + z \ln z$. To do so, I have tried this: ...
9
votes
1answer
285 views

Why ArcTan[1, 0. I ] yields -1.5708+0. I?

Bug introduced in 5.2 or earlier and persisting through 12.0.0 Why ArcTan[1, 0. I ] yields -1.5708+0. I ? The result should ...
0
votes
3answers
70 views

expression containing radicals of imaginary numbers

I can't bear an expression containing radicals of imaginary numbers, in case it can be expressed as in terms of radicals of real numbers only. For example, I can't bear the expression Sqrt[2 + i] ...
5
votes
1answer
127 views

Visualizing Riemann surface (two branches) of logarithm

I'm trying to plot two branches of the complex multi-valued function: (In a previous post - linked above-, Mathematica found the branch cut of the following function between -1 and 0) $1-z\ln[(1+z)/z]...
4
votes
2answers
166 views

To plot branch cut of logarithm

I like to see the branch cut of the function: $$1 - z \ln[(1+z)/z].$$ If I plot it in the complex plane: ...
1
vote
1answer
64 views

How to plot special contour lines for a “Ridge System” of complex function?

Mathematica makes it very easy to to plot the contour lines for a function of two real variables using ContourPlot. It also makes it very easy to plot the ...
0
votes
0answers
56 views

Unexpected difference between integral and summation?

I am trying to integrating something like: Integrate[Exp[-i*(k*x+k*z)]*Exp[-(x^2+z^2)],{x,-largenumber,largenumber},{z,-largenumber,largenumber}] My issue is that ...
2
votes
2answers
155 views

Getting an Accurate Transformed Region (Part II)

I asked earlier about transforming a set of curves and getting an accurate plot when a curve goes to infinity: Getting an Accurate Transformed Region Here is an example where a transformed region ...
1
vote
1answer
102 views

Getting an Accurate Transformed Region

I would like to get an accurate plot of the image of concentric circles under the transformation $$f(z) = \log(1+z).$$ I've defined $\cal R$ as the union of a few circles: ...
1
vote
1answer
76 views

How to extract only real part of 2nd root solution to C code?

I have this cubic polynomial: ...
3
votes
1answer
187 views

How to solve PDE with periodic and anti-periodic b.c.?

I need to solve the PDE for a complex function $A(x,t)=A_r(x,t)+iA_i(x,t)$ ...
0
votes
0answers
35 views

Why do all the Roots not show up in ContourPlot of an equation?

Roots by Normal Method: f[x_] := (Sin[x] + Cos[x] - Sqrt[2]) Sqrt[-11 x - x^2 - 30]; Reduce[(Sin[x] + Cos[x] - Sqrt[2]) Sqrt[-11 x - x^2 - 30] == 0, x] Which ...
1
vote
1answer
61 views

Verification of ComplexPlot

from Wegert Visual complex functions. I am trying to verify a phase portrait by reproducing it with Mathematica. The only problem is that I am misunderstanding the ...
0
votes
0answers
15 views

Set conditions on SingularValueDecomposition

I'm a new user of Mathematica, and I am having some issues with SingularValueDecomposition. This function returns three matrices {u,v,w}, with v that is diagonal and u,w unitary such that u.v....
0
votes
1answer
36 views

Conditions to make unitary a given matrix

Suppose I have some symmetric matrix W = {{c[1, 1], c[1, 2], c[1, 3]}, {c[1, 2], c[2, 2],c[2, 3]}, {c[1, 3], c[2, 3], c[3, 3]}}; where the c's are complex and I ...
0
votes
1answer
36 views

Interesting output in Integrate [closed]

I found interesting behaviour, best illustrated in the following example. When trying to evaluate Integrate[1/(d^2 - 1), d] Mathematica 11.3 gives the following ...
1
vote
1answer
83 views

Sharp jagged lines in Plot3D

I have the following function of five parameters of which I would like to construct a 3D density plot using Plot3D ...
1
vote
2answers
39 views

Different styles for different points in ComplexListPlot?

I'd like to use ComplexListPlot to show a point and its image under a complex function, with the point and image having different styles, say different colors. Use,...
2
votes
1answer
53 views

Plotting Complex Numbers as “Arrows” on the Complex Plane

Given the following complex numbers (defined as the values of two functions f and g defined only on the points ...
2
votes
1answer
86 views

Taking real and imaginary parts after reciprocal

I noticed the following strange scenario. When I defined a variable to be real, Mathematica does not only recognize that it is real after taking an inverse. How can I resolve this so that it will ...
0
votes
1answer
55 views

Adding degrees to complex numbers

I'd like to take the complex number $(1 + 0i)$ and (i) multiply it by $0.5$ and (ii) add 45 degrees to it (without changing its magnitude). But I'd like to get its complex represenation in non-polar ...
0
votes
1answer
57 views

Showing a specific (complex) point in a Graphic [closed]

Somewhat related to a previous post that I made - Complex infinity at a point and division by zero I'm still following the book on this example and I've come to the part where one draws the '...
2
votes
1answer
49 views

Discolored ComplexPlot ColorFunction [closed]

I have this code. ...
0
votes
1answer
54 views

Complex infinity at a point and division by zero

Edit: I've found out that the book was written for Mathematica 7, which was a pretty long time ago. It boils down to changes in syntax most probably, but simple renaming to lower lettercase does not ...
0
votes
0answers
30 views

Expanding the complex conjugate of a Mathieu function as a series

In my calculations, I found this equation: ...