A powerful object oriented programming language.

learn more… | top users | synonyms

1
vote
1answer
63 views

Is there a single C++ IDE packed with necessary scientific libraries for computing purpose?

I am basically looking for a good open source C++ IDE with scientific and visualization libraries built in. Can any one suggest few projects?
0
votes
0answers
51 views

C++ Library: What is the Most Efficient Library that Factorizes a Polynomial?

I need to know what library is the fastest one that can factorize a polynomial of large degree whose coefficients are big integers. I have tried NTL library to factorize a monic polynomial but it is ...
14
votes
6answers
664 views

Modern C++ in scientific computing?

I am looking for books or articles, or blog-posts, or any published material in general, that address specifically the uses of C++ modern features (move semantics, the STL, iterators, lazy evaluation, ...
2
votes
1answer
76 views

Recommendation for C/C++ library which offers Schur complement functions?

I need to find C/C++ libraries which offer function for computing Schur complement. I know about MUMPS and Pastix, but I need more of them to compare them in my research. Do you have any experience ...
1
vote
1answer
35 views

Interpolation using compactly supported radial basis function

I have been struggling for two days with the following problem. I would like to do a $d$-dimensional interpolation over some data. I tried first to use polyharmonic splines, but when the size of data ...
2
votes
2answers
113 views

C++ Library: What is the common libraries that do polynomial arithmetic?

I need to know what libraries (in C++) support polynomial arithmetic specially over a field. So I can give to it an array of coefficients of polynomial over a field and it returns the roots of ...
2
votes
0answers
82 views

C++: How to find the roots of polynomial modulus N [duplicate]

I need to know what library, given a vector of coefficients and modulus N return the roots of polynomial modulus N. The library should support big integer. I'm coding in C++.
4
votes
3answers
115 views

Minimization of non-linear function

Problem Summary I am trying to estimate the (x,y) coordinates of each node in a graph, where I know the distances between connected nodes. For example Given this ...
1
vote
1answer
45 views

C++ - Starting paraller instances of an executable from a C++ code

Can I start parallel run of LAMMPS from inside a C++ code. Is it possible to compile my code and then do mpirun with my compiled code. I also have one system command inside the code, which starts ...
-1
votes
1answer
79 views

How to solve this differential equation using RK4 in C++?

How to apply these equation using second order DE using RK4 in c++ and how top plot a graph with it?? ...
1
vote
1answer
66 views

Why is MPI/PETSc only showing 1 processor even though it works for helloworld?

I am a beginner with Unix and MPI. For the serial program, I run the program by typing make in /directory/buildagain and then ...
1
vote
2answers
105 views

Parallelization of element-wise matrix multiplication

I use Armadillo as an interface to OpenBLAS. In my current program, I have a loop, in which I do multiplications of the form ...
1
vote
0answers
39 views

Elemental vs DPLASMA

I want to use one of these two libraries into my C++ project to basically invert a dense matrix (with Cholesky). Of course, I am interested in a distributed environment. Both libraries seem nice so ...
6
votes
6answers
2k views

Super C++ optimization of matrix multiplication with Armadillo

I'm using Armadillo to do very intensive matrix multiplications with side lengths $2^n$, where $n$ can be up to 20 or even more. I'm using Armadillo with OpenBLAS for matrix multiplication, which ...
3
votes
1answer
162 views

Software for triangulating a point set (with restrictions)

I want to triangulate a point-set like the one below. I would like the triangulation of the point-set to have the following properties The triangles must have as vertices the black and orange ...
0
votes
0answers
27 views

Solving the Wilberforce pendulum using Runge-Kutta method [duplicate]

I'm writing a program in C++ (almost from scratch) for solving the coupled equations that rise from the Wilberforce pendulum: $m\ddot{z}+kz+\frac{1}{2}\epsilon \theta = 0$ $I\ddot{\theta}+\delta ...
1
vote
1answer
371 views

eigenvalues of a general complex matrix in C++

Is there a free C or C++ library including a routine for the eigenvalues of a general complex matrix? I checked a number of linear algebra packages like Eigen, but there does not seem to be support ...
0
votes
0answers
62 views

Sparse MatrixExp acting on a vector

I am looking for a library implemented in C++ which would be able to compute action of matrix exp on a vector $$w = e^{A}v$$ I want to operate on sparse matrices with complex entries, not on real ...
3
votes
2answers
117 views

Why is SIMD programming on such a low level in CPU's compared to GPU's?

Just speaking from my experience in c++ - Its really tricky to take advantage of the SIMD capabilities of modern CPU's for more complex algorithms. If I see an opportunity from a high level OO ...
5
votes
1answer
1k views

Applying the Runge-Kutta method to second order ODEs

How can I replace the Euler method by Runge-Kutta 4th order to determine the free fall motion in not constant gravitional magnitude (eg. free fall from 10 000 km above ground)? So far I wrote simple ...
2
votes
1answer
74 views

Mathematica NIntegrate function in C++

I am working on computing a challenging integral. I am working with someone else who wrote some code in Mathematica to compute it. I do not have mathematica so I am trying to do the same thing in C++. ...
3
votes
2answers
451 views

literature on scientific computing

Maybe, this is a dump question. But anyway. I developed a finite difference code for a class of problems in dynamo theory. I used GNU Octave (MATLAB) which is good for testing. The problem size ...
0
votes
0answers
73 views

Compute left and right eigenvectors in c++ using Eigen library

The zgeev routine of the Lapack library computes the eigenvalues and left and/or right eigenvectors of a given matrix. I want to use c++ and the eigen library to do the same. A ...
0
votes
1answer
255 views

Order of eigenvalue problem using c++ Eigen library

I have the following 6x6 matrix (taken from Google Books p. 129): For background info: All the entries depend on the momentum $k$. Getting the eigenvalues of this matrix for each $k$ corresponds to ...
2
votes
0answers
44 views

Bracket Algebra, Straightening Algorithm

My apologies if the question is simple. I need to write a code for straightening algorithm. Which includes defining bracket algebra. I tried to write it in CoCoA-5, but it wasn't possible because ...
1
vote
0answers
63 views

Get a single value from a global Vec in petsc [closed]

I don't understand the concept with local and global vec's in petsc when it come to DMDAVecGetArray and VecGetValues. I'm creating some DMDA Vec in parallel which works well. Now I want to access ...
2
votes
1answer
84 views

What are the tradeoffs of using statically allocated arrays vs. pointers and dynamic allocation? [closed]

I am learning Monte Carlo simulation by C++. I begin with reading codes (from the internet and text books) of the 2D Ising model and the XY model. I find some people define spins simply by a two ...
0
votes
1answer
46 views

Unexpected behavior, values tend to converge instead of fluctuate. (MD)

I am writing a molecular dynamics program to create an lattice and populate it with atoms/molecules. These then are given random velocities and the system is initialized. Then throughout time the ...
-2
votes
1answer
58 views

Simulating dipoles/quadrupoles

Does anyone know how to simulate in C++ the beam-dynamics of particles passing through an array of magnets like a quadrupole + dipole ? Or maybe in the thin lense approximation how to simulate a FODO ...
1
vote
1answer
46 views

LAPACK DGGEVX: BALANC option

I'm using DGGEVX routine from LAPACKE with BALANC option as shown below, but to my surprise changing BALANC option from 'N' to ...
0
votes
1answer
66 views

How to give a simple estimation of errors for results obtained from 4th order Runge-Kutta

This question is a follow up of another one I have asked a while ago. I have successfully implemented my problem using odeint library and I get the results I expect. However I would like to give an ...
1
vote
1answer
265 views

Parallel vs Serial Thomas Algorithm

I am currently writing a code that solves a large tridiagonal matrix every iteration and runs for 1,000's of iterations. I am currently using a Thomas algorithm to solve the matrix serially. I found a ...
1
vote
0answers
135 views

Can you provide me with the source code of DMRG writen by C++?

I want to study the Density matrix renormalization Group(DMRG). Can some one provide me with the souce code which is writen by C++ for study purpose only? The code is not necessiary very professional, ...
3
votes
5answers
162 views

Speed of solving linear system with block diagonal matrix

I have a bunch of 3x3 linear systems of the form $Ax=b$. In general, would it be faster to solve each individual system, or to formulate it as a giant block diagonal system and solve that? I expect ...
0
votes
0answers
59 views

Debugging in parallel mode using Netbeans

I want to debug a c++ code with Netbeans. I can use the debugger in sequential mode but I dont know how to debug it when I want to run it in parallel. I would be grateful if anyone help me on this ...
0
votes
0answers
89 views

Eigen vector property: MATLAB 'chol' (LAPACK DSYGV) & MATLAB 'qz' (LAPACK DGGEVX)

Two Eigen algorithms return Eigen vectors with different properties: 1st algorithm, LAPACK DSYGV (the same as MATLAB eig with ...
0
votes
2answers
110 views

Simulating a traveling sine wave

I'm trying to make an animation of a travelling sine wave (amplitude vs. position) would anyon here happen to know how to do so?
2
votes
1answer
109 views

non-smooth convex c++ solver

I happened to know that there are advanced established techniques for non-smooth convex optimization in research. For example, these two papers: Nesterov, "Smooth minimization of non-smooth ...
0
votes
0answers
284 views

Eigen-unsupported: Levenberg - Marquardt algorithm

I am using Eigen-unsupported: LevenbergMarquardt algorithm. I use this algorithm inside my model. I wrote the minimization code both in MATLAB (using fsolve) and C++ and both gave the similar results ...
1
vote
1answer
274 views

How can I call the Boost C++ odeint Runge-Kutta integrator for a system of ODEs?

I would like to use Boost C++ odeint Runge-Kutta integrator on a system that looks like this : $$\ddot x = - \frac A{||x||^3} * x $$ $ x $ is a vector in 3D space, so basicaly $ x(i, j, k) $ $ ...
-2
votes
1answer
101 views

Solving electron density function for Hydrogen and drawing in 3D

I recently stumbled upon interesting site that has interactive 3D representation of radial electron distribution (atomic orbital). here is the url: ...
3
votes
1answer
66 views

Computing the (non-convex) boundary of a set of paths between two points

I have a set of paths between two fixed points (marked in red below). Each of these paths consists of an ordered series of $\{x, y\}$ points (marked in blue). I am trying to find the ordered set of ...
3
votes
2answers
771 views

Programming Finite Element Methods in C++

I am trying to develop a library for finite element methods in C++ and for that I am looking at the data structures for meshes. Based on what I've read up on fenics and deal.ii, the general ...
0
votes
1answer
243 views

Domain Decomposition with PETSc

Does anyone have any experience on Domain Decomposition using PETSc library? I have used PETSc for creating my vectors and matrix within my C++ code. I also used KSP to solve the linear system. I ...
0
votes
0answers
25 views

Cardiac Excitation Threshold in C++ modelling

So I am trying to write a code in C++ about the cardiac excitation threshold. I know that this excitation threshold is the shortest stimulus2 value at which it can conduct an action potential (known ...
0
votes
0answers
214 views

total memory usage of MPI shared memory

I am trying to use the MPI share memory feature. I have several SMP nodes, and each of them has four cores. I need an array of size N for each node that should be accessed by all four cores in each ...
1
vote
1answer
174 views

Windows C++ library for operations on mesh with a mex-interface in Matlab?

Please recommend me a well documented C++ library that I could wrap with a mex-interface in Matlab. The library should have the capability to read meshes (optimal in different formats, at least in ...
0
votes
0answers
35 views

Sequence optimization for multithreading

Given a list of object I must compute an expensive operation on any couple of object of the list. So I need to create a sequence of tasks. I want to find the sequence of tasks such that there is the ...
0
votes
2answers
91 views

How to determine the number of c points in algebraic multi grid

I am trying to write an algebraic multi-grid solver (in c++). At a given level I determine which nodes are c-points and which nodes are f-points (where the total number of c and f points equals the ...
5
votes
2answers
796 views

Should I pass command line arguments to MPI_Init or not?

When writing MPI 3.0 code, should I pass argc and argv to the MPI_Init call or not, and why? ...