Screamer Project  V3.3.1
Screamer Structure
 All Files Functions Variables
r2wallmdl.f
Go to the documentation of this file.
1  Subroutine r2wall (time, curr, parms, rvar)
2 c
3 c Define passed variables
4 c
5  real time, curr, parms(*), rvar
6 c
7 c Stygar Resistive Wall Model
8 c
9 c Author/Date: Rick Spielman 2012-03-08
10 c Modifications:
11 c
12 c 2012-04-02 RBS: Changed the name of the subroutine to r2wall to make
13 c it easier to use a shortened name in the input deck
14 c 2013-12-07 RBS: Changed the subroutine to arbitrary upper and lower
15 c disks and separate cylindrical elements
16 c
17 c Version 1 - one disk (2 identical elements, i.e. X2 below) and
18 c one coax (two identical elements)
19 c
20 c Version 2 – one disk (2 separate elements) and one coax (two
21 c separate cylindrical elements)
22 c
23 c This routine estimates the resistive losses in the wall at very high
24 c current densities. This subroutine is based on the Phys. Rev. ST
25 c Accel Beams 11, 120401 (2008).
26 c In Eq. 35, the resistance R for a transmission line is described as
27 c
28 c Reff(t)[Ohms] = 2piCHI1(1/t^.5)[SUMi(li/ai) + SUMj(ln(cj/bj)] +
29 c 2piCHI2(t^.25)I^2[SUMi(li/ai^3) + .5SUMj(1/bj^2
30 c - 1/cj^2)]
31 c
32 c where CHI1 = 3.36E-08, CHI2 = 3.7548E-22, li - length of a cylindrical
33 c line, ai - radius of a cylindrical line, bj - inner disk radius,
34 c cj - outer disk radius of each disk segment.
35 c The values of CHI are for Z-like SS conductor geometries.
36 c The resistance can be made up of the sum of the disk and cylindrical
37 c pieces. This is EACH side of the elements.
38 c
39 c
40  parameter(chi1=3.36e-08, chi2=3.7548e-22, pi=3.14159)
41 c
42  t_in = parms(1)
43  cyl_lin = parms(2)
44  cyl_lo = parms(3)
45  cyl_rin = parms(4)
46  cyl_ro = parms(5)
47  d_urin = parms(6)
48  d_urout = parms(7)
49  d_lrin = parms(8)
50  d_lrout = parms(9)
51 
52 c
53 c Calculate the resistance
54 c
55 c
56  if(time .le. t_in) then
57  rvar=0.0
58  else
59  t = time-t_in+1e-10
60  t1 = 1.0/t**.5
61  t2 = t**.25
62 c t is adusted from zero to prevent problems with divide by zero.
63 c Initial tests use a constant resistance but all else is included
64 c
65  rvar = 2*pi*(chi1*t1*
66  & (cyl_lin/cyl_rin + cyl_lo/cyl_ro +
67  & log(d_urout/d_urin) + log(d_lrout/d_lrin)) +
68  & chi2*t2*curr**2*(cyl_lin/cyl_rin**3 + cyl_lo/cyl_ro**3 +
69  & .5*(1/d_urin**2 - 1/d_urout**2 +
70  & 1/d_lrin**2 - 1/d_lrout**2)))
71 
72  endif
73  return
74  end
c *****************************************************************************c Various format statements for read_screamer_data output c To get these into made format to be characters c for each line corrected spelling errors in format added statement for Zflow Plasma Loss Model added format for CSV output type fixed more lines longer than characters added format for Measure Zflow Block and forward c reverse current directions in Zflow plasma loss c and Zflow POS models added format for SFC output type c removed from all code calls c c c c c a80 c i10 c No grids on plots c Do not write files containing the plotted points c Execute only one cycle c Do not echo the setup parameters and indicies c c &exitting c a13 c c c c c c c c102 c &described as a function of time c c c &described as a function of time c c c &function of time c c shell c &min A K c &trapped field time
Definition: zdemfmt.h:85
subroutine r2wall(time, curr, parms, rvar)
Definition: r2wallmdl.f:1