Electrical Proerties of a torus

Program to calculate inductance of a toroid and field strength inside.

Private Sub cmdCalculate_Click()
Dim FileNumber, ret
Dim FileName As String
FileNumber = FreeFile()
Rem to calculate magnetic flux
pi = 3.1415926: turns = 100
rt = 0.01: rmid = 0.075: total_flux = 0: i_1 = 1
A = pi * 0.0000004: i = i_1 * turns / (2 * pi * rmid)
total_force = 0: length = rmid * 2 * pi
rmid = 0.075: delta_delta_deg = 10: delta_psi_deg = 10
delta_l = delta_psi_deg * pi * rt / 180
delta_delta = delta_delta_deg * pi / 180
delta_d = delta_delta * rmid
FileName = InputBox("Enter file name, including path", "File Name", ".\TorDat.txt")
Open FileName For Output As FileNumber
ret = MsgBox("Coil diameter 2cm on torus 7.5cm dia current 1A 100 Turns" + vbCrLf + "No loss in induced current in surface layer of plasma")
Print #FileNumber, "Coil diameter 2cm on torus 7.5cm in dia current 1A 100 Turns"
Print #FileNumber, "No loss in induced current in surface layer of plasma"
Print #FileNumber, " "
Print #FileNumber, Tab(10); "Mag Flux Wb/M^2"; Tab(30); "Pressure Pa";
Print #FileNumber, Tab(44); "Angle Dist from Centre m"
For psi1_deg = 0 To 90 Step 45
psi1 = psi1_deg * pi / 180
For r0_l = -9 To 9 Step 1
r0 = 0.1 * rt * r0_l
For delta_deg = -180 To 170 Step delta_delta_deg
delta = delta_deg * pi / 180
For psi2_deg = 0 To 350 Step delta_psi_deg
psi2 = psi2_deg * pi / 180
GoSub find
GoSub force
ret = DoEvents()
total_force = total_force + f
total_flux = total_flux + f * (pi / 4) * (Abs(r0) + 0.1 * rt) * 0.1 * rt
Next
Next
Print #FileNumber, Tab(13); " ";
Print #FileNumber, total_force;
Print #FileNumber, Tab(29); " ";
Print #FileNumber, total_force * i;
Print #FileNumber, Tab(46);
Print #FileNumber, psi1_deg;
Print #FileNumber, Tab(59); " ";
Print #FileNumber, r0

total_force = 0
Next
Next
inductance = total_flux / i_1
old_inductance = A * pi * (rt ^ 2) * (turns ^ 2) / length
ratio = inductance / old_inductance
Print #FileNumber, "Computed inductance "; inductance
Print #FileNumber, "Calculated inductance "; old_inductance
Print #FileNumber, "ratio new/old "; ratio
Close FileNumber
ret = MsgBox("Results in" + vbCrLf + FileName)
End
force:
f = A * i * delta_l * sin_chi * delta_d * cos_sigma / sep_sq
If delta_deg < -90 And delta_deg > 90 And psi_deg < 270 And psi_deg > 90 Then
f = -f
End If
Return
find:
sep1 = (rmid + rt * Cos(psi2)) * Sin(delta)
sep2 = (rmid + rt * Cos(psi2)) * Cos(delta) - (rmid + r0 * Cos(psi1))
sep3 = rt * Sin(psi2) - r0 * Sin(psi1)
tp1 = rt * Sin(psi2) * Sin(delta)
tp2 = rt * Sin(psi2) * Cos(delta)
tp3 = rt * Cos(psi2)
Rem find cos_sigma
cos_sigma = tp3 * sep2 - sep3 * tp2
div = Sqr((tp3 * sep2 - sep3 * tp2) ^ 2 + (sep3 * tp1 - sep1 * tp3) ^ 2 + (sep1 * tp2 - sep2 * tp1) ^ 2)
If div = 0 Then
cos_sigma = 1
Else
cos_sigma = Abs(cos_sigma / div)
End If
Rem find sin_chi
cos_chi_sq = (tp1 * sep1 + tp2 * sep2 + tp3 * sep3) ^ 2
div = (tp1 ^ 2 + tp2 ^ 2 + tp3 ^ 2) * (sep1 ^ 2 + sep2 ^ 2 + sep3 ^ 2)
If div = 0 Then
cos_chi_sq = 1
Else
cos_chi_sq = cos_chi_sq / div
End If
If cos_chi_sq > 1 Then cos_chi_sq = 1: Rem to avoid rounding error
sin_chi = Sqr(1 - cos_chi_sq)
Rem find sep_sq
sep_sq = sep1 ^ 2 + sep2 ^ 2 + sep3 ^ 2
Rem end of find
Return
Rem End of program text


End Sub
Results of calculation

Installation Executable file to calculate inductance of farady coil (A toroidal inductance). 1.4 MB Visual Basic 

This file is for test only and is not promised to give the correct answer.

Note:

 

In this diagram, it may be seen that the surface area of the plasma is much less than the surface area of the inside of the torus of windings that contain it.  Thus there will be a force toward the centre, which is constant along the radius but the area of a torus at a particular radius will decrease toward the circle of the centre.  Thus as the plasma contracts the pressure on it will increase. The area is 2(pi)rl, where l is the length of a line drawn round the circle of the torus of the plasma at the point.  So as the radius of the plasma decreases the pressure increases as 1/r.  Thus near the centre the pressure will increase very rapidly without any stress on the containing torus of windings.  This makes the achievement of very high pressure possible through moderate current in the windings.

 

See also Fusion

 

 Graphical Result