You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The code below shows that when you call IsothermalDiskPotential, the second derivative does not give the amplitude (density) entered when the potential is initialized. However, pot._evaluate() does give the correct amplitude.
from galpy.potential import IsothermalDiskPotential,turn_physical_off
import numpy as np
z= np.linspace(-0.1,0.1,10001)
pot= IsothermalDiskPotential(amp=0.1, sigma=20.5/220.)
turn_physical_off(pot)
p1= 1./(np.pi*4)*np.gradient(np.gradient(pot(z),z),z)
p2= 1./(np.pi*4)*np.gradient(np.gradient(pot._evaluate(z),z),z)
print(p1[5000]) #Result is: 0.01
print(p2[5000]) #Result is: 0.1
The text was updated successfully, but these errors were encountered:
The code below shows that when you call IsothermalDiskPotential, the second derivative does not give the amplitude (density) entered when the potential is initialized. However, pot._evaluate() does give the correct amplitude.
The text was updated successfully, but these errors were encountered: