Subroutine Fcn(n, t, Y, Yprime) Implicit none Integer i, j, n Real*8 Cp, k, L, dx, Rho, t, Y1, Y(n), Yprime(n) Y1 = 50 k = 37.7d0 Rho = 7822.d0 Cp = 444.d0 L = 0.10d0 ! n is the number of nodes in the slab (x). dx = (L - 0.d0)/dble(n - 1) ! dT/dt = Yprime = Derivative of the temperature. ! If the program starts with Debug, this condition is necessary. Yprime(1) = 0.0 ! If the program starts with Debug, this condition is not necessary. Yprime(n) = 0.0
Do i = 2, n-1 ! Symmetry condition at x = 0 m. Y(1) = Y(2) ! Evaluate the derivative of the temperature, !
!
End Do End subroutine |