Hello,

I am working on the calculation of the pressure induced at d locations \{\xi_1, \ldots, \xi_d\} due to a set of n singularities located at \{z_1, \ldots, z_n\} with strength \{ S_1, \ldots, S_n\}, where \xi_i, z_J, S_J are complex numbers.

I end up having to compute the following double sum:

\sum_J \sum_{K \neq J} \frac{S_J}{2\pi} \frac{\overline{S}_K}{2\pi} \frac{1}{\xi_i - z_J} \frac{1}{\overline{z}_J -\overline{z}_K} for all i = 1,\ldots, d

Let define the matrices C_{yx} \in \mathbb{C}^{d \times n} as [C_{yx}]_{i,j} = 1/(\xi_i - z_j), C_{xx} \in \mathbb{C}^{d \times n} as [C_{xx}]_{i,j} = (1-\delta_{i,j})/(z_i - z_j), and the vector S = [S_1, \ldots, S_n] \in \mathbb{C}^n.

We can compute this double sum for all the \xi_i's as the matrix product:

\frac{1}{4\pi^2}C_{yx} \; \text{Diagonal}(S) \; \overline{C_{xx}} \; \overline{S}.

This product can be efficiently computed by applying twice the fast multipole method. Do you know if there are â€śdouble fast multipoleâ€ť methods that perform the double summation at once?

Also, which fast multipole Julia packages would you recommend?