0
|
2929 Views
|
2 Replies
|
1 Total Likes
View groups...
Share
GROUPS:

# Question: compatibility of table in NDSolve

Posted 10 years ago
 I would like to solve the following simultaneous differential equations by NDSolve. When I tried to include a function g[t] in addition to functions f[t,1-10] that are defined by table, the following message appeared; NDSolve::dsfun:"you cannot use {f[t,1],...,f[t,10]} as a function". When I deleted g[t] from the equations, it worked. What is problem?
2 Replies
Sort By:
Posted 10 years ago
 Thank you for quick reply. Following your suggestion it worked. Based on this example code, I found that if I rename the function g[t] as f[3][t] it also worked.
Posted 10 years ago
 If you put your code into a Code Sample (the first icon) it could be copied into Mathematica without having to type it in.I suspect your code would work if you used f[i][t] for your functions instead of f[t,i].For example: NDSolve[{D[f[1][t], t] == f[2][t], D[f[2][t], t] == f[1][t], f[1][0] == 1, f[2][0] == 1}, {f[1][t], f[2][t]}, {t, 0, 1}]