Задача по "Матфизике"
Автор: cheshire fox • Апрель 15, 2023 • Задача • 3,476 Слов (14 Страниц) • 158 Просмотры
Задачи для подготовки к к/р 1 по матфизике
1. Utt - 4Uxx = sin(2t)cos(πx) + 6
Uxǀx=0 = 0 Uxǀx=2 = 0
Uǀt=0 = 3 + 2cos(πx) Utǀt=0 = - 5
2. Utt - Uxx + U = t(x-π) + (t+2)sin(x)
Uǀx=0 = -πt Uǀx=π = 0
Uǀt=0 = 3sin(x) Utǀt=0 = x-π + 2sin(3x)
Расчет задачи теплопроводности сеточным методом.
Ut - Uxx = (2 * x - 2) * t + 0.1 * x * 1/(t + 1) - 0.2 * sin(t)
U(0,t) = 0.1 + 0.2 * cos(t) Ux(l,t) = 0.1 * log(t + 1)
U(x,0) = (x)^2 - 5 * x + 0.3
x = [0 , 2.5] t = [0 , 0.4]
I. Явная схема.
Расчитаем U при t = 0:
U(0, 0) = U(0, 0) = (0)^2 - 5 * 0 + 0.3 = 0.3
U(1, 0) = U(0.5, 0) = (0.5)^2 - 5 * 0.5 + 0.3 = -1.95
U(2, 0) = U(1, 0) = (1)^2 - 5 * 1 + 0.3 = -3.7
U(3, 0) = U(1.5, 0) = (1.5)^2 - 5 * 1.5 + 0.3 = -4.95
U(4, 0) = U(2, 0) = (2)^2 - 5 * 2 + 0.3 = -5.7
U(5, 0) = U(2.5, 0) = (2.5)^2 - 5 * 2.5 + 0.3 = -5.95
Рассчитаем 1-й ряд, при t = 0.08:
U(1, 1) = U(0.5, 0.08) = ((2 * 0.5 - 2) * 0 + 0.1 * 0.5 * 1/(0 + 1) - 0.2 * sin(0)) * 0.08 + 0.08 * (-3.7 - 2 * -1.95 + 0.3) / 0.5 ^ 2 + -1.95= -1.786
U(2, 1) = U(1, 0.08) = ((2 * 1 - 2) * 0 + 0.1 * 1 * 1/(0 + 1) - 0.2 * sin(0)) * 0.08 + 0.08 * (-4.95 - 2 * -3.7 + -1.95) / 0.5 ^ 2 + -3.7= -3.532
U(3, 1) = U(1.5, 0.08) = ((2 * 1.5 - 2) * 0 + 0.1 * 1.5 * 1/(0 + 1) - 0.2 * sin(0)) * 0.08 + 0.08 * (-5.7 - 2 * -4.95 + -3.7) / 0.5 ^ 2 + -4.95= -4.778
U(4, 1) = U(2, 0.08) = ((2 * 2 - 2) * 0 + 0.1 * 2 * 1/(0 + 1) - 0.2 * sin(0)) * 0.08 + 0.08 * (-5.95 - 2 * -5.7 + -4.95) / 0.5 ^ 2 + -5.7= -5.524
Рассчитаем левое условие:
U(0, 1) = U(0, 0.08) = 0.1 + 0.2 * cos(0.08) = 0.29936
Рассчитаем правое условие:
U(5, 1) = U(2.5, 0.08) = -5.524 + (0.1 * log(0.08 + 1)) * 0.5 = -5.52015
Рассчитаем 2-й ряд, при t = 0.16:
U(1, 2) = U(0.5, 0.16) = ((2 * 0.5 - 2) * 0.08 + 0.1 * 0.5 * 1/(0.08 + 1) - 0.2 * sin(0.08)) * 0.08 + 0.08 * (-3.532 - 2 * -1.786 + 0.29936) / 0.5 ^ 2 + -1.786= -1.68138
U(2, 2) = U(1, 0.16) = ((2 * 1 - 2) * 0.08 + 0.1 * 1 * 1/(0.08 + 1) - 0.2 * sin(0.08)) * 0.08 + 0.08 * (-4.778 - 2 * -3.532 + -1.786) / 0.5 ^ 2 + -3.532= -3.36587
U(3, 2) = U(1.5, 0.16) = ((2 * 1.5 - 2) * 0.08 + 0.1 * 1.5 * 1/(0.08 + 1) - 0.2 * sin(0.08)) * 0.08 + 0.08 * (-5.524 - 2 * -4.778 + -3.532) / 0.5 ^ 2 + -4.778= -4.60177
U(4, 2) = U(2, 0.16) = ((2 * 2 - 2) * 0.08 + 0.1 * 2 * 1/(0.08 + 1) - 0.2 * sin(0.08)) * 0.08 + 0.08 * (-5.52015 - 2 * -5.524 + -4.778) / 0.5 ^ 2 + -5.524= -5.25771
Рассчитаем левое условие:
U(0, 2) = U(0, 0.16) = 0.1 + 0.2 * cos(0.16) = 0.297445
Рассчитаем правое условие:
U(5, 2) = U(2.5, 0.16) = -5.25771 + (0.1 * log(0.16 + 1)) * 0.5 = -5.25029
Рассчитаем 3-й ряд, при t = 0.24:
U(1, 3) = U(0.5, 0.24) = ((2 * 0.5 - 2) * 0.16 + 0.1 * 0.5 * 1/(0.16 + 1) - 0.2 * sin(0.16)) * 0.08 + 0.08 * (-3.36587 - 2 * -1.68138 + 0.297445) / 0.5 ^ 2 + -1.68138= -1.59909
U(2, 3) = U(1, 0.24) = ((2 * 1 - 2) * 0.16 + 0.1 * 1 * 1/(0.16 + 1) - 0.2 * sin(0.16)) * 0.08 + 0.08 * (-4.60177 - 2 * -3.36587 + -1.68138) / 0.5 ^ 2 + -3.36587= -3.21797
U(3, 3) = U(1.5, 0.24) = ((2 * 1.5 - 2) * 0.16 + 0.1 * 1.5 * 1/(0.16 + 1) - 0.2 * sin(0.16)) * 0.08 + 0.08 * (-5.25771 - 2 * -4.60177 + -3.36587) / 0.5 ^ 2 + -4.60177= -4.39559
U(4, 3) = U(2, 0.24) = ((2 * 2 - 2) * 0.16 + 0.1 * 2 * 1/(0.16 + 1) - 0.2 * sin(0.16)) * 0.08 + 0.08 * (-5.25029 - 2 * -5.25771 + -4.60177) / 0.5 ^ 2 + -5.25771= -5.00859
Рассчитаем левое условие:
U(0, 3) = U(0, 0.24) = 0.1 + 0.2 * cos(0.24) = 0.294268
Рассчитаем правое условие:
U(5, 3) = U(2.5, 0.24) = -5.00859 + (0.1 * log(0.24 + 1)) * 0.5 = -4.99784
Рассчитаем 4-й ряд, при t = 0.32:
U(1, 4) = U(0.5, 0.32) = ((2 * 0.5 - 2) * 0.24 + 0.1 * 0.5 * 1/(0.24 + 1) - 0.2 * sin(0.24)) * 0.08 + 0.08 * (-3.21797 - 2 * -1.59909 + 0.294268) / 0.5 ^ 2 + -1.59909= -1.53104
U(2, 4) = U(1, 0.32) = ((2 * 1 - 2) * 0.24 + 0.1 * 1 * 1/(0.24 + 1) - 0.2 * sin(0.24)) * 0.08 + 0.08 * (-4.39559 - 2 * -3.21797 + -1.59909) / 0.5 ^ 2 + -3.21797= -3.07412
U(3, 4) = U(1.5, 0.32) = ((2 * 1.5 - 2) * 0.24 + 0.1 * 1.5 * 1/(0.24 + 1) - 0.2 * sin(0.24)) * 0.08 + 0.08 * (-5.00859 - 2 * -4.39559 + -3.21797) / 0.5 ^ 2 + -4.39559= -4.18984
U(4, 4) = U(2, 0.32) = ((2 * 2 - 2) * 0.24 + 0.1 * 2 * 1/(0.24 + 1) - 0.2 * sin(0.24)) * 0.08 + 0.08 * (-4.99784 - 2 * -5.00859 + -4.39559) / 0.5 ^ 2 + -5.00859= -4.76149
Рассчитаем левое условие:
U(0, 4) = U(0, 0.32) = 0.1 + 0.2 * cos(0.32) = 0.289847
Рассчитаем правое условие:
U(5, 4) = U(2.5, 0.32) = -4.76149 + (0.1 * log(0.32 + 1)) * 0.5 = -4.74761
Рассчитаем 5-й ряд, при t = 0.4:
U(1, 5) = U(0.5, 0.4) = ((2 * 0.5 - 2) * 0.32 + 0.1 * 0.5 * 1/(0.32 + 1) - 0.2 * sin(0.32)) * 0.08 + 0.08 * (-3.07412 - 2 * -1.53104 + 0.289847) / 0.5 ^ 2 + -1.53104= -1.46974
U(2, 5) = U(1, 0.4) = ((2 * 1 - 2) * 0.32 + 0.1 * 1 * 1/(0.32 + 1) - 0.2 * sin(0.32)) * 0.08 + 0.08 * (-4.18984 - 2 * -3.07412 + -1.53104) / 0.5 ^ 2 + -3.07412= -2.93634
U(3, 5) = U(1.5, 0.4) = ((2 * 1.5 - 2) * 0.32 + 0.1 * 1.5 * 1/(0.32 + 1) - 0.2 * sin(0.32)) * 0.08 + 0.08 * (-4.76149 - 2 * -4.18984 + -3.07412) / 0.5 ^ 2 + -4.18984= -3.98608
...