Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [physics]

Questions related to the application of Mathematica to problems in physics.

1
vote
1answer
211 views

Mathematica package for power spectra of scalar perturbations

Is there any Mathematica package available to numerically compute the power spectra of the scalar and tensor perturbations in cosmology? I'd like to numerically calculate the tensor to scalar ratio in ...
1
vote
1answer
104 views

Solving a diffusion-reaction ODE with NDSolve

I'm working on solving an equation to estimate production in a spherical catalyst pellet. A working example is given below: ...
4
votes
1answer
925 views

Plotting the electric field and potential of a dipole

This is a function that takes a function, turn it into a vector, then plots the vector and its contour. ...
3
votes
1answer
370 views

How can I plot visible spectrum? [duplicate]

I have a data with wavelength and intensity and I draw these graph with excel. then how can i make this into specturm like below?
1
vote
1answer
101 views

Mathematica not able to calculate known principal value using Integrate

I am trying to calculate the principal value integral - $$I = P\int_{-\infty}^{\infty}\frac{g(x)}{y-x}dx$$ where $$g(x) = f_{1}(x) - f_2(x)$$ $$ f_i(x) = \frac{1}{1+e^{\beta_{i}(x-\mu_{i})}} $$ $$y = ...
3
votes
3answers
147 views

Filling a ListPlot with an optical spectrum

I have discrete optical spectra data consisting of pairs of wavelengths and intensities, and I would like to make a ListPlot in which the points are both joined, ...
4
votes
1answer
783 views

How to define a tensor in xAct for Mathematica?

I'm working on a cosmological model for general relativity, and I need to define a tensor and assign values to this. For example, a tensor $A_{\mu\nu}$ that is function of other tensors: $$A_{\mu\nu}...
0
votes
1answer
98 views

Is there a way to compute the following definite integrals?

While evaluating the final wavefunction of a free spin-0 particle in one dimension in terms of Green's functions (propagators) and considering the initial conditions as Gaussian wavepackets, I arrived ...
1
vote
1answer
144 views

ParametricNDSolveValue for ODE with boundary at infinity

I'm trying solve the Schrödinger equation for a given potential using the function ParametricNDSolveValue following the the first method of the post: Find eigen energies of time-independent Schrö...
-5
votes
1answer
426 views

Plotting Hermite-Gaussian polynomial for Gaussian beams

Can you show me all the steps and the code to trace the Hermite modes with Mathematica 11? I want to draw the Hermite Gauss mode for a Gaussian beam with Mathematica 11 but I can not write a ...
1
vote
1answer
225 views

Finding intersection points from contour plot

The Left hand side of the equation has only real part. But the right hand side has real and imaginary parts. So i am using a contour plot. The intersection of lefthand side and righthand side of ...
4
votes
1answer
364 views

A product for fermionic variables

I'm trying to write a dot product that can handle fermionic variables, i.e., let $a,b$ be fermionic variables, $a\, b=-b\, a$. There is already a package that can handle fermionic+bosonic variables, ...
0
votes
1answer
278 views

Two waves interference animation

I would like to plot (or to find) an animation where two waves at different frequencies, propagating with different velocities, sum together $$w_1 (x,t) = \cos(\omega_1 t - k_1 x)\\w_2 (x,t) = \cos(\...
6
votes
1answer
131 views

Using CloudDeploy to build a website for diagrams for Physics/Math teachers

I create a lot of diagrams in Mathematica like the one below for my physics and math study guides. What I'd like to do is create a website where teachers could rapidly customize images like this and ...
2
votes
0answers
535 views

Plotting the Magnetic Field

I have a dataset of $ \textbf{B} = {B_x, B_y, B_z}$. (Quite a big dataset :78*100*150) I want to plot magnetic field lines. If I was working with an analytical function, the magnetic field line ...
4
votes
1answer
996 views

How to implement ladder operators for quantum harmonic oscillator?

I want to write the annihilation and creation operators for the harmonic oscillator, and see how they act on basis states of the form $\lvert n\rangle$. What's the best approach to implement this in ...
1
vote
0answers
180 views

Heat diffusion equation (steady state) [closed]

I am trying to solve this problem: $\lambda \frac{1}{r} \frac{d}{dr}(r \frac{dT}{dr})+S=0$ with $S$ being a const source term... and the boundary contions: $T(r1) =T1$ $T(r2) =T2$ Numeric values:...
1
vote
0answers
57 views

Mathematica, why am i geting imaginary numbers? [closed]

Just started using Mathematica and would appreciate any help resolving this issue - which I believe is in the sys of eq (second line below) ...
4
votes
3answers
788 views

show a trajectory of a projectile by position vector and velocity vector

We are so motivated to show the projectile motion but emphasize to vector algebra. We could find some help in SE for the projectile motion but non of them have been satisfied our aims. Please see the ...
5
votes
1answer
480 views

Two-Point correlation function of Ising data is not giving expected results

Due to the nature of my problem, and readers perhaps not having a physics background, I need to give some context to my problem which is intrinsic to it. The problem however is not a physics one, but ...
12
votes
1answer
327 views

Compute the curvature of a bent stack of paper

My goal is to link the curvature of a bent stack of paper in a wind tunnel to its bending modulus $B$, knowing all the other physical properties. To this end, I would like to reproduce the numerical ...
1
vote
1answer
78 views

What is the meaning of the highlighted expression ? [closed]

I am using GRQUICK package for calculation of Ricci tensors. I am using a non diagonal metric with coefficients being functions of two co-ordinates. I want to know if the highlighted expression ...
3
votes
1answer
600 views

How to program mathematica (simple example) [closed]

How do I program mathematica to perform basic second quantization operation of creation and annihilation operators such as c† and commutation rules for c†c. I know that out there there are libraries ...
0
votes
1answer
117 views

Calculating minimum potential energies for Thomson problem

I have found a table of values for minimum potential energies up to 470 electrons on Wikipedia. However, the method I used for calculating energies is not efficient enough for configurations that have ...
2
votes
1answer
270 views

Solving a BC Differential equation, (Buckling) any way possible

I am trying to verify my manual solution for this problem by any way, so I tried NDSolve, and DSolve, with no success. Can some one help, or even give me the final numbers :D I need the first 3 ...
1
vote
2answers
164 views

Mathcad to Mathematica: finding coil impedance

I am new to Mathematica. I am trying to figure out how to do the same thing in Mathematica as the image depicts done in Mathcad. Declaring the variables with units I figured out. ...
3
votes
2answers
385 views

Derivatives of a four vector

How can I take partial derivatives of four vectors in Mathematica? For instance I need to evaluate following simple terms; $\frac{\partial x^\beta}{\partial x^\delta} = g^{\beta \delta}$ $\frac{\...
7
votes
1answer
615 views

2d solution to 3d using axial symmetry - Finite Element

This problem is axially symmetric. I want to solve using the Finite Element method and taking advantage of the symmetry. (Note: eleField3D needs to be called with ...
-1
votes
1answer
610 views

Working with four-vectors (4-vectors)

Given an expression $\chi\,=\,C_{p1}\,\left[ h\,e^{- i\,p1.\,x}\,\, +\,\,h^{\dagger}\,e^{+i\,p1\,.\,x}\right]$ where $p1$ and $x$ are four-vectors; $C_{p1} = \ \frac{1}{\sqrt{(2 \pi)^3} \sqrt{2 \...
4
votes
2answers
285 views

Calculating the current through coil with a flyback diode using NDSolve

I plan to simulate the current through a coil with flyback (or freewheel) diode for an arbitrary voltage signal (square or PWM modulated signal is possible). You can find the circuit diagram over ...
11
votes
1answer
376 views

multiplication of vector spaces

Original Question Disclaimer: The question motivated by the product of Hilbert spaces which arises from separate degrees of freedom which a system might contain in quantum technical system. Examples ...
5
votes
1answer
263 views

Laplace equation conducting sphere

I'm trying to solve the Laplace equation for a conducting sphere of radius $r$ and potential $V0$. I impose that on the surface the potential is $V0$ and that at long distance from the center the ...
0
votes
1answer
91 views

How can I obtain a list of the physical quantities supported? [duplicate]

How can we list all available physical quantities in Mathematica?
3
votes
1answer
173 views

Bug recognizing “Wavenumbers” as a unit of energy?

Wavenumbers, aka inverse centimeters, has dimensions of energy and thus should be easily convertible to joules. MMA clearly recognizes "Wavenumbers" at some level, since it autosuggests this unit when ...
4
votes
2answers
466 views

simulation with kinetic friction, weird results

I would like to simulate a point mass that is moving on a circular rail considering kinetic friction. The mass point starts at the bottom of the rail with an initial velocity v0. for the derivation of ...
4
votes
1answer
88 views

Dynamics problem [closed]

This is school work. I do not want the problem solved for me, but I just want to know what I did wrong with my ParametricPlot. Question: A material point moves ...
7
votes
1answer
532 views

Free Convective Heat Transfer of Non-Newtonian Power Law Fluids from a Vertical Plate

I am trying to solve a set of PDEs mentioned in this paper with NDSolve but facing quite a few issues. The PDE system is: ...
0
votes
1answer
496 views

How can I plot a space time diagram in mathematica?

"Using Mathematica, construct space-time diagrams for which the speed of $S’$ moving in the positive x-direction with respect to $S$ and at speed $V$ with respect to $S$ for: (a) $V=0.1c$; (b) $V=0....
1
vote
1answer
391 views

Plotting electric field of charged particle

I am trying to plot the electric field of a charged particle in (2,4). The diagram is the next: We know: $ \overrightarrow{E} = \frac{1}{4 \pi \epsilon_0} \frac{q'}{|\overrightarrow{R}|^2} \widehat{...
9
votes
2answers
543 views

Wonky Solutions to Schrödinger Equation with Box Barrier

I'm trying to solve the Schrödinger equation using NDSolve in a case where there is a potential box barrier. The initial condition is a cosine wave, and for ...
3
votes
1answer
509 views

Hadamard Lemma and commutators algebra

I would like to implement the following formula, which goes under the name of Hadamard Lemma: $ e^A \, B \, e^{-A} = \sum_{k=0}^{+\infty} \frac{1}{k!} [A,B]_k $ where $ [A,B]_0 = B , \...
-7
votes
1answer
183 views

Can one use the new random matrices features of Version 11 in addressing a certain octonionic-based question?

I have cross-posted the question https://math.stackexchange.com/questions/2012301/can-one-test-an-octonionic-interpretation-for-a-conjecture-apparently-valid-in and https://physics.stackexchange....
3
votes
1answer
131 views

Trying to plot S curve with Mathematica filling in the blanks between data points

I'm completely new to Mathematica and trying to figure some stuff out as a first practical project. I'm trying to plot a calibration curve to fit some data to. As my first step I'm attempting to graph ...
0
votes
1answer
56 views

Limit converges when I plug in numbers, but diverges when I leave in terms of variables [closed]

I have an expression such as the following $$\frac{ab+a^2c+bx-acx+2adx-(a-x)\sqrt{b^2+2abc+a^2c^2+4acdx}}{2ax}$$ which describes a physical system that I want to find the limit as $x$ goes to 0. If ...
4
votes
2answers
224 views

Solving a nonlinear system of ODE with DSolve

I have been trying to solve the following system of ODE with initial values using the function DSolve. My code is : ...
5
votes
1answer
373 views

Position dependent Neumann condition on boundary mesh

I am trying to solve Laplace equation over a time-dependent region using cylindrical coordinates. My system is independent of the angle coordinate, and so the equation looks like: The region ...
3
votes
0answers
342 views

Solve PDE over time-dependent region

I have some experience with C++ programming, but I am quite new to Mathematica and I think the latter requires a different mindset which I am still not used to. I would like to simulate the effect ...
1
vote
0answers
49 views

How do I get the output of a square-wave input? (singularity problem)

I am trying to get the electrical response of a system to an input square wave. Here is the code: ...
1
vote
0answers
97 views

Simpler way to compute gravity?

I have code for a simple n-body problem: ...
1
vote
1answer
172 views

FeynArts field insertion problem

I'm trying insert this scattering into FeynArts as kaon decay (Up quark and anti strange quark to anti muon and neutrino ): but can't figure out why no field enter into 2->2 topologies ...