Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [complex]

The tag has no usage guidance.

0
votes
0answers
23 views

conditioning of complex objective function via change of coordinates

I want to minimize a function $f(z) = z^H A z + c_1^T \theta + c_2^T \log(r)$ where $z = r e^{i\theta}$, $z\in \mathbb{C}^n$, $A \in \mathbb{R}^{n\times n}$ is symmetric positive definite, and $c_1, ...
1
vote
1answer
65 views

Computing real normal modes from complex eigenvectors

I'm trying to get the normal modes of a system of springs and dasphots using the basic dynamic equations for a linear, damped elastic structure: $ M \ddot{u}(t) + C \dot{u}(t) + K u(t) = f(t) $ to ...
3
votes
2answers
319 views

Complex Eigenvalues using eig (Matlab)

I wanted to find and plot the eigenvalues of large matrices (around1000x1000). But discovered when using the eig function in matlab, it gives complex eigenvalues when it shouldn't. For example, in the ...
6
votes
3answers
736 views

Power of complex-valued neural network

I often see neural networks extended to complex-values. Those networks allow complex input, complex parameters, and complex output. My understanding is that the inner products and point nonlinearities ...
1
vote
1answer
83 views

Mapping from n x n complex symmetric tridiagonal to 2n x 2n real symmetric tridiagonal

In my program I have a complex symmetric tridiagonal matrix. In order to perform some algorithmic optimizations I am searching for a (ideally linear) mapping from $n\times n$ complex symmetric ...
7
votes
1answer
79 views

Numerical computation of the complex elliptic integral $E(k)$ for medium $|k|$

I have implemented Carlson's algorithm for $E(k)$ from Numerical computation of real or complex elliptic integrals (available from ArXiv eprint, see also DLMF). It is essentially his formula (46) ...
3
votes
0answers
120 views

What is the computational cost of using complex numbers in contrast to real numbers in matrix operations, e.g. $LU$ or $LDL^T$ factorizations? [duplicate]

I am curious about how much one loses in terms of computational cost, when complex numbers are used instead of real numbers? I guess the number of floating point operations and memory doubles, but I ...
2
votes
0answers
277 views

Arpack and Matlab give different values for eigenvalues

I am solving a generalized eigenvalues problem with inversed complex shift: $$(M-\sigma J)^{-1}J \boldsymbol{x} = \boldsymbol{x} \nu \enspace .$$ My matrices are obtained from a finite element ...
11
votes
2answers
557 views

Danger of complex arithmetics in scientific computing

The complex inner product $\langle u,v\rangle$ has two different definitions decided by conventions: $\bar{u}^Tv$ or $u^T\bar{v}$. In BLAS, I found the routines cdotu, zdotu, and cdotc, zdotc. The ...
6
votes
1answer
387 views

Reference BLAS/LAPACK from NETLIB is twice as fast as MKL for complex numbers

I'm solving the Helmholtz equation using PETSc. I found with the PETSc configure option --download-f-blas-lapack my program runs twice as fast over running it with ...
13
votes
2answers
1k views

Why would a computational scientist need to implement their own version of std::complex?

Many of the better-known C++ libraries in computational science such as Eigen, Trilinos, and deal.II use the standard C++ template header library object, ...
2
votes
1answer
527 views

Implicitly casting PetscReal to the real part of PetscComplex

The version of Petsc installed on my machine has PetscScalar set to be complex. I am making a matrix which has all real entries. Something like the following code compiles: ...