Tải bản đầy đủ - 0 (trang)
Phụ lục 2: Code tính toán cháy

# Phụ lục 2: Code tính toán cháy

Tải bản đầy đủ - 0trang

====================================

program main

implicit none

!

real k11,k12,k13,k14,k15,k16,k21,k22,k23,k24,k25,k26

real k31,k32,k33,k34,k35,k36,k41,k42,k43,k44,k45,k46

integer M,n

real t,h,h2,y1,y2,y3,y4,y5,y6,f1,f2,f3,f4,f5,f6

!

data M/3320/,t/0.0/,y1/0.0141/,y2/0.0/,y3/0.867272/, &

y4/0.0/,y5/0.0/,y6/0.0/,h/7200.0/

!

print *

print *,' Runge-Kutta method of order 4'

print *

print 20,'n','U-235','U-236','U-238','Pu-239','Pu-240','Pu-241'

!

print 30,0,y1,y2,y3,y4,y5,y6

h2 = 0.5*h

!

do 10 n = 1,M

k11 = h*f1(t,y1,y2,y3,y4,y5,y6)

k12 = h*f2(t,y1,y2,y3,y4,y5,y6)

k13 = h*f3(t,y1,y2,y3,y4,y5,y6)

k14 = h*f4(t,y1,y2,y3,y4,y5,y6)

k15 = h*f5(t,y1,y2,y3,y4,y5,y6)

k16 = h*f6(t,y1,y2,y3,y4,y5,y6)

k21 = h*f1(t + h2,y1 + 0.5*k11,y2 + 0.5*k12,y3 + 0.5*k13, &

y4 + 0.5*k14,y5 + 0.5*k15,y6 + 0.5*k16)

k22 = h*f2(t + h2,y1 + 0.5*k11,y2 + 0.5*k12,y3 + 0.5*k13, &

y4 + 0.5*k14,y5 + 0.5*k15,y6 + 0.5*k16)

k23 = h*f3(t + h2,y1 + 0.5*k11,y2 + 0.5*k12,y3 + 0.5*k13, &

y4 + 0.5*k14,y5 + 0.5*k15,y6 + 0.5*k16)

k24 = h*f4(t + h2,y1 + 0.5*k11,y2 + 0.5*k12,y3 + 0.5*k13, &

y4 + 0.5*k14,y5 + 0.5*k15,y6 + 0.5*k16)

k25 = h*f5(t + h2,y1 + 0.5*k11,y2 + 0.5*k12,y3 + 0.5*k13, &

y4 + 0.5*k14,y5 + 0.5*k15,y6 + 0.5*k16)

k26 = h*f6(t + h2,y1 + 0.5*k11,y2 + 0.5*k12,y3 + 0.5*k13, &

y4 + 0.5*k14,y5 + 0.5*k15,y6 + 0.5*k16)

k31 = h*f1(t + h2,y1 + 0.5*k21,y2 + 0.5*k22,y3 + 0.5*k23, &

y4 + 0.5*k24,y5 + 0.5*k25,y6 + 0.5*k26)

k32 = h*f2(t + h2,y1 + 0.5*k21,y2 + 0.5*k22,y3 + 0.5*k23, &

59

10

y4 + 0.5*k24,y5 + 0.5*k25,y6 + 0.5*k26)

k33 = h*f3(t + h2,y1 + 0.5*k21,y2 + 0.5*k22,y3

y4 + 0.5*k24,y5 + 0.5*k25,y6 + 0.5*k26)

k34 = h*f4(t + h2,y1 + 0.5*k21,y2 + 0.5*k22,y3

y4 + 0.5*k24,y5 + 0.5*k25,y6 + 0.5*k26)

k35 = h*f5(t + h2,y1 + 0.5*k21,y2 + 0.5*k22,y3

y4 + 0.5*k24,y5 + 0.5*k25,y6 + 0.5*k26)

k36 = h*f6(t + h2,y1 + 0.5*k21,y2 + 0.5*k22,y3

y4 + 0.5*k24,y5 + 0.5*k25,y6 + 0.5*k26)

k41 = h*f1(t + h,y1 + k31,y2 + k32,y3 + k33, &

y4 + k34,y5 + k35,y6 + k36)

k42 = h*f2(t + h,y1 + k31,y2 + k32,y3 + k33, &

y4 + k34,y5 + k35,y6 + k36)

k43 = h*f3(t + h,y1 + k31,y2 + k32,y3 + k33, &

y4 + k34,y5 + k35,y6 + k36)

k44 = h*f4(t + h,y1 + k31,y2 + k32,y3 + k33, &

y4 + k34,y5 + k35,y6 + k36)

k45 = h*f5(t + h,y1 + k31,y2 + k32,y3 + k33, &

y4 + k34,y5 + k35,y6 + k36)

k46 = h*f6(t + h,y1 + k31,y2 + k32,y3 + k33, &

y4 + k34,y5 + k35,y6 + k36)

y1 = y1 + (k11 + 2.0*(k21 + k31) + k41)/6.0

y2 = y2 + (k12 + 2.0*(k22 + k32) + k42)/6.0

y3 = y3 + (k13 + 2.0*(k23 + k33) + k43)/6.0

y4 = y4 + (k14 + 2.0*(k24 + k34) + k44)/6.0

y5 = y5 + (k15 + 2.0*(k25 + k35) + k45)/6.0

y6 = y6 + (k16 + 2.0*(k26 + k36) + k46)/6.0

t = t + h

print 30,n,y1,y2,y3,y4,y5,y6

continue

!

20

30

format(a6,a15,a15,a15,a15,a15,a15)

format(1x,i5,2x,6(e14.8,2x))

stop

end program main

! U-235

function f1(t,y1,y2,y3,y4,y5,y6)

f1 = -698.796e-24*phi*y1

return

end

! U-236

function f2(t,y1,y2,y3,y4,y5,y6)

60

+ 0.5*k23, &

+ 0.5*k23, &

+ 0.5*k23, &

+ 0.5*k23, &

!

!

!

!

f2 = 98.6866e-24*phi*y1 - 14.0222e-24*phi*y2

return

end

U-238

function f3(t,y1,y2,y3,y4,y5,y6)

f3 = - 11.9829e-24*phi*y3

return

end

Pu-239

function f4(t,y1,y2,y3,y4,y5,y6)

f4 = 2.68346e-24*phi*y3 - 1026.63e-24*phi*y4

return

end

Pu-240

function f5(t,y1,y2,y3,y4,y5,y6)

f5 = 270.727e-24*phi*y4 - 288.57e-24*phi*y5

return

end

Pu-241

function f6(t,y1,y2,y3,y4,y5,y6)

f6 = 287.555e-24*phi*y5 - 1386.61e-24*phi*y6

return

end

============================

b) Code tính tốn cháy cho I-135, Xe-135, Pm-149, Sm-149

============================

program main

implicit none

!

real k11,k12,k13,k14,k15,k21,k22,k23,k24,k25

real k31,k32,k33,k34,k35,k41,k42,k43,k44,k45

integer M,n

real t,h,h2,y1,y2,y3,y4,y5,f1,f2,f3,f4,f5

!

data M/3320/,t/0.0/,y1/ 0.0141/,y2/0.0/,y3/0.0/, &

y4/0.0/,y5/0.0/,h/7200.0/

!

print *

print *,' Runge-Kutta method of order 4'

print *

print 20,'n','U-235','I-135','Xe-135','Pm-149','Sm-149'

61

!

print 30,0,y1,y2,y3,y4,y5

h2 = 0.5*h

!

do 10 n = 1,M

k11 = h*f1(t,y1,y2,y3,y4,y5)

k12 = h*f2(t,y1,y2,y3,y4,y5)

k13 = h*f3(t,y1,y2,y3,y4,y5)

k14 = h*f4(t,y1,y2,y3,y4,y5)

k15 = h*f5(t,y1,y2,y3,y4,y5)

k21 = h*f1(t + h2,y1 + 0.5*k11,y2 + 0.5*k12,y3

y4 + 0.5*k14,y5 + 0.5*k15)

k22 = h*f2(t + h2,y1 + 0.5*k11,y2 + 0.5*k12,y3

y4 + 0.5*k14,y5 + 0.5*k15)

k23 = h*f3(t + h2,y1 + 0.5*k11,y2 + 0.5*k12,y3

y4 + 0.5*k14,y5 + 0.5*k15)

k24 = h*f4(t + h2,y1 + 0.5*k11,y2 + 0.5*k12,y3

y4 + 0.5*k14,y5 + 0.5*k15)

k25 = h*f5(t + h2,y1 + 0.5*k11,y2 + 0.5*k12,y3

y4 + 0.5*k14,y5 + 0.5*k15)

k31 = h*f1(t + h2,y1 + 0.5*k21,y2 + 0.5*k22,y3

y4 + 0.5*k24,y5 + 0.5*k25)

k32 = h*f2(t + h2,y1 + 0.5*k21,y2 + 0.5*k22,y3

y4 + 0.5*k24,y5 + 0.5*k25)

k33 = h*f3(t + h2,y1 + 0.5*k21,y2 + 0.5*k22,y3

y4 + 0.5*k24,y5 + 0.5*k25)

k34 = h*f4(t + h2,y1 + 0.5*k21,y2 + 0.5*k22,y3

y4 + 0.5*k24,y5 + 0.5*k25)

k35 = h*f5(t + h2,y1 + 0.5*k21,y2 + 0.5*k22,y3

y4 + 0.5*k24,y5 + 0.5*k25)

k41 = h*f1(t + h,y1 + k31,y2 + k32,y3 + k33, &

y4 + k34,y5 + k35)

k42 = h*f2(t + h,y1 + k31,y2 + k32,y3 + k33, &

y4 + k34,y5 + k35)

k43 = h*f3(t + h,y1 + k31,y2 + k32,y3 + k33, &

y4 + k34,y5 + k35)

k44 = h*f4(t + h,y1 + k31,y2 + k32,y3 + k33, &

y4 + k34,y5 + k35)

k45 = h*f5(t + h,y1 + k31,y2 + k32,y3 + k33, &

y4 + k34,y5 + k35)

y1 = y1 + (k11 + 2.0*(k21 + k31) + k41)/6.0

y2 = y2 + (k12 + 2.0*(k22 + k32) + k42)/6.0

62

+ 0.5*k13, &

+ 0.5*k13, &

+ 0.5*k13, &

+ 0.5*k13, &

+ 0.5*k13, &

+ 0.5*k23, &

+ 0.5*k23, &

+ 0.5*k23, &

+ 0.5*k23, &

+ 0.5*k23, &

10

y3 = y3 + (k13 + 2.0*(k23 + k33) + k43)/6.0

y4 = y4 + (k14 + 2.0*(k24 + k34) + k44)/6.0

y5 = y5 + (k15 + 2.0*(k25 + k35) + k45)/6.0

t = t + h

print 30,n,y1,y2,y3,y4,y5

continue

!

20

30

format(a6,a15,a15,a15,a15,a15)

format(1x,i5,2x,5(e14.8,2x))

stop

end program main

! U-235

function f1(t,y1,y2,y3,y4,y5)

f1 = -698.796e-24*phi*y1

return

end

! I-135

function f2(t,y1,y2,y3,y4,y5)

f2 = 36.7961226e-24*phi*y1 - 2.930607e-5*y2

return

end

! Xe-135

function f3(t,y1,y2,y3,y4,y5)

f3 = 1.507003043e-24*phi*y1 + 2.930607e-5*y2 &

- 2.106574e-5*y3 - 2963950.0e-24*phi*y3

return

end

! Pm-149

function f4(t,y1,y2,y3,y4,y5)

f4 = 6.3272951e-24*phi*y1 - 3.62737158e-6*y4 &

-1432.13e-24*phi*y4

return

end

! Sm-149

function f5(t,y1,y2,y3,y4,y5)

f5 = 3.62737158e-6*y4 - 40966.1e-24*phi*y5

return

end

================================

c) Code tính cháy cho các đồng vị: Gd-157, Tc-99, Sm-151, Nd-143, Cs-137

==============================

63

program main

implicit none

!

real k11,k12,k13,k14,k15,k16,k21,k22,k23,k24,k25,k26

real k31,k32,k33,k34,k35,k36,k41,k42,k43,k44,k45,k46

integer M,n

real t,h,h2,y1,y2,y3,y4,y5,y6,f1,f2,f3,f4,f5,f6

!

data M/3320/,t/0.0/,y1/ 0.0141/,y2/0.0/,y3/0.0/, &

y4/0.0/,y5/0.0/,y6/0.0/,h/7200.0/

!

print *

print *,' Runge-Kutta method of order 4'

print *

print 20,'n','U-235','Gd-157','Tc-99','Sm-151','Nd-143','Cs-137'

!

print 30,0,y1,y2,y3,y4,y5,y6

h2 = 0.5*h

!

do 10 n = 1,M

k11 = h*f1(t,y1,y2,y3,y4,y5,y6)

k12 = h*f2(t,y1,y2,y3,y4,y5,y6)

k13 = h*f3(t,y1,y2,y3,y4,y5,y6)

k14 = h*f4(t,y1,y2,y3,y4,y5,y6)

k15 = h*f5(t,y1,y2,y3,y4,y5,y6)

k16 = h*f6(t,y1,y2,y3,y4,y5,y6)

k21 = h*f1(t + h2,y1 + 0.5*k11,y2 + 0.5*k12,y3 + 0.5*k13, &

y4 + 0.5*k14,y5 + 0.5*k15,y6 + 0.5*k16)

k22 = h*f2(t + h2,y1 + 0.5*k11,y2 + 0.5*k12,y3 + 0.5*k13, &

y4 + 0.5*k14,y5 + 0.5*k15,y6 + 0.5*k16)

k23 = h*f3(t + h2,y1 + 0.5*k11,y2 + 0.5*k12,y3 + 0.5*k13, &

y4 + 0.5*k14,y5 + 0.5*k15,y6 + 0.5*k16)

k24 = h*f4(t + h2,y1 + 0.5*k11,y2 + 0.5*k12,y3 + 0.5*k13, &

y4 + 0.5*k14,y5 + 0.5*k15,y6 + 0.5*k16)

k25 = h*f5(t + h2,y1 + 0.5*k11,y2 + 0.5*k12,y3 + 0.5*k13, &

y4 + 0.5*k14,y5 + 0.5*k15,y6 + 0.5*k16)

k26 = h*f6(t + h2,y1 + 0.5*k11,y2 + 0.5*k12,y3 + 0.5*k13, &

y4 + 0.5*k14,y5 + 0.5*k15,y6 + 0.5*k16)

k31 = h*f1(t + h2,y1 + 0.5*k21,y2 + 0.5*k22,y3 + 0.5*k23, &

y4 + 0.5*k24,y5 + 0.5*k25,y6 + 0.5*k26)

k32 = h*f2(t + h2,y1 + 0.5*k21,y2 + 0.5*k22,y3 + 0.5*k23, &

y4 + 0.5*k24,y5 + 0.5*k25,y6 + 0.5*k26)

64

10

k33 = h*f3(t + h2,y1 + 0.5*k21,y2 + 0.5*k22,y3

y4 + 0.5*k24,y5 + 0.5*k25,y6 + 0.5*k26)

k34 = h*f4(t + h2,y1 + 0.5*k21,y2 + 0.5*k22,y3

y4 + 0.5*k24,y5 + 0.5*k25,y6 + 0.5*k26)

k35 = h*f5(t + h2,y1 + 0.5*k21,y2 + 0.5*k22,y3

y4 + 0.5*k24,y5 + 0.5*k25,y6 + 0.5*k26)

k36 = h*f6(t + h2,y1 + 0.5*k21,y2 + 0.5*k22,y3

y4 + 0.5*k24,y5 + 0.5*k25,y6 + 0.5*k26)

k41 = h*f1(t + h,y1 + k31,y2 + k32,y3 + k33, &

y4 + k34,y5 + k35,y6 + k36)

k42 = h*f2(t + h,y1 + k31,y2 + k32,y3 + k33, &

y4 + k34,y5 + k35,y6 + k36)

k43 = h*f3(t + h,y1 + k31,y2 + k32,y3 + k33, &

y4 + k34,y5 + k35,y6 + k36)

k44 = h*f4(t + h,y1 + k31,y2 + k32,y3 + k33, &

y4 + k34,y5 + k35,y6 + k36)

k45 = h*f5(t + h,y1 + k31,y2 + k32,y3 + k33, &

y4 + k34,y5 + k35,y6 + k36)

k46 = h*f6(t + h,y1 + k31,y2 + k32,y3 + k33, &

y4 + k34,y5 + k35,y6 + k36)

y1 = y1 + (k11 + 2.0*(k21 + k31) + k41)/6.0

y2 = y2 + (k12 + 2.0*(k22 + k32) + k42)/6.0

y3 = y3 + (k13 + 2.0*(k23 + k33) + k43)/6.0

y4 = y4 + (k14 + 2.0*(k24 + k34) + k44)/6.0

y5 = y5 + (k15 + 2.0*(k25 + k35) + k45)/6.0

y6 = y6 + (k16 + 2.0*(k26 + k36) + k46)/6.0

t = t + h

print 30,n,y1,y2,y3,y4,y5,y6

continue

!

20

30

format(a6,a15,a15,a15,a15,a15,a15)

format(1x,i5,2x,6(e14.8,2x))

stop

end program main

! U-235

function f1(t,y1,y2,y3,y4,y5,y6)

f1 = -698.796e-24*phi*y1

return

end

! Gd-157

function f2(t,y1,y2,y3,y4,y5,y6)

f2 = 3.65012856e-26*phi*y1 - 254557.0e-24*phi*y2

65

+ 0.5*k23, &

+ 0.5*k23, &

+ 0.5*k23, &

+ 0.5*k23, &

!

!

!

!

return

end

Tc-99

function f3(t,y1,y2,y3,y4,y5,y6)

f3 = 3.59338414e-23*phi*y1 - 28.2699e-24*phi*y3

return

end

Sm-151

function f4(t,y1,y2,y3,y4,y5,y6)

f4 = 2.44896038e-24*phi*y1 - 15168.4e-24*phi*y4

return

end

Nd-143

function f5(t,y1,y2,y3,y4,y5,y6)

f5 = 3.48808522e-23*phi*y1 - 412.5604e-24*phi*y5

return

end

Cs-137

function f6(t,y1,y2,y3,y4,y5,y6)

f6 = 3.71055844e-23*phi*y1 - 3.51144e-24*phi*y6 &

- 7.3095e-10*y6

return

end

================================

Phụ lục 3: Input MCNP cho bài tốn mơ phỏng tồn bộ vùng hoạt lò Tomari

số 3

C ALL CORE PWR

C cell cards

C FUEL ROD GD-24 3.5% (2A)

C fuel rod U02 3.5%

1 6 -10.6409 -1 -4 6 tmp=4.998E-8 u=1 imp:n=1

2 8 -0.001786 1 -2 -4 6 tmp=4.998E-8 u=1 imp:n=1

3 9 -6.44 2 -3 -4 6 u=1 tmp=4.998E-8 imp:n=1

4 10 -8.00 -7 -8 9 #1 #2 #3 u=1 tmp=4.998E-8 imp:n=1

5 14 -0.7187 #1 #2 #3 #4 u=1 tmp=4.998E-8 imp:n=1

66

C fuel rods(U,Gd)02 3.5%

7 1 -10.5312 -1 -4 5 u=3 tmp=4.998E-8 imp:n=1

8 6 -10.6409 -1 -5 6 u=3 tmp=4.998E-8 imp:n=1

9 8 -0.001786 1 -2 -4 6 u=3 tmp=4.998E-8 imp:n=1

10 9 -6.44 2 -3 -4 6 u=3 tmp=4.998E-8 imp:n=1

11 10 -8.00 -7 -8 9 #7 #8 #9 #10 u=3 tmp=4.998E-8 imp:n=1

12 14 -0.7187 #7 #8 #9 #10 #11 u=3 tmp=4.998E-8 imp:n=1

C control rods

13 11 -10.20 -21 -8 25 u=2 tmp=4.998E-8 imp:n=1

14 8 -0.001786 21 -22 -8 25 u=2 tmp=4.998E-8 imp:n=1

15 10 -8.00 22 -23 -8 25 #13 #14 u=2 tmp=4.998E-8 imp:n=1

16 14 -0.7187 #13 #15 #14 u=2 tmp=4.998E-8 imp:n=1

C Burnable poison rods

200 like 13 but mat=12 u=12 tmp=4.998E-8 imp:n=1

201 like 14 but u=12 tmp=4.998E-8 imp:n=1

202 like 15 but u=12 tmp=4.998E-8 imp:n=1

203 like 16 but u=12 tmp=4.998E-8 imp:n=1

C In-core Guide thimbles

17 14 -0.7187 -31 -8 34 u=4 tmp=4.998E-8 imp:n=1

18 10 -8.00 31 -32 -8 34 #17 u=4 tmp=4.998E-8 imp:n=1

19 14 -0.7187 #17 #18 u=4 tmp=4.998E-8 imp:n=1

C FUEL ROD GD-24 3.5% (2A)

20 14 -0.7187 47 -48 49 -50 45 -46 fill=5 tmp=4.998E-8 imp:n=1 u=101

1001 14 -0.7187 #20 u=101 tmp=4.998E-8 imp:n=1

21 14 -0.7187 41 -42 43 -44 lat=1 imp:n=1 u=5 fill=-8:8 -8:8 0:0&

11111111111111111&

11111311111311111&

11311111111111311&

67

### Tài liệu bạn tìm kiếm đã sẵn sàng tải về

Phụ lục 2: Code tính toán cháy

Tải bản đầy đủ ngay(0 tr)

×