# All Questions

7,658 questions
703 views

### Recommendations and experiences on which license to choose for software?

Developers of software have the choice to choose an appropriate license in accordance with the goal(s) of the work. Can anyone give some recommendations/experiences on which license to pick for ...
440 views

### Which time-integration methods should we use for hyperbolic PDEs?

If we employ the Method of Lines for discretization (separate time and space discretization) of hyperbolic PDEs we obtain after spatial discretization by our favorite numerical method (fx. Finite ...
897 views

### numerical integration with possible division by 'zero'

I am trying to integrate $$\int^1_0 t^{2n+2}\exp\left({\frac{\alpha r_0}{t}}\right)dt$$ which is a simple transformation of $$\int^{\infty}_1 x^{2n}\exp(-\alpha r_0 x)dx$$ using $t = \frac1{x}$ ...
210 views

### Nested dissection on regular grid

When solving sparse linear systems using direct factorization methods, the ordering strategy used significantly impacts the fill-in factor of non-zero elements in the factors. One such ordering ...
5k views

### Looking for C/C++ implementations of sampling from multinomial and Dirichlet distributions

I'm looking for C/C++ implementations of functions that return random variates multinomial and Dirichlet distributions. This is in the context of a calculation for posterior predictive p-values, part ...
7k views

### Mathematical Libraries for OpenCL?

I am looking for information from anyone that has tried to use OpenCL in their scientific code. Has anyone tried (recently) ViennaCL? If so, how does it compare to cusp? What about OCLTools? Does it ...
594 views

### Is it possible to dynamically resize a sparse matrix in the Petsc library?

This may be a Petsc newbie question, but... I'm using Petsc to solve a large sparse linear system. The initial creation of the matrix is fairly slow, which I'm given to understand is largely due to ...
3k views

### Future of OpenCL?

The OpenCL programming paradigm promises to be a royalty free opens standard for heterogenous computing. Should we invest our time in developing software based on OpenCL? Pros/cons?
1k views

### Estimation of condition numbers for very large matrices

Which approaches are used in practice for estimating the condition number of large sparse matrices?
118k views

### Recommendations for a usable, fast C++ matrix library?

Does anyone have recommendations on a usable, fast C++ matrix library? What I mean by usable is the following: Matrix objects have an intuitive interface (ex.: I can use rows and columns while ...
423 views

### What should be the criteria for accepting/rejecting singular values?

I am solving a system using singular value decomposition. The singular values (before scaling) are: ...
3k views

### What attributes make a figure “professional-quality”?

I've heard people say that plots produced by ORIGIN tend to look polished and "professional," whereas plots produced by Mathematica do not. However, most plot-creation programs are quite configurable ...
5k views

### Python implementations of Gillespie's direct method

I'm looking for a decent implementation of Gillespie's Direct Method in Python, as if I code the algorithm myself I'm nigh positive I'll do it inefficiently. Anyone have a favorite?
192 views

### Is there one general approach to build a projection methods for different problems?

My question is probably going to be too general to answer it with a couple words. Could you please suggest a good reading in that case. Projection methods are used to reduce size of the solution space ...
2k views

### What are good ways to document scientific software?

Many times, when I've inherited or encountered scientific code written by other people (or occasionally, even my own work), I've noticed that documentation is either sparse or nonexistent. If I'm ...
244 views

### Evaluating $\binom{100}{i}a^i(1-a)^{(100-i)}$ in GMP-GNU

I want to calculate $\binom{100}{i}a^i(1-a)^{(100-i)}$ for different $i$ with $a=0.001$ using GMP-GNU. How can this be done?
350 views

### (How) do you take into account memory fragmentation?

I use an example from finite element theory, but anybody who maintains a large datastructure and successively extends it will find something similar. Suppose I have an unstructured mesh of points and ...
436 views

### An efficient 'drizzle' algorithm?

What efficient implementations of a 'drizzle' algorithm are available? The problem is, given a timestream of data in which each element is associated with a pixel in a map, how do you create that map?...
1k views

### Applying same feature selection to multiple data sets with Weka

I am using the Weka workbench to train a protein fold classifier. I imported my training data into Weka and performed PCA-based feature selection. This seems to have worked fine, but now I cannot ...
31k views

### C++ vs Fortran for HPC

In my computational science PhD program, we are working almost exclusively in C++ and Fortran. It seems like some professors prefer one over the other. I am wondering which one is 'better' or if one ...
291 views

### In what application cases are additive preconditioning schemes superior to multiplicative ones?

In both domain decomposition (DD) and multigrid (MG) methods, one may compose the application of the block updates or coarse corrections as either additive or multiplicative. For pointwise solvers, ...
8k views

### What are criteria to choose between finite-differences and finite-elements

I am used to thinking of finite-differences as a special case of finite-elements, on a very constrained grid. So what are the conditions on how to choose between Finite Difference Method (FDM) and ...
811 views

### Introductions to hp-FEM

do you know good introductions into or surveys $hp$-adaptive finite elements? In particular I do not know how the heuristics for choosing spatial refinement or increased polynomial degree are ...
5k views

### How to work with function pointers in Fortran in scientific programs

Here is a typical usage of function pointers in C. I would like to do something similar in Fortran. I have some ideas, but I would like to know if there is some canonical way to do so. The function ...
1k views

### What are possible methods to solve compressible Euler equations

I would like to write my own solver for compressible Euler equations, and most importantly I want it to work robustly in all situations. I would like it to be FE based (DG is ok). What are the ...
345 views

### How to deal with too much data?

Our plasma dynamics simulations often produce too much information. During the simulations we record various physical properties on a grid (x,y,z,t) that is as large as (8192x1024x1024x1500), for at ...
54 views

### Assembled human ESTs for annotation

I am annotating protein-coding genes in a region of the human genome and am looking for a set of assembled ESTs I can use as evidence for constructing gene models. A quick search of NCBI's SRA shows 4,...
555 views

### How should I study creating and programming HPC systems?

I'm in a field that doesn't necessarily do a great deal of HPC work, and when it does encounter it, it's often the result of researchers from other fields exploring new applications to their methods ...
882 views

### Sampling from posterior predictive distribution

First post. I'm working on this problem using Bayesian methods. In desperation I'm considering using p-values (shock horror), specifically posterior predictive p-values. So I need to simulate from the ...
344 views

### Approximate a distribution function from a finite sample

Say I have a simulation that produces a single floating point number as a result, and a different number is produced each time the simulation runs. These numbers are randomly distributed according to ...
716 views

### COMSOL on Ubuntu (10.04 LTS and 11.04)

I am running into a problem with COMSOL 4.2.0.187 on Ubuntu (both 10.04 LTS and 11.04). When using the option -np x with x > 1, ...
18k views

### Intel Fortran Compiler: tips on optimization at compilation

I will start with my personal experience in our lab. Back in the ifort 9 and 10 days, we used to be quite aggressive with the optimizations, compiling with -O3 and processor specific flags (-xW -xSSE4....
165 views

### Global optimal sequence alignment algorithms

As far as global optimal sequence alignment goes, is the Needleman-Wunsch and Hirschberg's algorithm still state of the art? Or have there been any improvements to these algorithms since they were ...
3k views

### Where can I find a database of simple chemical structures in XYZ format?

As from Title. Where can I find a database of simple chemical structures in XYZ format, possibly with a simple CAS -> XYZ or InChi -> XYZ REST service ?
1k views

### Is there a numerical algorithm for finding an asymptotic slope?

I have a series of data points $(x_i,y_i)$ which I expect to (approximately) follow a function $y(x)$ that asymptotes to a line at large $x$. Essentially, $f(x) \equiv y(x) - (ax + b)$ approaches zero ...
225 views

### Best practices for describing agent-based models

I work fairly heavily in mathematical biology/epidemiology, where most of the modeling/computational science work is still dominated by sets of ODEs, admittedly sometimes fairly elaborate sets of them....
199 views

### Optimal way to find stationary solutions of the PDE

I am researching heat diffusion in an optical element irradiated by laser. This problem is described by the PDE which I wrote down in this question. I am using an implicit numerical scheme to model ...
160 views

### Artificial RNA 3D folding

I have a 50-base, artificially created RNA sequence and I would like to obtain its 3D structure. What software should I use for this purpose?
617 views

### Quickly finding rough lines in sets of points

In a particular class of detector our data comes out as pairs of points in two dimensions, and we want to string these points into lines. The data is noisy, and is binned in one direction but not in ...
682 views

### Linear regression via SVD not producing best fit with escalating polynomial degree

I am using a basic singular value decomposition (via LAPACK) routine in FORTRAN to solve an overdetermined system in the form of $A\cdot X = B$ where $\mathrm{size}(A) = [m,n]$ with $m > n$. My ...
10k views

### Performance differences between ATLAS and MKL?

ATLAS is a free BLAS/LAPACK replacement that tunes itself to the machine when compiled. MKL is the commercial library shipped by Intel. Are these two libraries comparable when it comes to performance, ...
226 views

### Enumerating hexahedral cell vertices and faces in arbitrary dimension

I have a Cartesian mesh in $d$ dimensions, and I would like to enumerate all the subcells of a given hexahedral cell. If I am just enumerating the vertices of a cell (or cells that contain a vertex) I ...
945 views

### How can I compute the Schur complement in PETSc?

How can I compute the Schur complement: $$S = K_{bb} - K_{ba} K_{aa}^{-1} K_{ab}$$ where $$K=\begin{pmatrix} K_{aa} & K_{ab} \\ K_{ba} & K_{bb} \end{pmatrix}$$ (in some ordering) is a ...
129 views

### Profiling numeric libraries

What efforts have been made to quantify the costs of the common numeric workhorse operations such as those found in LAPACK, BLAS, sparse matrix operations, etc.... We have several libraries which ...
8k views

### Is it worthwhile to write unit tests for scientific research codes?

I am strongly convinced of the value of using tests that verify a complete program (e.g. convergence tests), including an automated set of regression tests. After reading some programming books, I've ...
18k views

### What makes Fortran fast?

Fortran has a special place in numerical programming. You can certainly make good and fast software in other languages, but Fortran keeps performing very well despite its age. Moreover, it's easier to ...
2k views

### Parallel I/O options, in particular parallel HDF5

I have an application that can be trivially parallelized but its performance is to a large extent I/O bound. The application reads a single input array stored in a file that is typically 2-5 GB in ...
320 views

### What programming strategies can I take for easily modifying algorithm parameters?

Developing scientific algorithms is a highly iterative process often involving changing lots of parameters that I will want to vary either as part of my experimental design or as part of tweaking ...