instruction stringlengths 43 28.1k |
|---|
Are there any tools specifically designed for compressing floating point scientific data?
If a function is smooth, there's obviously a lot of correlation between the numbers representing that function, so the data should compress well. Zipping/gzipping binary floating point data doesn't compress it that well though. ... |
I use Intel MKL for BLAS and use the Intel MKL Link Line Advisor for help with the command line options.
The advisor provides options for Static, Dynamic and Single Dynamic Library. What do these terms mean?
There have been numerous posts on SO regarding this but all of them have been focused on developing softwares ra... |
(Not sure if that's the right SX site? I don't need actual code, so…)
I'm looking for an algorithm that generates all cartesian products for a list of sets, but skips tuples that are just rotations of previously issued tuples in a smart way.
Here, $(a_0,\dotsc,a_n)$ is a rotation of $(b_0,\dotsc,b_n)$ iff $\exists x : ... |
I'm working on a header-only matrix library to provide some reasonable degree of linear algebra capability in as simple a package as possible, and I'm trying to survey what the current state of the art is re: computing the SVD of a complex matrix.
I'm doing a two-phase decomposition, bidiagonalization followed by sin... |
EDIT: I am testing if any eigenvalues have a magnitude of one or greater.
I need to find the largest absolute eigenvalue of a large sparse, non-symmetric matrix.
I have been using R's eigen() function, which uses the QR algo from either EISPACK or LAPACK to find all eigenvalues and then I use abs() to get the absolute... |
After going to all possible "Introductions" to ScaLapack, I still can't understand how to carry out a simple PDGEMV operation using it.
Here is what I must do :
I have to generate a matrix using
do i=1,n
x(i) = i*i*1.0D+00
do j=1,n
A(i,j) = (i+j)*j*1.00D+00
end do
end do
and then simply multiply Matrix A b... |
What are all of the different ways to derive the partial charges, van der Waals interactions, bond lengths, etc. of an amino acid (in other words, all of the parameters that could be used in a molecular mechanics force field or other related method - such as a Poisson-Boltzmann equation solver)? I'm especially interest... |
I know that gnuplot's epslatex terminal can display superscipts and subscripts in titles and label axes. Is this also possible when using gnuplot's png terminal?
If so, how does one do this?
|
I've got a system of ordinary differential equations - 7 equations, and ~30 parameters governing their behavior as part of a mathematical model of disease transmission. I'd like to find the steady states for those equations Changing dx/dt = rest of the equation to 0 = equation for each of the equations makes it a strai... |
Consider an $n \times n$ real, time-dependent matrix $A(t)$ such that $A(t) = A(t)^{T} > 0$ and $A(t)$ is continuous on $[a,b]$. Then it is posible to specify a matrix $S(t) \in SO(n)$ such that $S(t)A(t)S^{T}(t) = \Lambda(t)$, where $\Lambda$ is a diagonal matrix. For instance, we can obtain such $S(t)$ using Jacobi r... |
I write codes in Fortran and C for various matrix algorithms. However, when I profile my codes using VTune, I usually run into some terminology that I cannot fully appreciate. Is there a good resource for learning profiling from scratch to a fairly advanced level?
Although I am looking forward to profiling numerical co... |
Suppose a square, real and symmetric matrix $G\in\mathbb{R}^{n\times n}$ is given, and it is known to have one zero eigenvalue associated with all ones eigenvector, $1_n$. I'm aware that the (possibly) negative spectrum could be shifted to non-negative,
$$(G + c\cdot I)u = Gu + c\cdot Iu = \lambda\cdot u + c\cdot u = (... |
Consider an equation $S(t)b(t) = a$, where $a, b(t) \in S^{n-1}$ are given and the vector $b(t)$ is continuous, i.e. its endpoint traces a continuous curve on the unit sphere. The task is to find continuous solution $S(t) \in SO(n)$ (numerically). Consider a time net $t_0 < ... < t_n$.
In 2D case we can count the ang... |
I wrote a function to read in the runtime parameters my program takes. This function is in a different file than my main program; the two object files are linked after compilation.
When I compile the file that contains the function I use to read in parameters, I get the following warning:
io.c(43): warning #120: return... |
as the title suggests I'm trying to compute the integral of a compactly supported function (Wendland's quintic polynomial) on a triangle. Notice, that the center of the function is somewhere in 3-D space. I integrate this function on an arbitrary, but small triangle ($area < \frac{(radius/4)^2}{2}$). I am currently usi... |
I'm doing a Lanczos diagonalization of a large sparse matrix (~2 million elements). Almost all of the steps in the Lanzcos algorithm are done in parallel on the GPU, except for diagonalizing the Lanczos matrix to check for convergence. For that, I've been using the TQLI algorithm from Numerical Recipes. Are there metho... |
Sorry for the long post but I wanted to include everything that I thought was relevant in the first go.
What I want
I am implementing a parallel version of Krylov Subspace Methods for Dense Matrices. Mainly GMRES, QMR and CG. I realized (after profiling) that my DGEMV routine was pathetic. So I decided to concentrate o... |
Many computational scientists that I know of, including myself for example, are not computer scientists. As such they are often not very well aware more advanced techniques in OOP. On the other hand, most of advanced programmers are not computational scientists. They may not be well aware of what OOP features are essen... |
As I see it, there are 3 ways to solve unstructured dense system of equations: GMRES, QMR and LU.
Has anyone done a comparison for these three? As far as I know, LU is the preferred choice and it is fairly popular for solving unstructured systems. I am trying to implement GMRES and QMR as a substitute.
EDIT: To limit s... |
I am trying to find the minimum of the function using GNU scientific library, package Multidimensional Minimization. The method I am using is Broyden-Fletcher-Goldfarb-Shanno (BFGS) algorithm which is implemented in function
gsl_multimin_fdfminimizer_vector_bfgs2
Unfortunately, after the first iteration with
gsl_mult... |
The C++ language provides generic programming and metaprogramming through templates. These techniques have found their way into many large-scale scientific computing packages (e.g., MPQC, LAMMPS, CGAL, Trilinos). But what have they actually contributed to scientific computing in value that goes beyond non-generic, non-... |
What are recommended ways of doing nonlinear least squares,
min $\sum err_i(p)^2$,
with box constraints $lo_j <= p_j <= hi_j$ ?
It seems to me (fools rush in) that one could
make the box constraints quadratic, and minimize
$$ \sum_i err_i(p)^2 + C * \sum_j tub( p_j, lo_j, hi_j )^2 $$
where $tub( x, lo, hi )$ is the "tu... |
I managed to reduce certain computational problem to the Gauss-Seidel solution of the following linear system: $$Ax=Ly,$$ where $A, L\in\mathbb{R}^{n\times n}$ are weighted Laplacian matrices (symmetric, positive semi-definite; negative off-diagonal entries, with rows(collumns) summing (in absolute values) to positive ... |
In my master thesis I used an Algorithm called Approximative Dynamic Programming [1] to solve equations of the form
$$
\max_{\pi}\mathbb{E}^{\pi}\left\{\sum_{t=0}^{T}\gamma^tC_t^{\pi}(S_t,A_t^{\pi}(S_t))\right\}.
$$
It uses Monte-Carlo sampling and an approximation $\overline{V}_t$ of the value function to come aroun... |
What methods are suggested to solve problems of the form $\min || {A} x - y ||_k$, subject to $x^T P x \leq c$, and/or $x^T Q x = d$?
|
I often find myself writing very similar code for one, two, and three dimensional versions of a given operation/algorithm. Maintaining all of these versions can become tedious. Simple code generation works fairly well, but it seems as thought there must be a better way.
Is there a relatively simple way to write an op... |
I asked this question on stackoverflow a few weeks ago, but have not gotten a useable answer, even after a colleague added a 150pt bounty.
Is it possible to query the doi for each record in a table of citations?
I have a table (csv version) that includes the last name of the first author, the title, journal, year, and ... |
I currently trying to cheaply compute a good rank estimate for a matrix $A$. Therefore I compute a columnt pivoting QR decompostion using
[Q,R,E]=qr(A)
in Matlab. I estimate the rank of $A$ using
tol = size(A,n)*eps*norm(A,'fro');
r = sum(abs(diag(R))>tol)
This works fine and a plot over all diagonal entries of R ... |
I'm working on a problem that can be parallelized by using a single mpi_allgather operation or one mpi_scatter and one mpi_gather operation. These operations are called within a while loop, so they may be called many times.
In the implementation with an MPI_allgather scheme, I'm gathering a distributed vector onto a... |
The essence of my question is the following: I have a system of two ODEs. One has an initial-value constraint and the other has a final-value constraint. This can be thought of as a single system with an initial-value constraint on some variables and a final-value constraint on the others.
Here are the details:
I am tr... |
I have some experience with mpmetis from METIS. It is pretty good software which offers unstructured mesh grid partitioning. But obtained results always minimize edgecuts or total communication volume. So splitting simple mesh grid into 2 parts gives me about 50 to 50% of mesh nodes in each part.
I am looking for soft... |
how can I turn an ODE equation into a discrete probabilistic model?
I take for example the Verhulst equation for the growth of a population.
$$\frac{dP}{dt} = rP(1-P/K)$$
I was thinking to simulate the population dynamic simply as a loop (for the time)
and at every time step, for each member of the population
evaluate ... |
I recently came across the notion of an accumulation point as a result of a certain gradient descent variation. The following definition was found:
An accumulation point $P$ is such that there are an infinite number of terms of the sequence in any neighborhood of $P$.
I'm not sure if I understand the above definition c... |
I was trying to run test cases for CG and I need to generate:
symmetric positive definite matrices
of size > 10,000
FULL DENSE
Using only matrix indices and if necessary 1 vector
(Like $A(i,j) = \dfrac{x(i) - x(j)}{(i+j)}$)
With condition number less than 1000.
I have tried:
Generating random matrices using A=rand... |
I have a symmetric indefinite matrix, $H$. I also have a routine that can compute the algebraically smallest eigenvalues of a symmetric indefinite matrix. I would like to compute the eigenvalues with smallest magnitude using my existing code.
One way I can do this is to use my routine to compute the algebraically small... |
In order to estimate the eigenvalues of a real symmetric $n\times n$ matrix, I intend to use the Gershgorin Circle Theorem. Unfortunately, the examples one might find on the internet are a bit confusing; What would be the mathematical
formula for deriving the eigenvalue estimates?
I understand that certain disks are fo... |
I'm trying to visualize the propagation of heat in a discrete sphere surface. The sphere is hollow, only the voxels of the boundary have value.
Visualization in matlab using isosurface shows correct color over the surface.
I would like to show iso-contours over this visualization but this is difficult in matlab. Search... |
This question is more about how to tackle a problem numerically.
In a small project I wanted to simulate the coorbital motion of Janus and Epimetheus. This is basically a three body problem. I choose Saturn to be fixed at the origin, let $r_1$ and $r_2$ be the location vectors of janus and epimetheus, respectively. S... |
Is there good approximation for largest (in magnitude) eigenvalue for discrete Laplacian ($\nabla^2$) obtained from nonuniform structured grid (like that)?
Of course, one can always use general methods such as Lanczos or Power Iteration, but I am interested in cheaper ways, possibly less accurate.
I found exact express... |
Can anyone recommend a site that maintains up-to-date reviews of graphics cards for GPGPU use? Most benchmarks focus on gaming performance, whereas I am interested in the performance of scientific applications like FFTs, linear algebra, and image/video processing.
I want to know how the performance varies for scientifi... |
It is claimed that the time and memory complexities of sparse direct solver are $O(N^2)$ and $O(N^{4/3})$ for 3D problems and $O(N^{1.5})$ and $O(N \log N)$ for 2D, respectively.
But how does a general-purpose direct solver know about dimensionality? If I call a direct solver with an arbitrary matrix, what is the compl... |
I need to compute only a small number of low frequency Fourier components of a complex 2-dimensional array. I'll be computing the same Fourier components over and over again as the input array changes. Clearly, in the limit where I only want one Fourier component, it would be fastest to build a DFT matrix that gives th... |
I am a programmer. I am working with Message Passing Interface (MPI) in C. I do a program that consist on finding the contiguous prime from 1 to 10,000,000.
I already do it! but I do it with trial division, testing the square root of the number to see if it is prime.
For example, to check for a number n, if it is prime... |
Suppose a matrix $X\in\mathbb{R}^{n\times 3}$ is given as a Principal Component Analysis (PCA) projection from some high dimensional space. The 2D PCA solution on X, say $Y\in\mathbb{R}^{n\times 2}$ would simply correspond to the first two columns of $X$.
Now, suppose the configuration is shifted such that the origin c... |
I am trying to solve the following equation numerically:
$$\dfrac{\partial u}{\partial t}=\dfrac 3 x\dfrac \partial{\partial x}\left(\sqrt x \frac \partial {\partial x}(\nu(u,u^2,\cdots,u^k)u\sqrt x)\right)$$
Expressed in its expanded form, this is:
$$u_t=3\nu(u,u^2,\cdots)u_{xx}+\left(6\nu_x(u,u^2,\cdots)+\dfrac{3\nu(... |
I have have multiple large matrices for which I need to find the largest absolute eigenvalue. I know that there is a large submatrix that does not vary. Is it possible to ignore/discard the submatrix?
My question is also related to this question: What is the fastest way to calculate the largest eigenvalue of a general ... |
I know that if I had evenly spaced points, I can use $U_{xx}\approx \frac{U_{i-1}-2U_{i}+U_{i+1}}{dx^2}$.
But if my gridpoints are unevenly spaced, I assume that I can obtain the finite difference formula in the following way:
$D^-[D^+(U)]$, where $D^-$ and $D^+$ are the backward and forward difference formulas. I... |
Suppose I knew that a random number sequence was generated by a linear congruential generator. That is,
$x_{n+1}=(aX_n+c) \bmod m$
If I am given the entire period (or at least a large contiguous subsequence of it), how can I reconstruct the parameters $a,c,m$ and $x_0$ that produced this sequence? I'm looking for a ge... |
I have a set of equations of the form:
$$\begin{align*}
x_1&=(ax_0+c) \bmod (m)\\
x_2&=(ax_1+c) \bmod (m)\\
x_3&=(ax_2+c) \bmod (m)\\
&\vdots\\
x_{n}&=(ax_{n-1}+c) \bmod (m)
\end{align*}$$
I want to compute the sensitivity indices of each equation with respect to the parameters $a$, $c$, and $m$. That is, compute $\fr... |
I would like to model laminar flow of water from roots to the stem of a plant. At the very end of the roots, the tubes vary from millimeter to centimeter scale in diameter and length. As we get closer to the stem the roots get larger in length and diameter. I want to create random 3D domains that represents the network... |
Let $\Omega$ be a convex polygonally bounded Lipschitz domain in $\mathbb R^2$, let $f \in L^2(\Omega)$.
Then the solution of the Dirichlet problem $\Delta u = f$ in $\Omega$, $\operatorname{trace} u = 0$ on $\partial\Omega$ has a unique solution in $H^2$ and is well-posed, i.e. for some constant $C$ we have $\|u\|_{H^... |
Possible Duplicate:
Understanding how Numpy does SVD
I have been using different methods to calculate both the rank of a matrix and the solution of a matrix system of equations. I came across the function linalg.svd, which I now learned is in fact a LAPACK routine. Comparing this to my own effort of solving the syst... |
I have been using different methods to calculate both the rank of a matrix and the solution of a matrix system of equations. I came across the function linalg.svd. Comparing this to my own effort of solving the system with Gaussian Elimination, it appears to be both faster and more precise. I'm trying to understand how... |
When computing the QR factorization in practice, one uses Householder reflections to zero out the lower portion of a matrix. I know that for computing eigenvalues of symmetric matrices, the best you can do with Householder reflections is getting it to tridiagonal form. Is there an obvious way to see why it can't be ful... |
From the Perron-Frobenius theorem, it might be concluded that the spectral radius is the largest eigenvalue for positive matrices, ie, matrices with strictly positive entries. In other words, the largest magnitude eigenvalue of a symmetric, real, positive matrix, is a positive eigenvalue.
However, I'm interested if the... |
My research group focuses on molecular dynamics, which obviously can generate gigabytes of data as part of a single trajectory which must then be analyzed.
Several of the problems we're concerned with involve correlations in the data set, which means that we need to keep track of large amounts of data in memory and ana... |
I made a strange observation while computing the solution to a simple 1D reaction diffusion equation:
$\frac{\partial}{\partial t}a=\frac{\partial^2}{\partial x^2}a-ab$
$\frac{\partial}{\partial t}b=-ab$
$\frac{\partial}{\partial t}c = a$
The initial value of $b$ is a constant ($b(0,x)=b_0$), and I'm only interested i... |
Can anyone point me to methods for varying $h$ in gradient estimation
for noisy numerical optimization?
Some programs have the user give a fixed $h$,
which is used for forward-difference or central-difference
gradient estimates the whole time,
from initial roughly-linear slopes to roughly-quadratic valleys
near a minim... |
Reproducibility has become more and more important in computational science research. (For instance, see this article by Roger Peng in Science; I'm aware of other such articles and web sites also.) However, it's not clear to me how much information I should include with a journal article (or online) to make my computat... |
Suppose the following matrix $A$ is given
$$ \left[\begin{array}{ccc}
0.500 & -0.333 & -0.167\\
-0.500 & 0.667 & -0.167\\
-0.500 & -0.333 & 0.833\end{array}\right]$$
with its transpose $A^T$. The product $A^TA=G$ yields
$$ \left[\begin{array}{ccc}0.750 & -0.334 & -0.417\\
-0.334 & 0.667 & -0.333\\
-0.417 & -0.333 ... |
How does one discretize the classical convective term in a transport equation using finite differences? I know the finite volume schemes out ther i.e. upwind, central differencing etc. Are there direct finite difference analogs?
I am modelling gas combustion in porous media. There are several PDEs involved and my ques... |
I have a small FEM implementation program. And I want to add imposing multifreedom constraints (MFC) feature to it. The theory of master-slave method is given here (page 10 for general case).
Stiffness matrix (static truss) is given in a rearranged block form:
$
\begin{bmatrix}
K_{uu} & K_{um} & K_{us} \\
... |
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:
PetscScalar value_for_matrix;
value_for_matrix=some_expression*returns_PetscReal;
Is the real value returned by the right hand side put into the r... |
I am wondering how to find the eigenvalues of some sparse matrix in given interval [a, b] by iterative method. To my personal understanding, it is more obvious to use Krylov subspace method to find the extreme eigenvalues rather than the interior ones.
|
Let's assume we have a planar domain whose boundary can be described with a polynomial curve (like Bezier curves).
Now assume that you want to produce a discretization of the boundary, i.e. you want to produce a polygon by sampling the polynomial defining the boundary of the domain. How can I produce a boundary that in... |
I'm using a PetscBag to store the input parameters of my program. At some point, I'm going to need to use python to plot these parameters against some output parameters, and dicts along with matplotlib seem to be the way to go with this.
Basically, I want to use PetscBagView() or something like it to write a petsc bag ... |
I'm solving the differential equation
$$
\left( \sigma^{2}(x) u ''(x) \right)'' = f(x), \;\;\; 0 \leqslant x \leqslant 1
$$
with initial conditions $u(0) = u(1) = 0$, $u''(0) = u''(1) = 0$. Here $\sigma(x) \geqslant \sigma_{0} > 0$ is parameter. In operator form we can rewrite the differential equation as $Au = f$... |
I've made a matrix, and now I want to draw it on the screen to make a basic check of correctness. The documentation for MatAssemblyEnd() states that I can pass an option to do this:
-mat_view_draw - PetscDraws nonzero structure of matrix, using MatView() and PetscDrawOpenX().
But when I run my program with this optio... |
In both the potential reduction and primal path following interior point methods for linear programming, a barrier function is constructed which contains the terms $-\sum \log x_j$ where $x_j$ are the variables. This is to keep the variables from being 0 and thus keep the current solution feasible.
However, in potentia... |
I know that in order to solve symmetric eigenvalue problem $Ax = \lambda x$, we can use the Sylvester Inertia Law, that is the number of eigenvalues of $A$ less than $a$ equals the number of negative entries of $D$ where diagonal matrix $D$ comes from the LDL factorization of $A-aI = LDL^{T}$. Then, by bisection method... |
According to this paper,
Ideally, a pseudorandom number generator would produce a stream of
numbers that:
are uniformly distributed,
are uncorrelated,
never repeats itself,
satisfy any statistical test for randomness,
are reproduceable (for debugging purposes),
are portable (the same on any computer),
can be cha... |
Please list the Python package (petsc4py, etc...) and the sparse direct solvers it supports. One (community-wiki) answer per package, please.
|
I have implemented CG in FORTRAN by linking it to Intel MKL.
When there are statements like:
(Refer Wikipedia)
p=r;
x=x+alpha*p
r=r-alpha*Ap;
or similar ones in QMR (in much greater quantity)
v_tld = r;
y = v_tld;
rho = norm( y );
w_tld = r;
z = w_tld;
xi = norm( z ); (and more)
Does it make sense to use BLAS Lev... |
Assume I am running an iterative method, I have a rough estimate of how many iterations it will need, How do best estimate the time it will run for in serial?
For instance, If I have Conjugate Gradient (for Ax=b), how do I estimate how long it will run for given that I know the matrix dimension?
Specifically, I wish to... |
I wrote a function to search a Binary Search Tree, but I have logic problems: When I insert some values, and I have a tree of 2 levels, and the final level (2 in this case) is not full (full is that it does not have all child nodes) it returns 3, not 2:
// --- Definition of depth()
template<typename DataType>
int BST<D... |
I have the positions of a large number of charges (the strengths are known, but are also variables). Are there any tools that will allow me to visualize the electric field induced by these charges (or by a subset of these charges)? Are there such tools that are connected to visualization routines, so that these can be ... |
Suppose a set of $n$ points, $n\in M$, is given in some $d-$dimensional space, $X\in\mathbb{R}^{n\times d}$. Among these $n$ points, some $k\in K$ are selected, so $k<n$, and the distances from these $k$ points to a all other points are calculated and stored in $D\in\mathbb{R}^{n\times k}$.
Now, given only this dista... |
So, we are solving the Biharmonic equation ($\Delta^2 u = f$) on a rectangle by solving the Poisson equation ($\nabla^2 u = f$) two times. We have nice boundary conditions, $u = 0$ and $\Delta u = 0$ on the boundary.
We use a 5 point scheme where
$\frac{1}{h^2} \delta_x^2u_p + \frac{1}{k^2} \delta_y^2u_p = f_p + \tau_p... |
Given large $x \in \mathbb{R}$, I want to know whether or not $2^x$ is an integer. Is there any fast way to answer the question for $x>2^{500}$?
I have also asked a slightly different form of this question on math.se: How many significant figures are needed in base 2?
|
There is a model embedded in a web browser (Caprio 1998) that I would like to use in an MCMC algorithm. What is the best way to do this?
I could implement the model in my favorite language but I would like to know if it is possible to either write a web-scraping / mechanize script to evaluates the model and dumps the o... |
Let $V$ be a finite-dimensional vector space with norm $\|\cdot\|$ and let $F : V \rightarrow \mathbb R$ be a bounded linear functional. It is only given as black-box.
I would like to estimate the norm of $F$ (from above and below). As $F$ is a black-box, the only way to do so is to test it with unit vectors from $V$ a... |
I'm trying to do MD on water vapor. As I know there exists some water models for liquid water, such as SPC,SPC/E,TIP3P, but will they also apply to vapor state of water? And what's the difference of simulations of liquid and vapor water?
|
Background: I'm trying to make a system that tracks a number of bubbles in a video
I'm implementing the bubble detection in the single image case using the Circular Hough Transform. Due to occlusion, blur and other factors, this detection will never be 100% accurate. I am tuning the detection procedure for high recal... |
What would be a good finite difference discretization for the following equation:
$\frac{\partial \rho}{\partial t} + \nabla \cdot \left(\rho u\right)=0$?
We can take the 1D case:
$\frac{\partial \rho}{\partial t} + \frac{d}{dx}\left(\rho u\right)=0$
For some reason all schemes I can find is for the formulation in Lagr... |
I am trying to generate a 2 tuple using maple. Can anyone give me the command to generate this? Thank you very much.
|
Below there are two algorithms for solving tridiagonal linear systems of the form
$$
\left[
\begin{array}{ccccc|c}
b_1 & c_1 & & & &d_1\\
a_2 & b_2 & c_2 & & & d_2\\
& \ddots & \ddots & \ddots & & \vdots\\
& & a_{n-1} & b_{n-1} & c_{n-1} & d_{n-1}\\
& & & a_n & b_n & d_n
\end{array}
\right].
$$
I called th... |
(I hope this question fits this site; if not, accept my apologies).
I ran a certain simulation, and got a time series y(t), t = 0, 1, ... 20. After trying some functions, I found that:
y(t) =~ 1 / (A t + B)
Where A and B are coefficients I calculated using linear regression, with R^2 > 0.99.
What is the standard way t... |
While trying to find cell-centered gradients in finite volume method computation of incompressible fluid flow I get over-determined linear system. This is a well known "cell based least-square" gradient reconstruction.
I know in theory that by using least squares we search for a solution which minimizes error vector in... |
I'm just getting into climate research, and am amazed at how much poorly documented legacy code is used. This kind of thing means that models more or less have to be maintained by the people who wrote them originally. If there was a good open standard for generic data exchange between components of a spatio-temporal mo... |
I'm trying to use MATMPIDENSE matrices to solve a system of type Ax=b, but I have some problems. The KSP documentation says that KSPSolve for dense matrices requires to set a 'gmres' solver and a 'lu' preconditioner, the problem is that a 'lu' preconditioner doesn't work in parallel and the corresponding 'asm' doesn't ... |
Which search/optimization problems can be reduced to the famous "Traveling Salesman Problem"? For instance, I have a collection of N particles, in 3D, and there is a function (Van der Waals energy) which depends on their coordinates. I want to find which configuration of the system minimizes the value of the function. ... |
In[2]:= Solve[sqrt(2x-9) == sqrt(4x+3), x]
Out[2]= {{x -> -6}}
But mathematically there is no solution, since sqrt (-21) is not defined. There is a flag that is responsible for this?
|
It appears that matlab's eigs is giving me bad approximations of the smallest eigenvectors of a matrix.
I assume I can use some slower methods which would also be more accurate...
I am looking to find the 2nd smallest eigenvector of a lapalcian matrix (known as the "fiedler" vector). I know of course that the smallest... |
I have an 2D elastodynamics problem, that is a problem which is driven by the Cauchy equation:
$$\rho\ddot u-\mathrm{div}\sigma=\rho f$$
where $u$ is the displacement, $\sigma$ the Cauchy stress tensor, $f$ the density of volumetric forces, and $\rho$ the mass density. The constituve law is Hook's law from linear elast... |
Doing so strikes me as a waste of time. Consider
std::complex<double> *a = new std::complex<double>[1<<28];
This could be near-instantaneous and only grab pages once they're used, except it isn't.
It appears I'm not the only one bothered by this:
http://listengine.tuxfamily.org/lists.tuxfamily.org/eigen/2011/01/msg001... |
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, std::complex<>, to represent complex floating-point numbers.
In Jack Poulson's answer to a question about default constructors, he points out that he has his own impl... |
I have an iterative method for computing the Moore-Penrose generalized inverse of matrices, that is
$$X_{k+1} = ((I-\beta X_{k}A)^t) + X_{k}$$
with initial approximation:
$$X_{0} = \beta AA^t$$
where:
$A$ is a given $m \times n$ matrix
$\beta \in [0,1]$
$X_{k}$ is the $k$th iterate generated by the algorithm, appro... |
I am getting the warning in the post subject when attempting to optimize a function in Python with the scipy.optimize.fmin_bfgs function.
The complete output:
Warning: Desired error not necessarily achieveddue to precision loss
Current function value: nan
Iterations: 1
Function evaluations: 18
Gra... |
As someone who holds a BA in physics I was somewhat scandalized when I began working with molecular simulations. It was a bit of a shock to discover that even the most detailed and computationally expensive simulations can't quantitatively reproduce the full behavior of water from first principles.
Previously, I had be... |
In the paper Hierarchical Conforming Finite Element Methods for the Biharmonic Equation, P. Oswald claimed Clough-Tocher type elements has $C^1$-continuity while being a cubic polynomial on each triangle. He didn't give a set of explicit basis functions just the standard degrees of freedom on the quadrature points.
Si... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.