instruction stringlengths 43 28.1k |
|---|
I've converted a MATLAB code to C++ to speed it up, using the Armadillo library to handle matrix operations in C++, but surprisingly it is 10 times slower than the MATLAB code!
So I test the Armadillo library to see if it's the cause. The below code is a simple test code that initializes two matrices, adds them togethe... |
Suppose I have a spherical object projected onto a discrete square mesh. The dicretised circle can be represented by filling a logical matrix such that voxels in the interior of the sphere are filled with 1's where outside of the sphere the voxels are filled with 0's. Calculating the volume is easy as you simply add up... |
I have the following problem:
In the space $E=\{1, 2, \dots, N_x\} \times \{1, 2, \dots, N_y\}$, I want to define $N_R$ rectangles $R_k=\{x_k^0, \dots, x_k^1\}\times\{y_k^0, \dots, y_k^1\}$ which cover part of my space $E$.
The total size of the union of all rectangles has a upper bound $C$ (constraint i). And the re... |
I am using the METIS to partition a matrix and then using domain decomposition to solve the subdomains in parallel using the Restricted Additive Schwarz method.
I am currently trying to solve some SPD matrices. Using METIS' METIS_PartGraphKway(...), I partition the matrix. I think this function minimizes edge cuts. I... |
I'm trying to convert and process GrADS (grib) files into netcdf files. The files have values every 3 hours (2890 per year), 12 z levels, 120 variables, 241 columns and 236 rows. The data is almost 80 gb per year and I have to process a total of 50 years.
Before converting into netcdf I'm trying to calculate daily aver... |
I am using an HPC cluster to launch parallel simulations. At the moment, there are 48 free cores over 4 nodes but not each node do not have the same number of free cores. The distribution is something like this :
node1: 8 cores free
node2: 8 cores free
node3: 8 cores free
node4: 24 cores free
I want to utilize all of t... |
I have a system of coupled nonlinear PDEs that I cannot figure out how to solve in a smart way using FDM, so I was hoping someone here might have a clue.
The equations go as:
\begin{align*}
\frac{1}{n_\alpha}\frac{\partial}{\partial t} \left[n_\alpha-A_\alpha\left(\nabla^2\phi+\nabla^2 p_\alpha\right) \right] &=\text{R... |
INTRO
Within the last 5 days I was able to generate a block structured Cartesian grid
generation system with a combination of Fortran,C++ and Python.
I am running intersection tests of the imported geometry with the bounding box
it is surrounded by and if the intersection test succeeds then I am subdividing the pare... |
I'm in the process of constructing an algorithm which computes the Voronoi diagram of a set of points, but I now need a method to decompose each Voronoi cell into simplices. The information we have is:
The vertices of the polytope
The faces of the polytope and their vertices
The location of a central point
The radial ... |
I am having trouble with a C program that uses the function dsysv from LAPACK. Everything compiles and works without any errors, my only problem is, that the routine doesn't chance any of the arrays it is supposed to.
The code (only hardcode for test purposes):
#include <iostream>
using namespace std;
extern "C" {
ext... |
I often see the terms "low arithmetic intensity" and "memory-bound" associated with sparse matrix operations. However, my intuition is that a sparse matrix operation should be less memory-bound, if anything. After all, for a highly sparse matrix, you only have to transfer a fraction of the data required for a dense mat... |
I have a system of conservation laws of the form
$$ \frac{\partial \mathbf{q}}{\partial t} + \nabla \cdot \mathbf{F}\!\left(\mathbf{q}\right) = 0 $$
I want to use finite elements to solve this system. As an initial choice, I am using Legendre polynomials $\phi$ for my function basis. Let $j$ be a polynomial index. If I... |
Problem description
Given data at many time instance $t$,
$$\min _{\alpha, \Lambda, \beta} \lVert y(t) - \alpha e^{\Lambda t} \beta \rVert_F$$
with $$ \lVert \alpha \rVert_2^F = 1 $$
where $y(t) \in \mathbb{R}^{n \times M}$, $\Lambda \in \mathbb{R}^{r\times r}$ is a diagonal matrix, $\alpha \in \mathbb{R}^{n \times r}$... |
I am looking into the four-point bend test, such as one in this YouTube video.
Sample screenshot from the video illustrating the problem:
I am a little confused as to how the loads are prescribed numerically as boundary conditions. My intuition tells me that the object has to have a Dirichlet BC somewhere. But it appe... |
Take the system $$A^TCAx=b$$
where $$A\in\mathbb{R}^{n\times m},\;C\in\mathbb{R}^{n\times n},\;x,b\in\mathbb{R}^{m}, \;m\leq n$$ and $$A^TA=I$$ and $$Cy=d$$ can be solved efficiently in general (specifically $C$ is SPD and it/it's inverse already has Cholesky decomposition). Clearly, if $m\ll n$, then it probably best ... |
I am trying to model 2D thermal expansion of a square area inside another square using FEATool. I have simulated plane strain by incorporating forces pointing along the $[1 \,\,\, -1]^T$ direction inside the smaller square . However, what I really want to simulate is this "shrinking" of the material as a thermal expans... |
If we have a continuous time state-equation,
$$ \dot{x}(t) = A x(t) + B u(t)$$
where $A \in \mathbb{R}^{n \times n}, x \in \mathbb{R}^{n\times1}, B \in \mathbb{R}^{n \times m}, u \in \mathbb{R}^{m \times 1}$, the analytical solution is obtained as
$$x(t) = e^{A t} x(0) + \int_0^t e^{A(t-\tau)}B u(\tau)\, d\tau$$
Conv... |
Currently I am facing the problem to solve numerically the following equation for a double well harmonic potential:
$iℏ\frac{\partial}{\partial t}ψ(x,t)=−\frac{ℏ}{2m}\frac{\partial ^2}{∂x^2}ψ(x,t)+V(x,t)ψ(x,t)$
where
$V(x,t)=\frac{mω^2_0}{2}[a(t)x^4−b(t)x^2]$
Where both $a(t)$ and $b(t)$ are of the form $\frac{1}{2*\sq... |
Is there any way to multiply a symmetric matrix by a dense one in armadillo(and use the fact that we have a symmetric matrix)? I know about DSYMM Routine in BLAS,but the matrices I'm dealing with are mat type(they are not arrays),So I wonder if there is some thing in armadillo using DSYMM Routine from BLAS .
I couldn't... |
The perspective of a function $f : \mathbb{R}^n \to \mathbb{R}$ is the function $g: \mathbb{R}^n \times \mathbb{R} \to \mathbb{R}$ where $g$ is defined as $$g(x,t) = tf(x/t)$$ with $$\mathbf{\text{dom}}\, g = \{(x, t) : x/t \in \mathbf{\text{dom}}\, f, \,t > 0\}.$$
If I'm modeling a convex constraint of the form $g(x,t... |
I need to solve the following problem:
$$ \begin{cases}
\dot{\vec{x(t)}} = A\vec{x(t)} + u(t)D\vec{x(t)} + u(t)\vec{b}, & x \in (0, T), \\
\vec{x(0)} = \vec{0},
\end{cases}$$
where $u(t)$ is known function, $A$ and $D$ are known constant matrices and $b$ is known constant vector.
I solve this problem with explicit Eule... |
I am translating some Matlab code into Python and I having some problems regarding matrix multiplication accuracy. Assuming we have following data:
A: 6x6 matrix
B: 5x5 matrix
C: 2x2 matrix
D: 5x5 matrix
E: 6x5 matrix
In Matlab, my operation looks as follows:
R1 = A * (-( B*C(1,1) + D*C(2,1) ) * E.').'
Previous set o... |
Consider the Schroedinger equation
$$\left(-\frac12\frac{\partial^2}{\partial x^2} + V(x) \right) \psi(x) = E \psi(x)$$
The usual way to solve it is to introduce a discretization of $\psi(x)$. This yields an eigenvalue problem which can be solved by standard methods from linear algebra. When using a discretization that... |
I have to diagonalize, within a Fortran-written code, a block tridiagonal Toeplitz Hermitian matrix, e.g.
$$
\left[
\begin{array}{ccccc}
\ddots & \hat{A} & & & \\
\hat{A}^\dagger & \hat{B} & \hat{A} & & \\
& \hat{A}^\dagger & \hat{B} & \hat{A} & \\
& & \hat{A}^\dagger & \hat{B} & \hat{A} \\
& & & \hat{A}^\dagger & \... |
This concerns algorithms for searching for the minimum of a continuous unidimensional unimodal function. The simplest method is three points, and bi-sectioning. The golden-section search seems more natural. Although Brent seems a little better yet.
I am trying to find a reference as to how much more efficient these ... |
This is really a general question, but my interest is primarily for structural mechanics.
Say you are modeling an elastic solid material that is orthotropic. You have the orthotropic properties (elastic modulus in 3 directions, the 6 poissons ratios, and the shear modulus in the 3 directions), but you only have a code ... |
I'm a high-schooler building a small vehicle for an independent study. I've had finite element modelling recommended to me as a way to save time during the design process, and I'd like to try it out. Unfortunately, the person who recommended FEM to me claims his knowledge is quite outdated. I have some coding experienc... |
Suppose we have a primal problem
$$
p^{*}=\min_x f(x), \\\text{s.t.}~~ h_i(x) \leq 0,
$$
where $f(.)$ and $h_i(.)$ are possibly non-convex.
Then its Lagrangian is
$$\mathcal{L}(x,z_i)= f(x) + \sum_i z_i h_i(x)$$
and the dual problem is
$$d^{*}=\max_{z_i\geq 0} \min_x \mathcal{L}(x,z_i)$$
Now it is well-known that $p^{... |
I have implemented BFGS myself from scratch in order to solve minimization problems. Part of BFGS, as I understand it, is that the approximation to the Hessian is supposed to be positive definite, which means it is supposed to be invertible. I have been following the algorithm outlined here: https://en.wikipedia.org... |
I get following error after implementing the attached code.
Error Message
"fmincon stopped because the size of the current step is less than
the default value of the step size tolerance but constraints are not
satisfied to within the selected value of the constraint tolerance."
Code:
rho = (1/3)*eye(3);
v1 = sdpva... |
Simple hard-sphere dynamical systems can exhibit chaotic dynamics. Due to finite-precision arithmetic when implemented on a computer, the presence of chaos implies that for a given set of initial data, simulations of such systems on different machines or run with different arithmetic precisions can yield wildly differe... |
I am trying to use CSDP and am struggling with it. Consider, for example, the following semidefinite program
$$\begin{array}{ll} \text{minimize} & 0\\ \text{subject to} & Q - A' Q A - \varepsilon I \succeq 0\\ & Q \succ 0\end{array}$$
where $A$ is a given matrix with spectral radius $\rho(A) < 1$. I need a Lyapunov fun... |
I am xposting this from my original stackoverflow question where I was presented with a coding challenge that I have been able to narrow down extensively and I think it lies with Euler's Method.
Here's my initial post with my previous assumptions.
It has been a while since I took differential equations and linear alge... |
I asked this question previously on the physics board (LINK: https://physics.stackexchange.com/questions/404539/linear-elasticity-governing-equation), but I thought I'd post it here and see if anyone else can offer me another perspective since there seem to be multiple users on here familiar with modeling structural me... |
I'm writing some code to solve problems in nonlinear elasticity using finite element methods. I have been following Bathe's book but I am having trouble with some nagging details.
My question is related to which configuration variables to use for calculating different quantities. I'm working on static problems in the... |
I am trying to compute the CDF of a Multivariate Cumulative Normal Distribution in the 1000th dimension (I have a 1000 vectors and their covariance matrix). I haven't been able to find a fast way to compute this, numpy and scipy all take take too long.
Are there any libraries (platform and language doesn't matter) that... |
I am new to numerical linear algebra, so i came to know that condition number in 2-norm case will be ratio of largest to smallest singular value.
Another concept "Nearness To Singularity" is measured using this number being large.
But consider the case where singular values are close to 0 but smallest and largest singu... |
I would like to find the smallest real root of a 1-D real-valued function $f(x)$ on the domain $x\in [0,\infty)$. In this problem, I can make the following guarantees on $f$:
$f$ does have a root at some finite, positive $x$.
$f$ is differentiable at all finite, positive $x$ and $f'(x)$ is either known or can be appro... |
Given indices $i,j$ s.t. $0\leq i \leq j <n$, the function $f(i,j)=i+j(j+1)/2$ maps 2d indices to linear indices in column major order. What is the fastest way to invert this function? My first inclination is binary search on a list of the first $n$ triangle numbers but is there a faster (perhaps $O(1)$, other than a l... |
I'm trying to solve physical problem in quantum mechanics of helium atoms, the solution require numerical integration over 2 variables. However when i'm trying to run the next code
e = 1.6e-19;
eps0 = 8.85e-12;
a0 = 0.53e-10;
c = e^2/(4*pi*eps0);
psi1 =@(r) ((2^1.5)/(sqrt(pi)*a0^1.5))*exp(-2*r/a0);
psi2 =@(r) ((2^1.5)/... |
I'd like to know if is possible to make a Von Neumann's stability analysis on an system of coupled equations, featuring quadratics:
$$\begin{aligned}
\frac{\partial u_1}{\partial t}&=D_1\Delta u_1 - s_1\left(\left(\frac{\nabla u}{(k+a)^2}-2u\frac{\nabla a}{(k+a)^3}\right)\nabla(a) + \frac{u}{(k+a)^2}\left(\Delta(a) + 2... |
In $\mathbb{R}^n$, I would like to solve a Poisson equation (given $f$, solve for $u$):
$$\nabla^2 u = f$$
assuming Neumann boundary condition (i.e. $\partial u = 0$ at boundaries).
I solved it in spectral domain. Using the 3x3 Laplacian stencil (so Neumann boundary = symmetric boundary), DCT & IDCT will be good. So th... |
There is an article describing how to detect a pupil from an eye photo.
A.-H. Javadi, Z. Hakimi, M. Barati, V. Walsh, and L. Tcheang, "SET: a pupil detection method using sinusoidal approximation," Front. Neuroeng., vol. 8, pp. 1–10, Apr. 2015
On the 4th step of pupil detection they use
Decomposition of each segmen... |
Primal-dual interior point methods for linear programming require interior primal and dual starting points. I am looking for a good reference containing a description for modifying a given linear program (without solving an auxiliary LP and without doubling the number of variables or constraints) to one with a primal a... |
I am trying to solve a non-linear time-dependent heat equation
$$\partial_tT=\nabla \left(k_T(T)\nabla T\right) + f$$
using the galerkin method, with neumann boundary conditions. For linearization of the nonlinear part I am using the newton approach. The source term $f$ always stays positive, thus I would expect that ... |
Focusing on following least squares problem:
$$\min\limits_{V} \lVert Z - WV \rVert _{_F}^2$$
$$Z∈{R}^{m\times n},\quad W∈{R}^{m\times k},\quad V∈{R}^{k\times n},\quad k\lt m\lt n $$
This problem can be easily solved given $Z$ and $W$. I assume the solution of this problem as $\overline{V}$.
My question is that, how ... |
How to use PETSc SNES (scalable nonlinear equation solver), when the solution is not a vector but a user defined state?
I am implementing a non-linear mechanics problem (geometrically exact shell 5-paramter model), the update
$$X^{(k+1)} = X^{(k)} + \Delta_X$$
is not additive and requires the use of exponential maps... |
In this code, all processes post a barrier, sleep a while for good measure, then first Test and then Wait for the barrier. The Test says no and the wait succeeds. A test should be like a non-blocking wait, so it should succeed. What am I missing?
printf("[%d] posting barrier, then sleeping\n",procid);
MPI_Request f... |
I'm interested in numerically diagonalizing a class of structured, symmetric eigenvalue problems with potentially extremely small eigenvalue gaps. The question I have is how to design a numerically stable way to get the eigenvalues and eigenvectors.
While usually small gaps destroy precision in numerical eigenproblems,... |
I need your help to solve a problem I'm working on for school.
My goal is to approximate the coefficients of a weight matrix so that they check particular properties.
So I have $W$ the weight matrix of my assets and $\Omega$ the covariance matrix of these assets. The global risk of my portfolio, $\sigma$, is defined by... |
I am trying to find interatomic distance considering periodic boundary conditions for hexagon cubic cells (graphite). I tried to follow the answers to these two questions here but am unable to get the right results
periodic boundary conditions for triclinic box
Minimum image convention for triclinic unit cell
My code, ... |
I have a code that uses both spatial and time discretization/integration. For convergence analysis, I am wondering how one would test the order of accuracy of their ${time}$ integration scheme? I assume you would have to isolate the time discretization from the spatial discretization somehow, but I am not sure how this... |
I am interested in solving ODE systems of the form
\begin{align}
\frac{\partial \vec{u}}{\partial t} = F(\vec{u})
\end{align}
where $F$ is a nonlinear operator, $\vec{u}$ is a vector valued function of $t$, and we have initial conditions $\vec{u}(0) = \vec{u}_0$. I am specifically interested in equations of this form ... |
W have a complicated structure on which we do some FEM calculations regarding electrical potentials and heat distribution. The equations have the form
$\nabla\kappa\nabla u = f + g\rvert_{N}$
where $u$ is the temperature or electrical potential, $\kappa$ is a material parameter and $f$ and $g$ are heat or current densi... |
This is my first post in this forum so please forgive me if it is not the way it should be.
My problem is about implementing "Boole's rule" into python. I have succesfully implementet trapezoidal and simpsons, but there is a difference in the results between the first 2 and Boole's rule when I calculate an integral. T... |
I’m trying to figure out how to model the rings of Saturn using a particle system for a gravity simulator that I’m making. Using the code below, I’ve managed to create a, if not perfect, decent ring that rotates around Saturn under the force of the gravity of Saturn and its moons. However, my ring has an axial tilt of ... |
I'm trying to solve a nonlinear eigenvalue problem in MATLAB, still without success. It's a problem about graphene plasmonics.
The nonlinear eigenvalue problem is given below:
\begin{equation}
\frac{\epsilon_1}{\kappa_{1||n}}E_{x||n}+\frac{\epsilon_2}{\kappa_{2||n}}E_{x||n}+ \frac{i}{\omega \epsilon_0} \sum_{p=-M}^{M}\... |
Using sine and cosine transforms to solve Poisson's equation with Dirichlet boundary conditions seem quite standard nowadays (see, e.g., here or Table 2 in this paper). In the case of Poisson's equation, the multiplication with $-k^2$ preserves the symmetry of the Fourier coefficients such that the same transform can b... |
I need to conduct some FEM calculations and I am wondering whether parallelization would be a good idea.
The trouble is that my model is not especially large so it takes few seconds to solve a single problem on my laptop.
However I need to do optimization (there's a lot of different geometric parameters to test), so I... |
I was reading a book about Matlab ("Accelerating Matlab with GPU computing - A Primer with Examples" by Jung Suh and Youngming Kim, 2013. Chapter 1.7 Examples).
I read an example where it said that:
by using elemental calculation, matrix calculation, and function call
instead of for loops, the speed can be dramati... |
I am looking to solve 1D burgers equation with various random initial conditions. What is the best algorithm to find the exact solution?
One method that is covered in literature is the equal area principle (R. J. LeVeque, Numerical Methods for Conservation Laws). Is this the standard procedure employed in numerics pap... |
I am writing a finite element code for structural analysis, and I want to implement rigid bodies. How is this usually done? Say that I have a square mesh, with one half of the mesh being defined rigid and the other deformable. How are the forces on the "boundary-nodes" (the nodes shared between the deformable and rigid... |
I am trying to build a simple solver for the incompressible fluid in a periodic box to learn the spectral method. I am following the textbook (Peyret R. Spectral methods for incompressible viscous flow[M]. Springer Science & Business Media, 2013.) the author presents a Fourier method for the calculation of spatially pe... |
I want to calculate the following expression
$$
\exp(-i\Delta t\mathbf{H})
$$
where $\mathbf{H}\in\mathbb{C}^{n\times n}$ is a hermitian matrix. Since I have a highly optimized eigensolver in the code I'm working with (ScaLAPACK & Fortran 90) I was thinking about utilizing it by calculating the matrix exponential with ... |
Suppose I have two images that contain many objects that are identical, or nearly so. Specifically, say the objects are shifted and scaled, but by differing amounts, from one image to the other. Is there an efficient algorithm for matching the objects?
The prototypical example would be subsequent images from a video s... |
I am trying to solve an equation in Python. Basically what I want to do is to solve the equation:
$$
\frac{1}{x^2}\frac{d}{dx}\left(Gam \frac{dL}{dx}\right)+L\left(\frac{a^2x^2}{Gam}-m^2\right)=0
$$
This is the Klein-Gordon equation for a massive scalar field in a Schwarzschild spacetime. We know $m$ and $Gam=x^2-2x$. ... |
I am currently studying eigenvalue problems. I already worked through the minimax-principles and seen why $\lambda_{h, m} \geq \lambda_m$, when comparing the eigenvalues of a discretization and the continuous ones.
The next lemma tries to establish conditions when we can get convergence between these two, finally arriv... |
Consider an $M\times N$ grid with periodicity in both dimensions upon which I want to do some local stencil-like computations using distributed-memory parallelism (MPI). I have two options for decomposing this problem:
(1) split the grid along one dimension so that each of the $P$ processes gets about $M/P\times N$ or ... |
I need to compute a bilinear form for a set of left and right vectors
$$ w_k = \sum_{i,j} V_{ik}^*A_{ij}U_{jk},$$
where $A_{ij}\in\mathbb{R}$ and $U_{jk}, V_{ik} \in \mathbb{C}$ (Assume that all the matrix sizes make sense). This can be obtained in one line of MATLAB code
$$ \texttt{w=diag(V'*A*U);} $$
or
$$ \texttt{w=... |
Suppose $F(u,v)$ is the center frequency Fourier representation of some $f(x,y)$ in 2D.
$$
f(x,y)=\int\limits_{-\infty}^{\infty}\int\limits_{-\infty}^{\infty}F(u,v)e^{2\pi i (xu+yv)}dudv
$$
In principle for the same $f(x,y)$, the representation could also be $F(u-u_0, v-v_0)$, where $u_0$ and $v_0$ are arbitrarily shif... |
I have a non-linear least-squares problem to solve and with my current modeling, the solver is either very slow or does not converge to a correct solution.
For the problem, I need to minimize energy on a set of triangles, which is defined by
$$\sum_f E_d(f) + \sum_e E_s(e)$$
with faces given by their vertices $f=((u_1,... |
How could I go about solving the continuity equation below in 2D?
$$\frac{\partial \rho}{\partial t} + \nabla \cdot \left(\rho u\right)=0$$
I saw that a similar question was posted here: A good finite difference for the continuity equation, but that only discussed the 1-D case.
In it, one of the answers defines incomi... |
Background
We know how to solve the following minimization problem
$$
\min_{X} \lVert AX - B \rVert_F^2
$$
But what about the extended version?
$$
\min_{X} \lVert A
\begin{bmatrix}
X & X^2
\end{bmatrix} - \begin{bmatrix}
B_1 & B_2
\end{bmatrix} \rVert_F^2
$$
Is there any analytical solution to this? Or we have to use... |
I am writing a 3d linear finite element code to solve the standard linear elasticity equation on a tetrahedron mesh of a gearbox. Notice that, the two rectangular plates above the gearbox are fixed, which means their displacement are zeros.
The standard linear elasticity model is
$$
-\mu\Delta \bf u - (\lambda + \mu)... |
My situation.
I have a function of a complex variable $f(z)$ defined through a complicated integral. What I am interested in is the value of this function on the imaginary axis. I have numerical access to this function on the following ribbon: $z=(x,y)\in (-\infty,\infty)\times[-1,1]$. Formally the integral expression ... |
Recently, I started to develop some codes that use NURBS (general things I intend to use/already using: spline generation, interpolation, grids, isolines, closest-point find, and many others), both for curves and surfaces.
The first practical problem I want to solve is to find a NURBS surface given a set of B-splines ... |
I am trying to solve a boundary value problem with Python. I have been using scipy.integrate.solve_bvp but the result that it is giving me is completely wrong. Basically my code is as follows:
from IPython import get_ipython
get_ipython().magic('reset -sf')
import numpy as np
import matplotlib.pyplot as plt
from math ... |
In a FEM mesh, does the order of node numbering in an element has any importance?
I'm currently trying to code my own FEM solver, which seems to work fine with quadrilateral elements, however I'm having difficulties whith triangular meshes, which yield different results when renumbering the nodes in the elements.
For e... |
According to the equation
$$ \frac{\partial y}{\partial t} = -a\frac{\partial y}{\partial x} $$
I simulated this in python. I used center differentiation, and I determined step size based on Von-Neumann stability criterion for a linear equation
$ \Delta t = \frac{\Delta x^2}{2a}$ .
This is what I get:https://gyazo.c... |
The Green500 List lists the top 500 most energy efficient supercomputers.
My question is, what is the minimum FLOPS that computers need to be considered for the Green500 list?
Do they just take the TOP500 list and rank them according to FLOPS/watt (cut-off = FLOPS of the 500th computer of TOP500)? Or is there some othe... |
I need to solve a least squares problem that takes the following form:
$$p = \arg \min_{x}\Vert J V x - y \Vert_2, $$
where $J \in \mathbb{R}^{N \times N}$ is a general dense matrix, and $V \in \mathbb{R}^{N \times m}$ is a block-diagonal matrix with $m << N$ (that is, this is a typical overdetermined least-squares pro... |
I'd like to know whether there are any publicly available tools for solving QCQP with complex variables (and constraints therefore expressed through Hermitian matrices). What I have found so far is the following:
A recently created CVXPY package for QCQP with real variables, as well as a paper mentioning the ability o... |
this might be a silly question, but if we’re trying to numerically solve Hamilton’s equations with some discrete scheme, sometimes when the scheme preserves phase space volume (Hamilton’s eqns are understood to be some flow on this phase space) it leads to stability, even if the algorithm isn’t symplectic (for example ... |
I want to know whether the equation : a-b+b = a is always true for a, b belongs to double precision floating-point number and |a|>=|b|.
If the equation is true, how can I proof it?
If not, what precondition can make the equation right?
A counterexample shows the equation is not true, so I now want to know,
the inequal... |
I'm hoping someone can recommend recent literature concerning homotopy methods for solving systems of nonlinear equations. Already by the time of Layne Watson's 1986 paper there were a lot of methods, and I'm sure there have been developments since then as well as practical shifts in the field due to hardware advancem... |
What are the main differences between finite element and finite difference approach for incompressible flow simulations? I have a vague idea about how FE methods rely on minimizing the residual over elements and FD methods consider Taylor series approximation of different terms in NS equations.
Based on my little expe... |
In a posteriori error control for solving ODEs, one typically computes two different approximate solutions, one of which being "more accurate" and one of which being "less accurate". If $y_q^{n+1}$ is the more accurate approximation to the solution at the next time step $y^{n+1}$, and $y_p^{n+1}$ is the less accurate a... |
I am using a central-difference scheme to solve the eigenvalue problem
$$\frac{d^2}{dx^2}u = \lambda u$$
on a unit interval with periodic boundary conditions. My understanding is the eigenvectors $u_i$ have the analytic form
$$u_i(x) = e^{in\pi x}$$
I know that, for example, with dirichlet boundary conditions $u_0 = u_... |
I have a set of matrices $\{(A_i,D_i)\}$ for $i\in\{1,\ldots,n\}$, where:
Each $D_j\in\mathbb{R}^{S\times S}$ is diagonal, and every entry on the main diagonal is non-negative.
Each $A_j\in\mathbb{R}^{m\times m}$ is symmetric and positive definite, with every entry being non-negative.
I want to find a matrix $B\in\ma... |
I am trying to take a Fourier transform of a density field estimated from mock galaxy survey catalogs.
Basically, you start with a list of galaxy positions, then you bin these positions over some grid spacing, getting an array with a weight for each grid position in the relevant volume of space.
Because I am trying to ... |
By a barycentric rational interpolant we understand a function of the form
\begin{align*}
r(t) := \frac{\sum_{i=0}^{n-1} \frac{w_i y_i}{t-t_i} }{ \sum_{i=0}^{n-1} \frac{w_i}{t-t_i}}
\end{align*}
In Schneider and Werner, (proposition 12) a stable algorithm for computation of the derivatives of $r^{(k)}$ is presented. (T... |
Let $A$ be a finite (and small-ish) set of positive real numbers and 0. Let $B$ be a subset of $\mathbb N^0$, up to some (small-ish) bound.
I have a function $f(t)$, $A \rightarrow B$ that is strictly monotonically increasing. It is $f(0) = 0$ and $f$ shall cover all values of its codomain $B$.
In plain English: $f$ st... |
I'm working on a fun open-source project to calculate the trajectories of objects near black holes. This is obviously not the first time anyone has done this sort of thing, but I have some design goals that have led me to roll my own solution. (These considerations are spelled out in the project's README file, but brie... |
Imagine I want to consider the temperature for a process given several input varibales. The temperature can be anywhere between 400 and 500 K. Consider I have experimental data to train the network and then I want to predict the temperature for a test point.
As I understand the theory of NN activation function are need... |
I am trying to solve an APSP (All-Pair Shortest Path) problem on a weighted graph.
This graph is actually a 1, 2 or 3 dimensional grid, and the weights on each edge represent the distance between its two vertices.
What I want to have is the geodesic graph distance (shortest path through the graph), for every pair of ve... |
With the guru interfaces of FFTW, I can apply transforms only to parts of a multidimensional array by modifying the fftw_iodim parameter (e.g., with fftw_plan_guru_r2r(...)). Unfortunately, there seems to be no MPI interface with the same arguments (see, e.g., fftw_mpi_plan_r2r(...)). Does anybody know how I could appl... |
I'm trying to understand the staircase map. Look at this map from the circle to itself:
$$ x \stackrel{F}{\mapsto} \big[\omega + x + \tfrac{\epsilon}{2\pi} \sin (2\pi x) \big] \pmod 1 $$
Such a map arises when applying Euler's method to solve a differential equation. Then the rotation number as a function of $\omega$... |
In the book
A Multigrid Tutorial - Briggs, Henson. McCormick
in the beginning of Chapter 3, it is mentioned that
...because the convergence factor behaves as 1-$O(h^{2})$, the coarse grid will have a marginally improved convergence rate...
Here, $h$ is the mesh spacing (say from Finite Difference Discretization).... |
I have to deal with the following problem in my research:
$$\left[\frac{1}{D}F_{x}\right]_{x} + \frac{f D_{x}}{c D^{2}}F = 0$$
with boundary conditions
$$F(0) = 0$$
$$F_{x}(L) = 0$$
where $f$ is a known constant and $D(x)$ is a known function of $x$. I should clarify that $D(x)$ is known numerically for all $x$ (I h... |
I am working on an XY model and I'm trying to calculate the magnetization and direction for an anti-ferromagnetic (AF) system. So I have a collection of spins in the $XY$ plane represented as vectors $s$ and when cooled then they will order (anti-align). The magnetization is normally calculated as
$$M = \frac{1}{N}\s... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.