Read about mathematica | 118 Discussions | Page 1

  1. S

    Mathematica Definite integral with some unknown variables

    I am trying to evaluate an integral with unknown variables ##a, b, c## in Mathematica, but I am not sure why it takes so long for it to give an output, so I just decided to cancel the running. The integral is given by, ##\int_0^1 dy \frac{ y^2 (1 - b^3 y^3)^{1/2} }{ (1 - a^4 c^2 y^4)^{1/2} }##
  2. JD_PM

    Mathematica Is Mathematica the best option to compute the eigenvalues?

    I am wondering what's the best option to compute the eigenvalues for such a determinant $$\begin{vmatrix} \sin \Big( n \frac{\omega}{v_1} \theta \Big) & \cos \Big( n \frac{\omega}{v_1} \theta \Big) & 0 & 0 \\ 0 & 0 & \sin \Big( n \frac{\omega}{v_2} (2 \pi - \theta) \Big) & \cos \Big( n...
  3. S

    A Calculating the Gravitational wave spectrum with Inflation as a source

    I am interested in knowing how to calculate the gravitational wave (GW) spectrum with inflation as a source, I have some background in inflation but I am not so familiar about calculating the GW spectrum. I am reading a paper ( about it, however, a big part of it...
  4. P

    What specs should I look for in a laptop

    After completing my sophomore year at college as a Physics major and I realized that the laptop I currently have is not able to keep up with the demand I put it under for school. The laptop I currently have has a <2 hour battery life and has been known to crap out (didn't know how else to...
  5. S

    Mathematica Solving 2-D partial integro-differential equation

    While reproducing a research paper, I came across the following equation, ∂f/∂t−(H(f)(∂f/∂x)=0 where [H(f)] is hilbert transform of 'f.' and f=f(x,t) and initial condition is f(x,0)=cos(x) and also has periodic boundary conditions given by F{H{f(x′,t)}}=i⋅sgn(k)F{f(x,t)}, where F(f(x,t) is...
  6. Ackbach

    Wolfram releases the free Wolfram Engine for Developers

    Wolfram made what I would call a gigantic move: they released the Wolfram Engine for Developers - for zero cost! The idea of the Engine is primarily that you can call and run Wolfram Language commands from lots of different sources. I am not the kind of person to automate Mathematica, although...
  7. A

    Mathematica Calculating traces with FeynCalc

    Hello everybody! I need a little help with FeynCalc. I think the problem is really simple but I can't find how to fix it. I want to evaluate a trace coming from a Feynman diagram. Since the particles are all massless, I want to impose the condition on the momentum ##p^2=k^2=p'^2=0##. I've...
  8. A

    Mathematica plotting

    Homework Statement Homework Equations E= kq/r^2 * r-hat where q= +/-(1.6*10^-19) The Attempt at a Solution x= (1.6*10^-19)*x/(x^2+y^2+(z+1)^2)^(3/2) - (1.6*10^-19)*x/(x^2+y^2+(z-1)^2)^(3/2) y= (1.6*10^-19)*y/(x^2+y^2+(z+1)^2)^(3/2) - (1.6*10^-19)*y/(x^2+y^2+(z-1)^2)^(3/2) z=...
  9. A

    Using Mathematica to solve an ODE

    Homework Statement Homework Equations The Attempt at a Solution I used the NDSolve function from mathematic but its giving me problems. What is the correct way to enter the equation?[/B] soln = NDSolve[{y''[t] = (-9.8/5)*sin (t), y[0] = 20, y, {x, 0, 12}}]
  10. C

    Mathematica Cannot do the integral of the Hyper-geometric function?

    Dear friends: It's strange that Mathematica can do the integral of ##\int_0^\infty dx~x~_2F_1(a,b,c,1-x^2)##, however, fails when it's changed to ##\int_0^\infty dx~x~_2F_1(a,b,c,1-x-x^2)##. Are there any major differences between this two types? Is it possible to do the second kind of integral...
  11. L

    Linear Algebra - Find an orthogonal matrix P

    A problem that I have to solve for my Linear Algebra course is the following We are supposed to use Mathematica. What I have done is that I first checked that A is symmetric, i.e. that ##A = A^T##. Which is obvious. Next I computed the eigenvalues for A. The characteristic polynomial is...
  12. C

    Mathematica Is this a bug in Mathematica 11 ?

    I calculated a simple complex function integration using Mathematica 11. As the screenshot shows, the only difference between the two inputs is that I set a = 1 in the second one. However, the two outputs differ by a factor of 2. What's wrong? Is this a bug?
  13. Necmi

    Mathematica Solve Perturbation problem with mathematica

    u'(1-epsilon(u')^2)=-y uo(1)=0 u1(1)=0 I need solve this problem with mathematica.
  14. RicardoMP

    Mathematica How to append functions to a list of functions?

    My objective is to make a list of functions and afterwards be able to make operations with those functions. Hyfield[list_, bits_] := Module[{i, auxList, Hy}, auxList[a_] := List[]; For[i = 1, i <= bits*2, i++, auxList[a] = Append[auxList[a]...
  15. W

    Mathematica Is the integral for current correct?

    Hi, I am using Mathematica to calculate density of states and current of the Green's function times self energy in most simple form. I am not sure if I am getting current integral over energy implemented correctly. Shouldnt first current plot be a line with a slope? Below is my code...
  16. W

    Mathematica Add a rectangle to a plot to indicate range

    I have some data points that I want to plot and suppose I have the function ##f(x) = x##, with the domain having the range ##0\leq x \leq 10##. Assume that the experimental values lies in the range ##4\leq x \leq 7##, how can I put a rectangular region to cover this range behind my plot so as to...
  17. M

    A EoM in Schwarzschild geometry: geodesic v Hamilton formalism

    Hi there guys, Currently writing and comparing two separate Mathematica scripts which can be found here and also here. The first one I've slightly modified to suit my needs and the second one is meant to reproduce the same results. Both scripts are attempting to simulate the trajectory of a...
  18. hbz88

    Mathematica For looping problem not getting answer

    Hi, I need some helps. I try to run the code below but its keep give me the value of intial value. Q = 1415; \[Mu] = 1000; \[Sigma] = 500; double dx; double x; double fx; double fxplusdx; double I1; double I2; I1 = 0; I2 = 0; For[x = 0, x <= Q - dx, dx += 0.01, fx = PDF[NormalDistribution[0...
  19. Q

    Mathematica Mathematica: Convolution Integral

    Hi all! I'm new to Mathematica. I have written a code for performing a convolution integral (as follows) but it seems to be giving out error messages: My code is: a[x_?NumericQ] := PDF[NormalDistribution[40, 2], x] b[k_?NumericQ, x_?NumericQ] := 0.0026*Sin[1.27*k/x]^2 c[k_?NumericQ...
  20. W

    Mathematica Rescaling equations in Mathematica

    Suppose I have a differential equation $$\ddot \phi + 3H (1+Q) \dot \phi + V_{,\phi} = 0$$ where ##\phi## is the inflaton field. ##H## is the Hubble parameter, ##Q## is just a number, ##V_{,\phi}## is the derivative with respect to ##\phi##, and initial conditions given by ##\phi[0] = 2...
  21. F

    Mathematica Plotting with base 10 as the interval

    I want to plot a function f(x) such that it's domain is from 1 to 10000 but I want the graph to read 1, 10, 100, 1000, 10000 in the x-axis, while the y-axis is normal. ##f(x) = 2\sin^{-1} ( e^{-\frac{60}{x}})##
  22. S

    I Hubble term versus inflaton

    From cosmology, ##H^2 = \frac{ρ}{3M_p^2} = \frac{1}{3M_p^2}(½\dot φ^2 + ½m^2φ^2)## Suppose ##V(φ) = ½m^2φ^2## where ##ρ## = density ##M_p## = planck mass I want to graph ##H## vs. ##φ## but there is a ##\dot φ## and I know this is a differential equation, can somebody help me what to do here?
  23. S

    Mathematica Numerical Simulations

    I'm very new to Mathematica/programming and I want to do a theoretical calculation using Mathematica, suppose I have, ##Y=CX,~~~C=constant## Now, I want to plot Y vs. X but X should run at every point since every point is a solution for Y, how should I do this? Before, I was thinking maybe I...
  24. ShadowMeson

    Declare a Commutation Relationship in FeynCalc

    Homework Statement I am a rookie to the QFT extension in Mathematica called FeynCalc, and tried to use that into solving some quiz. Soon I met a problem upon some condition presented in a problem which declares an relation of two same tensor with different indices results in some value when...
  25. Stella.Physics

    Mathematica Graph Plotting Problem in Mathematica

    Hello to all. I've been trying to plot some graphs on Mathematica but I have faced some troubles so far. I am working on this paper by Lattimer on binary systems: I am trying to reproduce Figure 11 but something seems to go wrong. Here's what I have...
  26. defaultusername

    Curvature using Mathematica

    Homework Statement Use Mathematica to calculate the Gaussian curvature of the plane Ax+By+Cz=D, in which A, B, C, and D are constants and C≠0. Use the following data: Homework Equations The Attempt at a Solution First I found the line curvature. As here: That code gets the result...
  27. GW150914

    Physics Why wouldn't astronomers use Mathematica?

    Mathematica is fully functional for daily astronomy data analyzing works, and it is much more convenient than python, so why can't them use Mathematica instead of python? It's like when you have warp drive you still travel through space using chemically powered traditional rockets, which is...
  28. C

    Mathematica Trying to define a integrating function in Mathematica

    I need to define a function that integrates a function in some interval and returns its numerical value. I am not allowed to use built in functions for integrating in Mathematica. This is my code that won't work: This is a code from a...
  29. N

    Mathematica How to remove I.0 from output?

    As I found on many websites, they suggest to use Chop[]. I tried that already but it doesn't work. This is my output. {{2 (Conjugate[ I.0] I.0 + (Conjugate[I.0] + Conjugate[Subscript[v, 1]]/Sqrt[ 2]) (I.0 + Subscript[v, 1]/Sqrt[2])) Subscript[\[Lambda], 1] (Conjugate[I.0]...
  30. E

    Mathematica Numerical vs. Monte-Carlo Simulations

    I have an integration that doesn't have a solution in the table of integrals. So, I evaluated it using Mathematica using the command NIntegrate. However, when I compare the result with Monte-Carlo simulations, there is a very small constant gap between the two curves. Is it because of the...