imagine is an example of what im trying to figure out

I I'm trying to solve this problem with mathematica but the code keeps giving me an error.

  • 2
    $\begingroup$ A first step is to write this equation in Mathematica syntax. Have a look at reference page of DSolve to get an idea how to do that. If have that code and it does not work, people would need to see it (i.e. you should post it) otherwise it's not possible to identify the issue. $\endgroup$ – user21 Apr 16 '19 at 15:04
  • 2
    $\begingroup$ You should include the code that is giving you the error. $\endgroup$ – Mr.Wizard Apr 16 '19 at 15:12
Eq1 = x1'[t] == x1[t] + x2[t] + x3[t] + Exp[t];

Eq2 = x2'[t] == -x1[t]^2 + x2[t]^2 + x3[t]^2 + Cos[10*t];

Eq3 = x3'[t] == x1[t] - x2[t] + x3[t] + Sin[5*t];    

sol = First@NDSolve[{Eq1, Eq2, Eq3, x1[0] == 1, x2[0] == -1, x3[0] == 1}, 
{x1[t], x2[t], x3[t]}, {t, 0, 5}]

Plot[(x1[t]^2 + x2[t]^2 + x3[t]^2)^(1/2) /. sol, {t, 0, 5}]

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.