PatrickT

Dr. Patrick T

2108 Reputation

18 Badges

16 years, 306 days

MaplePrimes Activity


These are replies submitted by PatrickT

very useful tip, thanks Robert.

very useful tip, thanks Robert.

forgive my ignorance:

for i from 1 to 10 do
  A[i]:= sin(i*Pi);
  B[i]:= cos(i*Pi);
  h[i]:= A[i]*cos(x) + B[i]*sin(x);
end do:
plot([h[i] $ i=1..10], x = 0 .. 2*Pi);
Error, invalid input: $ expects its 2nd argument, range, 
to be of type {numeric, algebraic, name = literal .. literal, 
name = algebraic .. algebraic}, but received 11 = 1 .. 10


forgive my ignorance:

for i from 1 to 10 do
  A[i]:= sin(i*Pi);
  B[i]:= cos(i*Pi);
  h[i]:= A[i]*cos(x) + B[i]*sin(x);
end do:
plot([h[i] $ i=1..10], x = 0 .. 2*Pi);
Error, invalid input: $ expects its 2nd argument, range, 
to be of type {numeric, algebraic, name = literal .. literal, 
name = algebraic .. algebraic}, but received 11 = 1 .. 10


Alex,

I'm not sure I understand your questions. Is your system the same you gave at the top of the thread? it does not seem to be solvable as is... perhaps after some transformations ... but that's not very likely. How about this: write down the system you want to solve and write down the solution you found by hand. If anything, we should be able to tell you whether your solution is correct.

 

Alex,

I'm not sure I understand your questions. Is your system the same you gave at the top of the thread? it does not seem to be solvable as is... perhaps after some transformations ... but that's not very likely. How about this: write down the system you want to solve and write down the solution you found by hand. If anything, we should be able to tell you whether your solution is correct.

 

I ran your code and it seemed to be missing something around the line that has NNV. Maybe it's just me. Take a look a jakubi's comment above.

I ran your code and it seemed to be missing something around the line that has NNV. Maybe it's just me. Take a look a jakubi's comment above.

Is the code below complete?

 

restart:
with(PDETools); with(ArrayTools);

Test := 0 = diff(u(x, y, t), t, y)+diff(v(x, y, t), `$`(x, 2))+(diff(u(x, y, t), y))*(diff(u(x, y, t), x))+u(x, y, t)*(diff(u(x, y, t), x, y));

Aux := 0 = diff(v(x, y, t), t)+diff(u(x, y, t)*v(x, y, t)+u(x, y, t)+diff(u(x, y, t), x, y), x);

uu := u0(x, t); ww := Wo(y, t);
f1 := f(x, y, t);
u1 := 2*(diff(ln(f1), x))+uu; v1 := 2*(diff(ln(f1), x, y))-1;
subs(u(x, y, t) = u1, v(x, y, t) = v1, Aux);
eval(%);
simplify(%);
lin := %*f^3;

subs(u(x, y, t) = u1, w(x, y, t) = w1, v(x, y, t) = v1, NNV);
simplify(%);
%*f^3;
(1/2)*%;
Eqn5 := %;
Ca := collect(Eqn5, diff(w0, y));
Cb := collect(Ca, diff(v0, x));
Cc := collect(Cb, w0);
Cd := collect(Cc, v0);

SepForm := 1+m*p(x, t)+n*q(y, t)+A*p(x, t)*q(y, t); subs(f = SepForm, lin);
ExpandedEqn5 := expand(%);
coll1 := collect(ExpandedEqn5, [diff(q, t), diff(q, y)]); collp1 := collect(ExpandedEqn5, diff(p, t));
coll2 := collect(coll1, diff(q, y, t));
simplify(coll2/(diff(q, y)));

Eqn7 := 0 = (diff(q, y))*((2*(q*A+m))*(diff(p, t)-a*(diff(p, x, x, x))+3*(diff(p, x))*a*v0)*(diff(p, x))-SepForm*(diff(diff(p, t)-a*(diff(p, x, x, x))+3*(diff(p, x))*a*v0, x)))+(diff(p, x))*((2*(p*A+n))*(diff(q, t)-b*(diff(q, y, y, y))+3*(diff(q, y))*b*w0)*(diff(q, y))-SepForm*(diff(diff(q, t)-b*(diff(q, y, y, y))+3*(diff(q, y))*b*w0, y)));
CheckEqn7 := expand(Eqn7);
evalb(CheckEqn7 = ExpandedEqn5);
 

Is the code below complete?

 

restart:
with(PDETools); with(ArrayTools);

Test := 0 = diff(u(x, y, t), t, y)+diff(v(x, y, t), `$`(x, 2))+(diff(u(x, y, t), y))*(diff(u(x, y, t), x))+u(x, y, t)*(diff(u(x, y, t), x, y));

Aux := 0 = diff(v(x, y, t), t)+diff(u(x, y, t)*v(x, y, t)+u(x, y, t)+diff(u(x, y, t), x, y), x);

uu := u0(x, t); ww := Wo(y, t);
f1 := f(x, y, t);
u1 := 2*(diff(ln(f1), x))+uu; v1 := 2*(diff(ln(f1), x, y))-1;
subs(u(x, y, t) = u1, v(x, y, t) = v1, Aux);
eval(%);
simplify(%);
lin := %*f^3;

subs(u(x, y, t) = u1, w(x, y, t) = w1, v(x, y, t) = v1, NNV);
simplify(%);
%*f^3;
(1/2)*%;
Eqn5 := %;
Ca := collect(Eqn5, diff(w0, y));
Cb := collect(Ca, diff(v0, x));
Cc := collect(Cb, w0);
Cd := collect(Cc, v0);

SepForm := 1+m*p(x, t)+n*q(y, t)+A*p(x, t)*q(y, t); subs(f = SepForm, lin);
ExpandedEqn5 := expand(%);
coll1 := collect(ExpandedEqn5, [diff(q, t), diff(q, y)]); collp1 := collect(ExpandedEqn5, diff(p, t));
coll2 := collect(coll1, diff(q, y, t));
simplify(coll2/(diff(q, y)));

Eqn7 := 0 = (diff(q, y))*((2*(q*A+m))*(diff(p, t)-a*(diff(p, x, x, x))+3*(diff(p, x))*a*v0)*(diff(p, x))-SepForm*(diff(diff(p, t)-a*(diff(p, x, x, x))+3*(diff(p, x))*a*v0, x)))+(diff(p, x))*((2*(p*A+n))*(diff(q, t)-b*(diff(q, y, y, y))+3*(diff(q, y))*b*w0)*(diff(q, y))-SepForm*(diff(diff(q, t)-b*(diff(q, y, y, y))+3*(diff(q, y))*b*w0, y)));
CheckEqn7 := expand(Eqn7);
evalb(CheckEqn7 = ExpandedEqn5);
 

Guildenstern: Pragmatism. Is that all you have to offer?
Rosencrantz: I merely suggest that the position of the sun, if it is out, would give you a rough idea of the time. Alternatively, a clock, if it is going, would give you a rough idea of the position of the sun. I forget which you are trying to establish.
Guildenstern: I'm trying to establish the direction of the wind.
Rosencrantz: There isn't any wind.

 

copy-pasted from: http://www.imdb.com/character/ch0009784/quotes

Guildenstern: Pragmatism. Is that all you have to offer?
Rosencrantz: I merely suggest that the position of the sun, if it is out, would give you a rough idea of the time. Alternatively, a clock, if it is going, would give you a rough idea of the position of the sun. I forget which you are trying to establish.
Guildenstern: I'm trying to establish the direction of the wind.
Rosencrantz: There isn't any wind.

 

copy-pasted from: http://www.imdb.com/character/ch0009784/quotes

I second your suggestions. I too struggle to post images and don't usually bother. Especially cumbersome is resizing images. My rule of thumb now is I select a width of 400 and don't attempt to resize later on, it seems to work. I also don't try to post too many images in one post, for fear of losing the formatting in the rest of the message.

I second your suggestions. I too struggle to post images and don't usually bother. Especially cumbersome is resizing images. My rule of thumb now is I select a width of 400 and don't attempt to resize later on, it seems to work. I also don't try to post too many images in one post, for fear of losing the formatting in the rest of the message.

The ability to see the contour lines in 3D is definitely a plus -- Doug's approach has much to commend it!

One minor drawback of using 3d plots, as discussed elsewhere, is that 3D plots are currently lagging behind in development relative to 2D plots. Hopefully this will be fixed soon!

contourplot3d(f(x,z), x=-3..3, z=-3..3, grid=[100,100], 
contours=[$-10..10], numpoints=100, axes=boxed, 
orientation=[20,70], view=[-3..3,-3..3,-10..10]);
Standard 13.01:

Classic 13.01:

First 79 80 81 82 83 84 85 Last Page 81 of 93