diff --git a/besseltransforms/runit.sh b/besseltransforms/runit.sh new file mode 100755 index 0000000..d277388 --- /dev/null +++ b/besseltransforms/runit.sh @@ -0,0 +1,11 @@ +#!/bin/bash +K=$1 +Q=$2 +N=$3 +module load mathematica +cat - vzor.m <<<" +kk=$K; +qq=$Q; +nn=$N; +" | math -noprompt > "${K}-${Q}-${N}" + diff --git a/besseltransforms/vzor.m b/besseltransforms/vzor.m new file mode 100644 index 0000000..85ce73d --- /dev/null +++ b/besseltransforms/vzor.m @@ -0,0 +1,6 @@ +$Assumptions = k >= 0 && k0 >= 0 && c >= 0 && n >= 0 ; +Refine[Integrate[(1 - Exp[-c x])^\[Kappa] (k0 x)^(-q) Exp[ + I k0 x] x BesselJ[n, k x] Exp[-c x], {x, + 0, \[Infinity]}], {\[Kappa] == kk, q == qq, n == nn}] +Series[%, {k, \[Infinity], 10}] +Quit[ ] diff --git a/qpms/tmatrices.py b/qpms/tmatrices.py index 9b765d7..7546595 100644 --- a/qpms/tmatrices.py +++ b/qpms/tmatrices.py @@ -152,7 +152,7 @@ def _scuffTMatrixConvert_EM_01(EM): else: return None -def loadScuffTMatrices(fileName): +def loadScuffTMatrices(fileName, normalisation = 1): """ TODO doc """ @@ -182,7 +182,10 @@ def loadScuffTMatrices(fileName): for outc_type in [0,1]: TMatrices[:,1-outc_type,:,1-inc_type,:] = TMatrices_tmp_real[:,:,outc_type,:,inc_type]+1j*TMatrices_tmp_imag[:,:,outc_type,:,inc_type] # IMPORTANT: now we are going from Reid's/Kristensson's/Jackson's/whoseever convention to Taylor's convention - TMatrices[:,:,:,:,:] = TMatrices[:,:,:,:,:] * np.sqrt(ny*(ny+1))[ň,ň,ň,ň,:] / np.sqrt(ny*(ny+1))[ň,ň,:,ň,ň] + if normalisation == 1: + TMatrices[:,:,:,:,:] = TMatrices[:,:,:,:,:] * np.sqrt(ny*(ny+1))[ň,ň,ň,ň,:] / np.sqrt(ny*(ny+1))[ň,ň,:,ň,ň] + elif normalisation == 2: # Kristensson? + pass return (TMatrices, freqs, freqs_weirdunits, lMax)