All Questions

0
votes
0answers
13 views

The final Boundary Condition is Unknown, Is Backward Euler is still valid to be implemented?

I am working on conductive polymer modeling and supposed to do one-dimensional diffusion model in the thickness of the polymer, however, due to the small value of thickness in micro, when I use the ...
0
votes
0answers
24 views

Fastest method for elliptic pde

What is the fastest method (language, solver, etc.) to numerically solve elliptic equations such as Poisson or Stokes equations in a cube in 3D with mixed boundary conditions? Especially, a ...
0
votes
0answers
8 views

Inverse kinematics BFGS divergence

I am trying to implement inverse kinematics solver using BFGS as stated in the paper Xia2017. In the test experiment, i created 4 objects in 3-dimensional space: Node,Node1,Node2,Node3. Each Node is a ...
0
votes
0answers
10 views

Why does the correlation function of this stochastic differential equation starts at different points?

I am working with the following differential equation: The equation is $$x=\beta +\sqrt{2D} \xi(t)$$ where $\xi(t)$ is a white noise term, with a reflecting wall boundary conditions. After solving ...
0
votes
0answers
11 views

How to implement adaptive step size Runge-Kutta Cash-Karp?

Trying to implement an adaptive step size Runge-Kutta Cash-Karp but failing with this error: ...
0
votes
0answers
18 views

Finding a shortest path in a graph

If each edge of a graph $G$ is unweighted or has equal weights, then the shortest path between two nodes in that graph is the path that contains the fewest number of edges. Such a path can be obtained ...
0
votes
0answers
16 views

Infinity norm inverse estimate

Let $V_h$ be the space of linear finite elements on triangles. From the scaling argument, we can obtain the following inverse estimate inequality: $$ \| v_h \|_t \leq ch^{m-t} \| v_h \|_m, $$ for ...
1
vote
0answers
12 views

Calculate the Bloch wave

The eigenvalue problem $$\frac{d^2u}{dx^2}+2i k\frac{du}{dx}-k^2-6\sin(x)^2u(x)=-\mu u(x)$$ gives the first five eigenvalues with $k=0$ or $k=1$ which are $2.06$, $2.26$, $5.16$, $6.81$, and $7.74$....
0
votes
0answers
8 views

Specifying mesh spacing for DFT in numpy

I was testing the .fft package of numpy 1.16.1 in Python 3.7.2. In particular I was trying to verify that the transform resembles the analytical one for: $$f(x) = \mathrm{exp}\left[-\left(\frac{x-5}{2}...
0
votes
0answers
21 views

Python ODE solver with implicit Euler method

I am looking for two python solvers using these methods: Backward (implicit) Euler method with fixed step size Backward (implicit) Euler method with adaptive step size I need the solvers to be able ...
1
vote
1answer
44 views

FFT solver for the Poisson problem with Dirichlet boundary conditions

I am trying to solve the Poisson problem with Dirichlet boundary condition in 1D: \begin{equation} \begin{array}{rcl} - \mu \Delta u & = & f~in~[0,1], \\ u(0) & = & 0, \\ u(1) & = ...
0
votes
0answers
39 views

Reflexive and antisymmetric have same things in some cases [on hold]

i have an example of Antisymmetric i.e 1: R(1,1),(2,2) and one example of Reflexive is 2: R(1,1),(2,2). both examples are same. my question is this: Q: why same things have different names? ...
-1
votes
0answers
20 views

Why the loss is nan by using linear activation function in the last layer?

I want to use neural network to solve a simple regression problem, and I try to program by myself accroding to lecture Backpropagation and Neural Networks . However, I meet loss divergence problem. ...
0
votes
0answers
20 views

Parameter estimation using fmincon

This is a follow up to my previous question posted here. I am solving an optimization problem using fmincon in MATLAB. There are no equality constraints in my model....
2
votes
0answers
45 views
+100

Computing the structure factor from positions and radial distribution function

I'm currently analysing some spatial point patterns that come from some fluid dynamics simulations and I'm having some difficulty computing the structure factor, $S(\pmb{k})$, from both the positions ...
-1
votes
0answers
18 views

how to do aggregate analysis for a complex networked system

i wanted to know how to do aggregate analysis for a complex networked system. You can assume this complex networked system to be something like an organisation where people work in several units and ...
4
votes
1answer
71 views

How to calculate the geodesic curvature of a discrete 3D curve?

I have coordinates of a set of points that form a closed loop that lies in a 3D surface. I know the equation of the surface and I can calculate it's surface normal at any point. I found that for a ...
1
vote
0answers
23 views

Boundary conditions for a Non-linear Schrödinger equation using an extended crank nicolson scheme

I try to solve numerically the following PDE for $E(r, z)$ with a cylindrical symmetrie (i. e. $E(r, z) = E(-r, z)$). $\frac{\partial E}{\partial z} = \frac{i}{2k} \Delta E + \mathcal{N}(E)$ Where $...
0
votes
0answers
23 views

Stability region of explicit midpoint method

Consider the explicit midpoint method, i.e $$y_{n+1}-y_{n-1} = 2hf(y_n).$$ I'm asked to apply this method to the linear test equation, $f(y_n) = \lambda y_n,$ in order to find the method's stability ...
4
votes
0answers
30 views

Numerical methods for the continuity equation with Sobolev vector field

Consider the continuity equation $$ \partial_t \rho(x,t) + \operatorname{div} (b(x,t) \rho(x,t)) = 0, \qquad t \in [0,T], \quad x \in \mathbb R^N, $$ with $b \in L^1((0,T), W^{1,p}(\mathbb R^N))$. ...
1
vote
0answers
27 views

Boundary conditions for solving the time-independent SE for the hydrogen atom

I am trying to solve the schrodinger equation for the hydrogen atom numerically, using finite elements, with matlab's solvepdeeig(). I have a hard time getting the solution to be right, and it seems ...
0
votes
0answers
34 views

Parameter estimation using shooting method

I want to do the following, I have a set of 20 first order differential equations and I want to estimate some of the parameters. I've got the following initial and boundary conditions. The initial ...
3
votes
1answer
117 views

Computing any element of the null space of a singular matrix

Given a singular matrix $A$, what is the fastest method to find a single non-zero solution to $Ax=0$? Note that we are not looking for the whole kernel, we just want any non-zero vector in it. I ...
0
votes
0answers
32 views

Time sampling changes solution

I'm currently trying to solve a problem using numerical methods. The set-up is rather long, so I apologize in advance... TL;DR: My solutions change depending on how big my steps are and I don't know ...
0
votes
0answers
17 views

state of art resources for transportation logistics

By transportation logistics, I mean the application of theoretical tools like traveling salesman problem, routing problem etc. So what are these applications? Well, stuff like how to schedule a fleet ...
2
votes
1answer
58 views

Nonlinear conjugate gradient with orthogonality constraint

I have to solve a set of nonlinear optimization problems in the subspace defined as the orthogonal space to a given vector. More precisely, $$ \arg\min f(\vec x) \qquad \text{with} \qquad \vec x \...
0
votes
0answers
20 views

Euler's method in scilab

I trying to solve this system of equations with Euler's method $$\begin{aligned} \frac{dn_0}{dt} &= -n_0(t)W_{01}(t) + n_1(t)K_{10}\\ \frac{dn_1}{dt} &= -n_1(t)W_{12}(t) - n_1(t)K_{10} + n_2(...
0
votes
0answers
18 views

How to start using python scripting in automotive power train? [closed]

Looking for the basic things like what we can do with python in automotive.
0
votes
1answer
36 views

How to efficently plot a finite element mesh solution with matplotlib

I am looking for the most efficient way to plot a mesh using matplotlib given the following information, coordinates of each node, what nodes belong to each element, and the value each node has. Below ...
1
vote
1answer
39 views

Simplest way to precondition Uzawa iteration

I have a diffusion problem with an internal circular dirichlet constraint and a side condition which shall enforce a certain global volume integral. $\nabla(D \nabla u(x)) = 0$ outer boundary ...
0
votes
1answer
40 views

How to obtain linear tridiagonal system from PDE

I'm trying to re-solve the governing equations in hydraulic fracturing modeling as instructed step by step in a paper. After (A-9), the author stated that by substituting A-6, A-8 and A-9 into ...
3
votes
0answers
46 views

Solve ODE with non-negative and maximization constraints

My task is to solve $$\eta_k\frac{d^2C_k}{dz}(z)=-e_k, k = 1,2,3$$ $$C_k\ge0$$ $$C_1(0)=0, C_2(0)=A, C_3(0)=0$$ $$C_1(L)=B, \frac{dC_2}{dz}(L)=0, \frac{dC_3}{dz}(L)=0$$ with $$e_1 = -\beta_1-\beta_3$...
0
votes
1answer
40 views

CFL equation for non-linear equation

I am trying to solve numerically (obviously) inviscid Burgers' equation with the finite difference method. The equation is the following: $$ \displaystyle \partial_t u + u \, \partial_x u = 0 $$ ...
1
vote
1answer
38 views

Weak scaling for N-body simulations

I'm going to be doing some weak scaling of an $N$-body integrator on AWS. In the past when I've done weak scaling for this integrator I've fixed the number of particles per core ($N/n = {\rm const}$). ...
1
vote
1answer
28 views

How to obtain and form a 1st order differential equation for leapfrog integration from second order one in this example of coulomb drag

I am currently doing a computational physics homework which asked us to use leapfrog to give the relations between timevelocities and time-distance of these two objects. The full question is as ...
0
votes
0answers
46 views

Good C, C++ library for efficient grid search / tuples, ideally with bindings to Eigen

I have a $q$-dimensional grid, known at run, not compile-time, that has $50$ points in each direction and hence $50^3$ combinations that I would like to first build and then call a function with each ...
0
votes
0answers
31 views

How can I find the velocity of the capillary flow?

What is the best way of finding the capillary flow using computer vision? Procedure that I have been using so far: Selected a ROI Calculated the optical flow in the ROI to get a flow matrix ...
0
votes
0answers
14 views

Vehicle routing problem using or-tools with delivery constraints

I want to solve a vehicle routing problem where goods are collected from multiple locations, and then dropped at collection facilities. There are multiple collection points and they should be filled ...
1
vote
1answer
69 views

Is there a name for this integer linear optimization problem?

I have an integer linear programming problem of the form: $$\DeclareMathOperator{\tr}{tr} \min \tr WX$$ subject to: $$\begin{align} \sum_j X_{ij} < c_i && \forall i \\ \sum_i X_{ij} = 1 &...
0
votes
0answers
29 views

Finding second excited state of Schrödinger equation with secant Runge Kutta method

In our assignment, we are required to find the energies of the ground state and the first two excited states of the Schrödinger equation in a harmonic potential: $$V = \frac{50 x^2}{(10^{-11})^2}\, .$...
0
votes
1answer
25 views

How to improve the efficiency of periodicity detection for long time based lined and gapped datasets

Our data set has $10^4$ data points, but has a long baseline and many gaps. As the histogram shows, the horizontal-axis is time and most of the time, there are no data. The vertical-axis is data ...
0
votes
0answers
13 views

Numpy repeat for selected rows [closed]

Is it possible to repeat selected rows in numpy? For example, can we get [[1, 2,3][1,2,3][4,5,6]] from[[1, 2,3][4,5,6]] ?
0
votes
0answers
24 views

extrapolation/interpolation in fmincg.m

Can you tell me these equations come from where in MATLAB fmincg.m? ...
4
votes
1answer
122 views

Is a symmetric bilinear form necessary to ensure a weak formulation has a solution?

Problem I want to convert the general second order linear PDE problem \begin{align} \begin{cases} a(x,y)\frac{\partial^2 u}{\partial x^2}+b(x,y) \frac{\partial^2 u}{\partial y^2} +c(x,y)\frac{\...
-1
votes
0answers
23 views

How to decrease the cost by direct computation of the jacobian given a system of equation with drift matrix

I have provided the R script of the project I´m working on.It works fine but computation of the required Jacobian at each step makes it costly. I need to find an alternate way to either compute the ...
1
vote
0answers
37 views

Properly sizing ParaView plots for LaTeX

I would like to make a visualization with ParaView for a paper. In order to have a high quality look, I would like the image to be, say, 300 dpi (or vector graphics). Moreover, since I know the column ...
0
votes
0answers
38 views

A fast way to check if a Matrix is ill-conditioned, and turning it into well-conditioned

I'm running a simulation, and some linear solvers are returning a message of ill-conditioned matrix. Hence, I'm looking for a fast, easy to implement, method to detect if a matrix is ill-conditioned, ...
-1
votes
0answers
17 views

Polyfit min/max constraints

I would like to "smooth" my prediction output and limit it to specific local min/max points. (The predicted line in blue - min is to low, how can I limit the polynomial equation accordingly?) My ...
1
vote
1answer
81 views

What's the minimum step size that can be used in Euler's method before it becomes unreliable?

In particular, if Euler's method is implemented on a computer, what's the minimum step size that can be used before rounding errors cause the Euler approximations to become completely unreliable? I ...
2
votes
1answer
87 views

Why the numerical solution of advection-dominant problem is challenging

In many CFD text books, usually there is a dedicated chapter for advection term discretization. Why discretization of such term in advection-dominated problems and near the discontinuities is ...

15 30 50 per page