Skip to content
Snippets Groups Projects
Commit d292edd0 authored by Alexis GAMELIN's avatar Alexis GAMELIN
Browse files

[Fix] Coating class with frequency array

parent 52abfc04
No related branches found
No related tags found
No related merge requests found
......@@ -304,7 +304,7 @@ class Coating(WakeField):
bracket = ( (np.sign(f) - 1j) * skin1 *
(alpha * tanh + 1) / (alpha + tanh) )
else:
valid_approx = self.thickness / skin1
valid_approx = self.thickness / np.min(skin1)
if valid_approx < 0.01:
print("Approximation is not valid. Returning impedance anyway.")
bracket = ( (np.sign(f) - 1j) * skin2 - 2 * 1j * self.thickness *
......@@ -352,7 +352,7 @@ class Coating(WakeField):
bracket = ( (1 - 1j*np.sign(f)) * skin1 *
(alpha * tanh + 1) / (alpha + tanh) )
else:
valid_approx = self.thickness / skin1
valid_approx = self.thickness / np.min(skin1)
if valid_approx < 0.01:
print("Approximation is not valid. Returning impedance anyway.")
bracket = ( (1 - 1j*np.sign(f)) * skin2 - 2 * 1j * self.thickness
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment