Changes between Version 13 and Version 14 of u/ehansen/buildcode
- Timestamp:
- 10/31/11 19:19:54 (13 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
u/ehansen/buildcode
v13 v14 28 28 [[latex($U_{i}^{n+1} = \frac{1}{\Delta x} \int_{x_{i-\frac{1}{2}}}^{x_{i+\frac{1}{2}}} \tilde{U}(x,t^{n+1}) \ \mathrm{d}x$ \hspace{1 in}(2))]] 29 29 30 Where [[latex($\tilde{U}$)]] is the global solution as opposed to the local solution [[latex($U$)]]. However, we already know that the global solution can be written in terms of its fluxes. You just use equation(1) with a specific control volume:30 Where [[latex($\tilde{U}$)]] is the global solution as opposed to the local solution [[latex($U$)]]. However, we already know that the global solution can be written in terms of its fluxes. You just use (1) with a specific control volume: 31 31 32 32 [[latex($\int^{x_{i+\frac{1}{2}}}_{x_{i - \frac{1}{2}}} \tilde{U}(x,t^{n+1}) \ \mathrm{d}x = \int^{x_{i+\frac{1}{2}}}_{x_{i - \frac{1}{2}}} \tilde{U}(x,t^{n}) \ \mathrm{d}x + \int_{t^{n}}^{t^{n+1}}F(\tilde{U}(x_{i-\frac{1}{2}},t)) \ \mathrm{d}t - \int_{t^{n}}^{t^{n+1}} F(\tilde{U}(x_{i+\frac{1}{2}},t)) \ \mathrm{d}t \hspace{1 in} (3)$)]] … … 43 43 44 44 [[latex($\tilde{U}(x_{i-\frac{1}{2}},t) = U_{i-\frac{1}{2}}(0) = constant \hspace{1 in} (6)$)]] 45 45 46 [[latex($\tilde{U}(x_{i+\frac{1}{2}},t) = U_{i+\frac{1}{2}}(0) = constant \hspace{1 in} (7)$)]] 46 47 47 Substitute (6) and (7) into (3), and then that result into (2) gives:48 Substitute (6) and (7) into (3), and then substituting that result into (2) gives: 48 49 49 50 [[latex($U_{i}^{n+1} = \frac{1}{\Delta x} \int^{x_{i+\frac{1}{2}}}_{x_{i - \frac{1}{2}}} \tilde{U}(x,t^{n}) \ \mathrm{d}x + \frac{1}{\Delta x} \int_{t^{n}}^{t^{n+1}}F(U_{i-\frac{1}{2}}(0,t)) \ \mathrm{d}t - \frac{1}{\Delta x} \int_{t^{n}}^{t^{n+1}} F(U_{i+\frac{1}{2}}(0,t)) \ \mathrm{d}t \hspace{1 in} (8)$)]]