Created
May 8, 2019 18:22
-
-
Save NanoExplorer/b8d2e1f4fab2598fece6e8c52efd62fb to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from KinMS import KinMS | |
import numpy as np | |
import KinMS_testsuite as kstest | |
#set very simple parameter values for testing | |
xs=1 | |
ys=1 | |
vs=800 | |
nchan=80 | |
cellsize=0.01 | |
dv=vs/nchan | |
inc=90 | |
gassigma=0 | |
sbrad=np.linspace(0,1,100) | |
velrad=sbrad | |
sbprof=np.exp(-sbrad**2/2/(0.2/2.355)**2) #Gaussian with 0.2" FWHM | |
velprof=400*np.arctan(velrad/0.05)/np.pi*2 | |
posang=0 | |
intflux=1 | |
x_cen=0.05 #Changing this to 0 results in the model I would expect | |
y_cen=0 | |
nsamps=1e5 | |
vel_cen=0 | |
cube=KinMS(xs, | |
ys, | |
vs, | |
cellSize=cellsize, | |
dv=dv, | |
beamSize=0, | |
inc=inc, | |
gasSigma=gassigma, | |
sbProf=sbprof, | |
sbRad=sbrad, | |
velRad=velrad, | |
velProf=velprof, | |
fileName=False, | |
diskThick=0, | |
cleanOut=True, | |
ra=0, | |
dec=0, | |
nSamps=nsamps, | |
posAng=posang, | |
intFlux=intflux, | |
inClouds=[], | |
vLOS_clouds=[], | |
flux_clouds=0, | |
vSys=0, | |
restFreq=115.271e9, | |
phaseCen=np.array([x_cen,y_cen]), | |
vOffset=vel_cen, | |
fixSeed=False, | |
vRadial=0, | |
vPosAng=0, | |
vPhaseCen=np.array([x_cen,y_cen]), | |
returnClouds=False, | |
gasGrav=False) | |
kstest.makeplots(cube,xs,ys,vs,cellsize,dv,0.5,posang=posang) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
In Commit b03e162 a bug was fixed regarding the offset between kinematic and morphological centers. My colleague had been using the older version of the code without this fix, and his code contained a workaround for this bug, When the bug was fixed, I needed to remove the workaround.