# Tag Info

0

r is the distance between the two masses v is the relative velocity a is the relative semimajor axis* * Two bodies orbiting each other trace out two separate ellipses in an inertial frame. The smaller body traces a larger ellipse, and vice versa. The relative semimajor axis (a) is equal to the sum of the semimajor axes of these two ellipses. The relative ...

3

The issue is with short-hand notation. The term $\psi^{n+1/2}_{j,k}$ being operated on by $D_x^2$ really means \begin{align} D_x^2\psi^{n+1/2}_{j,k}&=D_x^2\left[\frac12\left(\psi^{n+1}_{j,k}+\psi^n_{j,k}\right)\right]\\ &=\frac12D_x^2\psi^{n+1}_{j,k}+\frac12D_x^2\psi^{n_{j,k}} \\ &=\frac1{2\Delta ...

2

The parameter $h$ is the maximum distance that two smoothed particles, $a$ and $b$, can be before the distance between them is negligible for SPH purposes. If the distance, $\vert r_a-r_b\vert>h$ then the weight is zero. For any kernel, the integral over the particular region, e.g. $r\in(-h,\,h)$, is necessarily 1. Since $h$ is an unknown parameter, then ...

1

Almost all of the comments are valuable. I think that a consensus is building (probably better: has been built) that the standard base system for science use is the numpy/scipy/matplotlib stack. But there are packages that don't build on that stack. I'm afraid you'll have to do some digging to see which packages will work for you. There are many ...

0

The subscript $j$ represents all particles, including $i$, from 1 to $n$. This should be obvious in the example below Equation (9), To give an example, let us consider the distance constraing function $C(\mathbf p_1,\,\mathbf p_2)=\vert\mathbf p_1-\mathbf p_2\vert-d$. The derivative with respect to the points are \$\nabla_{\mathbf p_1}C(\mathbf ...

1

My previous comments are almost ok, your actual problem seems to be that you do not average over the magnetization. You are measuring <cos(theta)>, which is the average of m_x. So just change m = magnetization_cossin(); to magnetization_cossin(&mx, &my); where you define void magnetization_cossin(double* mx, double* my) { int x, y, z; ...

0

The heat equation for non-constant coefficients, which is more or less what you're doing here, takes the form, $$\frac{\partial\psi}{\partial t}=\nabla\cdot\left(\kappa\nabla\psi\right)$$ We can simplify by using a single dimension: $$\frac{\partial\psi}{\partial t}=\frac{\partial}{\partial x}\left(\kappa\frac{\partial\psi}{\partial x}\right)$$ Rather ...

Top 50 recent answers are included