Skip to content

Commit

Permalink
Fix bad capitalization of GetVpCon, GetVpCov
Browse files Browse the repository at this point in the history
  • Loading branch information
brryan committed Dec 12, 2023
1 parent bda457b commit d73c044
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 13 deletions.
4 changes: 2 additions & 2 deletions scripts/python/get_torus_radial_profiles.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@ def get_torus_radial_profiles(dfile):
Pg = dfile.GetPg()
ucon = dfile.Getucon()
ucov = dfile.Getucov()
vpcon = dfile.GetVpcon()
vpcov = dfile.GetVpcov()
vpcon = dfile.Getvpcon()
vpcov = dfile.Getvpcov()
bsq = dfile.GetPm() * 2
sigma = bsq / rho
alpha = dfile.alpha
Expand Down
22 changes: 11 additions & 11 deletions scripts/python/phoedf.py
Original file line number Diff line number Diff line change
Expand Up @@ -234,7 +234,7 @@ def Getbcon(self):

Bcon = self.GetBcon()
Gamma = self.GetGamma()
vcon = self.GetVpCon() / Gamma[:, np.newaxis, :, :, :]
vcon = self.Getvpcon() / Gamma[:, np.newaxis, :, :, :]
ucon = self.Getucon()
gcov = self.gcov
alpha = self.alpha
Expand Down Expand Up @@ -394,7 +394,7 @@ def GetGamma(self):
if self.Gamma is None:
self.Gamma = np.zeros(self.ScalarField)

vpcon = self.GetVpCon()
vpcon = self.Getvpcon()
for ii in range(3):
for jj in range(3):
self.Gamma[:, :, :, :] += (
Expand All @@ -406,18 +406,18 @@ def GetGamma(self):

return self.Gamma

def GetVpcov(self):
def Getvpcov(self):
if self.vpcov is None:
self.vpcov = np.zeros(self.ThreeVectorField)

vpcon = self.GetVpCon()
vpcon = self.Getvpcon()
for ii in range(3):
for jj in range(3):
vpcov[:,ii,:,:,:] += self.gcov[:, ii + 1,jj + 1,:,:,:]*vpcon[:,jj,:,:,:]

return self.vpcov

def GetVpcon(self):
def Getvpcon(self):
if self.vpcon is None:
self.vpcon = self.Get("p.velocity", flatten=False)
assert self.vpcon is not None
Expand All @@ -428,13 +428,13 @@ def GetVpcon(self):

# Backwards compatibility TODO(BRR) remove?
def GetVpCon(self):
return self.GetVpcon()
return self.Getvpcon()

def Getucon(self):
if self.ucon is None:
self.ucon = np.zeros(self.FourVectorField)

vpcon = self.GetVpCon()
vpcon = self.Getvpcon()
Gamma = self.GetGamma()

self.ucon[:, 0, :, :, :] = Gamma[:, :, :, :] / self.alpha[:, :, :, :]
Expand Down Expand Up @@ -470,7 +470,7 @@ def GetXi(self):

Hcov = self.GetHcov() / self.GetJ()[:, np.newaxis, :, :, :]
Gamma = self.GetGamma()
vcon = self.GetVpCon() / Gamma[:, np.newaxis, :, :, :]
vcon = self.Getvpcon() / Gamma[:, np.newaxis, :, :, :]
for ispec in range(self.NumSpecies):
vdH = np.zeros(self.ScalarField)
for ii in range(3):
Expand Down Expand Up @@ -499,7 +499,7 @@ def GetE(self):
)

Gamma = self.GetGamma()
vcon = self.GetVpCon() / Gamma[:, np.newaxis, :, :, :]
vcon = self.Getvpcon() / Gamma[:, np.newaxis, :, :, :]
J = self.GetJ()
Hcov = self.GetHcov()

Expand Down Expand Up @@ -529,7 +529,7 @@ def GetF(self):
)

Gamma = self.GetGamma()
vcon = self.GetVpCon() / Gamma[:, np.newaxis, :, :, :]
vcon = self.Getvpcon() / Gamma[:, np.newaxis, :, :, :]
J = self.GetJ()
Hcov = self.GetHcov()
gammacon = self.gammacon
Expand Down Expand Up @@ -572,7 +572,7 @@ def GetP(self):
)

Gamma = self.GetGamma()
vcon = self.GetVpCon() / Gamma[:, np.newaxis, :, :, :]
vcon = self.Getvpcon() / Gamma[:, np.newaxis, :, :, :]
J = self.GetJ()
Hcov = self.GetHcov()
gammacon = self.gammacon
Expand Down

0 comments on commit d73c044

Please sign in to comment.