Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- In[1]:= A = 1.5;
- B = 2;
- In[3]:= Comatrix = {
- {-(A + 2*B), 3*B, 0, 0, 0, 0, 0, 0, 0},
- {A, -(A + 3*B), 4*B, 0, 0, 0, 0, 0, 0},
- {0, A, -(A + 4*B), 5*B, 0, 0, 0, 0, 0},
- {0, 0, A, -(A + 5*B), 6*B, 0, 0, 0, 0},
- {0, 0, 0, A, -(A + 6*B), 7*B, 0, 0, 0},
- {0, 0, 0, 0, A, -(A + 7*B), 8*B, 0, 0},
- {0, 0, 0, 0, 0, A, -(A + 8*B), 9*B, 0},
- {0, 0, 0, 0, 0, 0, A, -(A + 9*B), 10*B},
- {0, 0, 0, 0, 0, 0, 0, A, -(10*B)}
- };
- In[4]:= Nmatrix[t_] = {N2[t], N3[t], N4[t], N5[t], N6[t], N7[t], N8[t],
- N9[t], N10[t]};
- In[5]:= system = Derivative[1][Nmatrix][t] == Comatrix . Nmatrix[t];
- In[6]:= sol = DSolve[{system, N2[0] == 1, N3[0] == 0, N4[0] == 0, N5[0]
- == 0, N6[0] == 0, N7[0] == 0, N8[0] == 0, N9[0] == 0, N10[0] == 0},
- {N2, N3, N4, N5, N6, N7, N8, N9, N10}, t];
- In[7]:= {N2ans[t_], N3ans[t_], N4ans[t_], N5ans[t_], N6ans[t_],
- N7ans[t_], N8ans[t_], N9ans[t_], N10ans[t_]} = {N2[t], N3[t],
- N4[t], N5[t], N6[t], N7[t], N8[t], N9[t], N10[t]} /. Flatten[sol];
- In[8]:= f[t_] = 2*B*N2ans[t];
- Integrate[t*f[t], {t, 0, Infinity}]
- Out[9]= 0.326222
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement