Mathematica 9 is now available
Student Support Forum
-----
Student Support Forum: 'Curve Fitting Complex Diff Eq.' topicStudent Support Forum > General > Archives > "Curve Fitting Complex Diff Eq."

Next Comment >Help | Reply To Topic
Author Comment/Response
William Duhe
07/11/12 10:37pm

Here is my lines of code which produces a very interesting plot:

Subscript[M, p] = 100;
Subscript[A, r] = -Subscript[C, d];
Subscript[B, m] = 0;
Subscript[C, d] = -10^-8*Subscript[M, p]^4;
K = 0;
Subscript[p, r] = -Subscript[C, d]*a[t]^-4;
Subscript[p, m] = Subscript[B, m]*a[t]^-3;
Subscript[p, d] = Subscript[C, d];
Subscript[P, r] = Subscript[p, r]/3;
Subscript[P, m] = 0;
Subscript[P, d] = -Subscript[p, d];
p = Subscript[p, r] + Subscript[p, m] + Subscript[p, d];
P = Subscript[P, r] + Subscript[P, m] + Subscript[P, d];
v = 1/(Sqrt[3]*100);
mu = 10^-4*Subscript[M, p];
Y = -mu^3;
q = NDSolve[{a''[
t] == -a[t]*1/(6*100^2)*(p + 3 P) + (p/100^4*(3 P + 2 p)),
a[0] == 1, a'[0] == 0}, a, {t, -500, 500}]
s = NDSolve[{a''[
t] == -a[t]*1/(
6*Subscript[M, p]^2)*(p + 3 P) + (p/Subscript[M,
p]^4*(3 P + 2 p)),
phi''[t] + 3 (a'[t]/a[t])*phi'[t] - mu^3 == 0, a[0] == 1,
phi[0] == 0, a'[0] == 0, phi'[0] == 0}, {a, phi}, {t, -5000, 5000}];
Plot[Evaluate[{phi[t]} /. s], {t, -5000, 5000},
PlotStyle -> Automatic]


What would be the best and most efficient way of curve fitting the plot produced? Thanks a lot!

URL: ,

Subject (listing for 'Curve Fitting Complex Diff Eq.')
Author Date Posted
Curve Fitting Complex Diff Eq. William Duhe 07/11/12 10:37pm
Re: Curve Fitting Complex Diff Eq. Bill Simpson 07/12/12 5:27pm
Next Comment >Help | Reply To Topic