## 5 Reputation

11 years, 355 days

## ...for loop in the total system...

`Using the technique you suggested, I solved the system (of two second-order odes de1, de2) for a particular parameter k.Now suppose I want to do a loop computation for different k values:sysk := {subs(H[0] = 1, Omega[d] = .274, alpha = -0.1e-2, w = 0, de1), subs(H[0] = 1, Omega[d] = .274, alpha = -0.1e-2, w = 0, de2)}icsys := Delta[d](1) = 10^(-5), (D(Delta[d]))(1) = 0,             Delta[f](1) = 10^(-5), (D(Delta[f]))(1) = 0A := []; for e from -1 by .1 to 3 do solk := dsolve({icsys, op(subs(k = 10^e, sysk))}, numeric,`
` known = [A, A1, A2, A3]); deltk := subs(solk, Delta[d](t)); `
`A := [op(A), [e, log10(deltk(.9)^2)]] end doand here is the error message I get:Error, (in dsolve/numeric/process_input) unknown [] specified as 'known' must be an evaluatable procedureBut A,A1,A2,A3 are defined earlier in the previous 4th order system and it had worked for a single k value.Any idea?`

## This works perfectly...

It works, thanks!

## It works, thanks!...

That was it!

Thanks for the help, Preben!

## .dat file...

That is true. But my question is: how can I save the numerical solutions as a  filename.dat file?

Thanks

 Page 1 of 1
﻿