# Items tagged with plotplot Tagged Items Feed

### how to plot graph and insert arrow...

5 hours ago
0 0

i want to plot two difrent graph in one diagram.. anyone how to do it?

restart; with(plots); n := .2; B := .5; Ec := 2.0; Pr := 1.0; N := .5; l := 1; rho := .5; c := 1; T := .5; T1 := .5; c1 := .2; c2 := .2; Gr := .5; blt := 5;

Eq1 := diff(f(eta), eta, eta, eta)+f(eta)*(diff(f(eta), eta, eta))-(diff(f(eta), eta))^2+l*B*H(eta)*(F(eta)-(diff(f(eta), eta)))+Gr*theta(eta)-Mn*(diff(f(eta), eta)) = 0;

Eq2 := G(eta)*(diff(F(eta), eta))+F(eta)^2+B*(F(eta)-(diff(f(eta), eta))) = 0;

Eq3 := G(eta)*(diff(G(eta), eta))+B*(f(eta)+G(eta)) = 0;

Eq4 := G(eta)*(diff(H(eta), eta))+H(eta)*(diff(G(eta), eta))+F(eta)*H(eta) = 0;

Eq5 := diff(theta(eta), eta, eta)+Pr*((diff(theta(eta), eta))*f(eta)-2*(diff(f(eta), eta))*theta(eta))+N*Pr*(theta1(eta)-theta(eta))/(rho*c*T)+N*Pr*Ec*(F(eta)-(diff(f(eta), eta)))^2/(rho*T1) = 0;

Eq6 := 2*F(eta)*theta1(eta)+G(eta)*(diff(theta1(eta), eta))+c1*(theta1(eta)-theta(eta))/(c*c2*T) = 0;

bcs1 := f(0) = 0, (D(f))(0) = 1, (D(f))(blt) = 0, F(blt) = 0, G(blt) = -f(blt), H(blt) = n, theta(0) = 1, theta(blt) = 0, theta1(blt) = 0;

L := [0, 1, 2];

for k to 3 do R := dsolve(eval({Eq1, Eq2, Eq3, Eq4, Eq5, Eq6, bcs1}, Mn = L[k]), [f(eta), F(eta), G(eta), H(eta), theta(eta), theta1(eta)], numeric, output = listprocedure); Y || k := rhs(R[3]); YP || k := rhs(R[5]); YR || k := rhs(R[6]); YQ || k := rhs(R[7]); YA || k := rhs(R[8]); YB || k := rhs(R[10]) end do;

plot([Y || (1 .. 3)], 0 .. 10, labels = [eta, (D(f))(eta)]);

this comands will comeout to diffrent graph in two diagram.. but i want two graph in one diagram.. any one know how to do it.. beside that.. i want to know how to insert arrow in diagram..

### Beziercurve plot in 3d...

Yesterday at 11:10 AM
1 1

Hi, guys and happy eastern to all! :)

I have a realy big problem. I have to do beziercurves in 3d plots.

I can´t plot it in 3d, something wrong with the plot (complex). Can anybody pls help me?! It´s very important to me, thanks! :)

### Plot a continuous function...

April 18 2014
0 2

AOA... I want to plot the following function which is continuous in [0,3]

f:=x^2+1  for x belong to [0,1]

f:=x^2-1  for x belong to [1,2]

f:=x+1  for x belong to [2,3]

Kindly help...

### Spacecurve command does not work...

April 17 2014
1 4

Hi

I'm using Maple 17 on Windows 8 (64-bit).

I have noticed that when I use the 'spacecurve' command and try to display it with the 'display' command, nothing shows up. I made sure that I used 'with(plots)' and 'with(plottools)', still nothing. However 'plot3d' works fine. I think it has something to do with the version of Java I'm using but I don't know what. Any help is welcome, thx

Specifications of my laptop:

Graphics: NVIDIA Geforce GT 740m

Processor: Intel(R) Core(TM) i7-3630QM (2.40GHz)

Ram: 6,00 GB

OS: Windows 8.1

### Plotting of piecewise continuous function...

April 17 2014
0 2

AOA... I wan to plot the following piecewise function

f := x^2+1         if x belongs to (0,1)

f := x-x^2          if x belongs to (1,2)

f := x+1-x^2       if x belongs to (2,3)

### Extracting data from a 2D plot to compare in Matla...

April 16 2014
1 6

Hello;

I would like to extract data from a 2D plot to compare my numerical result in Matlab.

I used this command.

However, I need to spesify the nodes on x axis to get the error in Matlab. My matlab codes give the result as fix step size i.e [0 0.1 0.2 ... 1.0] or [0 0.01 0.02 ... 1.00] etc.

Is there any command in Maple to spesify the nodes on x axis?

Thanks you!

### How to plot a graph...

April 16 2014
1 4

i solve 4 ODE with boundary condition.. i try to plot a graph F(eta) with different value of M.. but it doesnt comeout.. anyone can help me please??

 (1)

 (2)

 (3)

 (4)

 (5)

 (6)

 (7)

 (8)

 (9)

 (10)

 (11)

### I am so close to plot what I need but......

April 14 2014
0 6

Hi everybody,

In quantum mechanics, I want to draw the wave  of the electron in the hydrogen atom.  So in 3D, you will have a cricle and along the circle, there will be a cosine function that will meet after a full cercle (the standing wave that is possible).  The blue one and the red one at the same time.  But in 3D

The closest that I come to succes is with this commands:

But as you will see, the wave end at the same place as it started.  But instead of going in a cercle, is as a funny shape.

Thank you in advance for you trouble.

--------------------------------------
Mario Lemelin
Maple 18 Ubuntu 13.10 - 64 bitsMaple 18 Win 7 -  64 bits
messagerie : mario.lemelin@cgocable.ca
téléphone :  (819) 376-0987

### Polar plot of wavefunction...

April 12 2014
0 1

Hello , Happy weekend ... I need a help on plot of a wavefunction give below , i have made the plot using plot3d in cylindrical coordinate. But what i need now is the Polar plot of it. And it always comes with the code ensure calling sequence is correct.

psi(r,phi):= C[0, .1]*BesselI(4, 2*lambda*exp((1/2*I)*phi))*BesselJ(2, 1/r)+C[1, .1]*BesselI(6, 2*lambda*exp((1/2*I)*phi))*BesselJ(3, 1/r)+ C[2, .1]*BesselI(8, 2*lambda*exp((1/2*I)*phi))*BesselJ(4, 1/r)+ C[3, .1]*BesselI(10, 2*lambda*exp((1/2*I)*phi))*BesselJ(5, 1/r)+ C[4, .1]*BesselI(12,2*lambda*exp((1/2*I)*phi))*BesselJ(6, 1/r)+ C[5, .1]*BesselI(14, 2*lambda*exp((1/2*I)*phi))*BesselJ(7, 1/r)+C[6, .1]*BesselI(16, 2*lambda*exp((1/2*I)*phi))*BesselJ(8, 1/r)+ C[7, .1]*BesselI(18, 2*lambda*exp((1/2*I)*phi))*BesselJ(9, 1/r);

C[0, .1]:= 2.222222222*10^11;  C[1, .1]:=8.333333333*10^18 ; C[2, .1]:=6.250000000*10^26 ; C[3, .1]:= 2.127659574*10^32; C[4, .1]:= 3.125000000*10^43 ; C[5, .1]:=1.639344262*10^52 ; C[6, .1]:=1.408450704*10^61; C[7, .1]:=1.886792453*10^70;

My 1st case:
lambda:=0.1; plot3d(abs(psi(r,phi))^2,phi=0..2*Pi,r=0..5, coords=cylindrical);

2nd case: What i want.

lambda:=0.1; plot(abs(psi(r,phi))^2,r=-0..5, phi= 0..2*Pi, coords = polar);

### poinplot3d add names of point...

April 10 2014
0 3

Dear all;

Please in this code Maple, I plot using pointplot3d, some points. I would like to add a name of each point.

The name of each point  P:=[x(i),y(j),t(k)] is u[i,j]^k.  Please how can I add the name at each point. here is the maple code.

Thanks.

pointplot3d.mw

### geom3d seq of point in R^3...

April 09 2014
1 7

Dear all,

Using   I want to plot in R^3, the set of point u[i,j]^k . This point has as cordinate  (x[i],y[j],t[k]).

x := i -> (1/5)*i;  #  x[i] the x-coordinate
y := j -> (1/5)*j; # y[j] the y-coordinate
t := k -> (1/5)*k;  #  t[k] the t-coordinate

The name of point is u[i,j]^k

How can I  plot all the point.

with(geom3d):

point(u[i,j]^k, x(i),y(j),t(k));

Thank you.

### visualization of the lattice...

April 09 2014
0 0

Dear all;

I need a help in this question.

u(x,y,t) my solution of PDE. x,y space, and t=time.

In the case without t. .i.e. u(x,y). Here is a visualization of the lattice u(x_i,y_j). i=1..3, anf j=1..3.  Please try this example, it's working.

my question, if i would like to add a third variable t, i.e.  and get u(x_i,y_j,t_k)  on each points. I would like to show the lattice in (x,y) plan for each t_k. I Think I will get many parallel lattice.

Please can some one, modify this code to get the parallel lattice. Thanks.

with(LinearAlgebra):
with(plots):
with(PDEtools):
interface(rtablesize=20):

Here,

L := 'L':
N := 'N':
g := 'g':
Z := i -> -L+2*L/(N+1)*i;
x[0] = Z(0),x[N+1] = Z(N+1),y[0] = Z(0),y[N+1] = Z(N+1);

N := 4;
L := 1;
r := L/(N+1)/4;
ngon := (n,x,y,r,phi) -> [seq([x+r*cos(2*Pi*i/n+phi), y+r*sin(2*Pi*i/n+phi)], i = 1 .. n)]:
p[1] := display([seq(polygonplot(ngon(4,Z(0),Z(j),r,Pi/2),color=magenta),j=0..N+1),

seq(polygonplot(ngon(4,Z(N+1),Z(j),r,Pi/2),color=magenta),j=0..N+1),

seq(polygonplot(ngon(4,Z(i),Z(0),r,0),color=magenta),i=1..N),

seq(polygonplot(ngon(4,Z(i),Z(N+1),r,0),color=magenta),i=1..N),

seq(seq(polygonplot(ngon(20,Z(i),Z(j),r,0),color=white),i=1..N),j=1..N),

textplot([seq(seq([Z(i+0.1),Z(j),typeset(u[i,j])],i=0..N+1),j=0..N+1)],align={above,right})],view=[Z(-1)..Z(N+2),Z(-1)..Z(N+2)],tickmarks=[[seq(Z(i)=typeset(x[i]=evalf[2](Z(i))),i=0..N+1)],[seq(Z(i)=typeset(y[i]=evalf[2](Z(i))),i=0..N+1)]],

axes=boxed,scaling=constrained,labels=[,]):
p[1];

### Maple LaTeX font consistency...

April 07 2014
2 4

Dear Mapleprimes,

I have been struggling with a problem in the last couple of days. I wish to export a Maple plot to LaTeX while ensuring font consistency. While searching for solutions online, I found the psfrag package in LaTeX. So far, however, I have been unsuccesful in making this work. As as test, I attempted to export plot(x^2) to LaTeX. I used the following code to convert to .eps which worked fine:

plotsetup(ps, plotoutput = plot1.eps, plotoptions = portrait, noborder,height=5in,width=5in);plot(x^2);

Then in LaTeX, I have:

\documentclass{article}

\usepackage{graphicx}

\usepackage{psfrag}

\begin{document}

\begin{figure}[!h]
\centering
\psfrag{x}{$\alpha$}
\includegraphics[scale=0.5]{plot1.eps}
\end{figure}
\end{document}

However, no replacements are made. After intense Google searching I found the following post http://www.mapleprimes.com/posts/43255-Trouble-Replacing-Maple-Axes-Labels which to sum up argues that this was only possible with earlier versions of Maple.

Does anyone know if the problem has been resolved?

Does anyone know any other ways to ensure font consistency for plots imported from Maple to LaTeX?

Thank you very much in advance!

C

### problem with plot...

April 04 2014
0 1

i have a list of data, i can plot them with point plot,but i can not plot it in line style not point, could anyone help ? tnx for your help.

 > restart:m1:=3:m2:=3:m3:=3:
 > P:=unapply(Vector(9, {(1) = 0, (2) = 0, (3) = 0, (4) = -50, (5) = -100/3, (6) = -25, (7) = 0, (8) = 0, (9) = 0}),t):
 > K:=unapply(Matrix(9, 9, {(1, 1) = -200000000, (1, 2) = -600000000, (1, 3) = -1000000000, (1, 4) = -100000000*a[4](t)-600000000*a[5](t)-1000000000*a[6](t), (1, 5) = -2000000000/3*a[5](t)-2100000000*a[6](t), (1, 6) = -1620000000*a[6](t), (1, 7) = 0, (1, 8) = 0, (1, 9) = 0, (2, 1) = -200000000, (2, 2) = -1600000000/3, (2, 3) = -900000000, (2, 4) = -100000000*a[4](t)-1600000000/3*a[5](t)-900000000*a[6](t), (2, 5) = -600000000*a[5](t)-1920000000*a[6](t), (2, 6) = -1500000000*a[6](t), (2, 7) = 0, (2, 8) = 0, (2, 9) = 0, (3, 1) = -200000000, (3, 2) = -500000000, (3, 3) = -840000000, (3, 4) = -100000000*a[4](t)-500000000*a[5](t)-840000000*a[6](t), (3, 5) = -560000000*a[5](t)-1800000000*a[6](t), (3, 6) = -9900000000/7*a[6](t), (3, 7) = 0, (3, 8) = 0, (3, 9) = 0, (4, 1) = -200000000*a[4](t)-600000000*a[5](t)-1000000000*a[6](t), (4, 2) = -600000000*a[4](t)-4000000000/3*a[5](t)-2100000000*a[6](t), (4, 3) = -1000000000*a[4](t)-2100000000*a[5](t)-3240000000*a[6](t), (4, 4) = -100000000*a[4](t)^2+(-900000000*a[5](t)-1500000000*a[6](t))*a[4](t)-6300000000*a[5](t)*a[6](t)-4860000000*a[6](t)^2-175000000/3-2000000000*a[5](t)^2, (4, 5) = -1400000000*a[5](t)^2-6480000000*a[5](t)*a[6](t)-9900000000*a[6](t)^2-175000000, (4, 6) = -35100000000/7*(a[6](t)^2)-875000000/3, (4, 7) = -87500000, (4, 8) = -875000000/9, (4, 9) = -306250000/3, (5, 1) = -200000000*a[4](t)-1600000000/3*a[5](t)-900000000*a[6](t), (5, 2) = -1600000000/3*a[4](t)-1200000000*a[5](t)-1920000000*a[6](t), (5, 3) = -900000000*a[4](t)-1920000000*a[5](t)-3000000000*a[6](t), (5, 4) = -100000000*a[4](t)^2+(-800000000*a[5](t)-1350000000*a[6](t))*a[4](t)-5760000000*a[5](t)*a[6](t)-4500000000*a[6](t)^2-175000000/3-1800000000*a[5](t)^2, (5, 5) = -1280000000*a[5](t)^2-6000000000*a[5](t)*a[6](t)-64800000000/7*(a[6](t)^2)-1400000000/9, (5, 6) = -4725000000*a[6](t)^2-262500000, (5, 7) = -700000000/9, (5, 8) = -87500000, (5, 9) = -280000000/3, (6, 1) = -200000000*a[4](t)-500000000*a[5](t)-840000000*a[6](t), (6, 2) = -500000000*a[4](t)-1120000000*a[5](t)-1800000000*a[6](t), (6, 3) = -840000000*a[4](t)-1800000000*a[5](t)-19800000000/7*a[6](t), (6, 4) = -100000000*a[4](t)^2+(-750000000*a[5](t)-1260000000*a[6](t))*a[4](t)-5400000000*a[5](t)*a[6](t)-29700000000/7*(a[6](t)^2)-175000000/3-1680000000*a[5](t)^2, (6, 5) = -1200000000*a[5](t)^2-39600000000/7*a[5](t)*a[6](t)-8775000000*a[6](t)^2-437500000/3, (6, 6) = -4500000000*a[6](t)^2-245000000, (6, 7) = -218750000/3, (6, 8) = -245000000/3, (6, 9) = -87500000, (7, 1) = 0, (7, 2) = 0, (7, 3) = 0, (7, 4) = 87500000/3, (7, 5) = 350000000/9, (7, 6) = 43750000, (7, 7) = 173500000/9, (7, 8) = 42250000/3, (7, 9) = 32500000/3, (8, 1) = 0, (8, 2) = 0, (8, 3) = 0, (8, 4) = 175000000/9, (8, 5) = 87500000/3, (8, 6) = 35000000, (8, 7) = 43250000/3, (8, 8) = 101000000/9, (8, 9) = 80750000/9, (9, 1) = 0, (9, 2) = 0, (9, 3) = 0, (9, 4) = 43750000/3, (9, 5) = 70000000/3, (9, 6) = 87500000/3, (9, 7) = 11500000, (9, 8) = 83750000/9, (9, 9) = 22900000/3}),t):
 > M:=Matrix(9, 9, {(1, 1) = 13/5, (1, 2) = 39/20, (1, 3) = 39/25, (1, 4) = 0, (1, 5) = 0, (1, 6) = 0, (1, 7) = 0, (1, 8) = 0, (1, 9) = 0, (2, 1) = 39/20, (2, 2) = 39/25, (2, 3) = 13/10, (2, 4) = 0, (2, 5) = 0, (2, 6) = 0, (2, 7) = 0, (2, 8) = 0, (2, 9) = 0, (3, 1) = 39/25, (3, 2) = 13/10, (3, 3) = 39/35, (3, 4) = 0, (3, 5) = 0, (3, 6) = 0, (3, 7) = 0, (3, 8) = 0, (3, 9) = 0, (4, 1) = 0, (4, 2) = 0, (4, 3) = 0, (4, 4) = 260, (4, 5) = 195, (4, 6) = 156, (4, 7) = 0, (4, 8) = 0, (4, 9) = 0, (5, 1) = 0, (5, 2) = 0, (5, 3) = 0, (5, 4) = 195, (5, 5) = 156, (5, 6) = 130, (5, 7) = 0, (5, 8) = 0, (5, 9) = 0, (6, 1) = 0, (6, 2) = 0, (6, 3) = 0, (6, 4) = 156, (6, 5) = 130, (6, 6) = 780/7, (6, 7) = 0, (6, 8) = 0, (6, 9) = 0, (7, 1) = 0, (7, 2) = 0, (7, 3) = 0, (7, 4) = 0, (7, 5) = 0, (7, 6) = 0, (7, 7) = 13/6000, (7, 8) = 13/8000, (7, 9) = 13/10000, (8, 1) = 0, (8, 2) = 0, (8, 3) = 0, (8, 4) = 0, (8, 5) = 0, (8, 6) = 0, (8, 7) = 13/8000, (8, 8) = 13/10000, (8, 9) = 13/12000, (9, 1) = 0, (9, 2) = 0, (9, 3) = 0, (9, 4) = 0, (9, 5) = 0, (9, 6) = 0, (9, 7) = 13/10000, (9, 8) = 13/12000, (9, 9) = 13/14000}):
 >
 >
 >
 >
 >
 >
 >
 >
 >
 >
 > V:=unapply(Vector(9,i->a[i](t)),t):
 > Vdot:=unapply(Vector(9,i->dd1[i](t)),t):
 > V2dot:=unapply(Vector(9,i->dd2[i](t)),t):
 >
 >
 >
 >
 > for i to 9 do a[i](0):=0 od:
 > for i to 9 do dd1[i](0):=0: od:
 > V2dot(0):=M^(-1).(P(0)-K(0).V(0)):
 >
 >
 > #K(t)(8..10,8..10);
 >
 >
 > #Newmark step by step SOLVER #
 >
 >
 > h:=1/100;
 (1)
 > t:=0;
 (2)
 > hh:=0.5;
 (3)
 > for i from 0 to 0.5 by h do KC:=K(t)+(4/h^2)*M: PC:=(P(t+h)-P(t))+M.((4/h)*Vdot(t)+2*V2dot(t)): Delta(V):=(KC^(-1)).PC: V(t+h):=Delta(V)+V(t): Delta(Vdot):=(2/h)*Delta(V)-2*Vdot(t): Vdot(t+h):=Delta(Vdot)+Vdot(t): Delta(V2dot):=M^(-1).((P(t+h)-P(t))-(K(t).Delta(V))): V2dot(t+h):=Delta(V2dot)+V2dot(t): for k from 1 to 9 do a[k](t+h):=evalf(V(t+h)[k]) od: u[t+h]:=evalf(x*(add(a[m](t+h)*x^(m-1),m=1..m1))-h/2*x*(add(a[m1+m3+m](t)*x^(m-1),m=1..m2))): #plot(u[t+h],x=0..L,title="displacement u for time" ,axes = framed,legend = ["displacement u"],color="NavyBlue"): w[t+h]:=evalf(x*(add(a[m1+m](t+h)*x^(m-1),m=1..m3))): #plot(w[t+h],x=0..L,title="displacement w for time  ",axes = framed,legend = ["displacement w"],color="red"): #phi[t+h]:=evalf(x*(add(a[m1+m3+m](t)*x^(m-1),m=1..m2))); #plot(phi[t+h],x=0..L,title="displacement phi for time  ",axes = framed,legend = ["displacement w"],color="green"); t:=t+h: x:='x'; od:
 > t:='t';w[0]:=0;u[0]:=0;
 (4)
 > x:=1;
 (5)
 > plots:-pointplot({seq([t,w[t]],t=0..0.3,h)});
 >

### Animate Polar Area Being Filled as Curve is Being ...

April 04 2014
3 9

I am using the following commands to create an animation of a simple cardioid being traced out. I would like to add to this an animation of the filling of the region bounded by the curve and the coordinate axes as the curve is being traced out. How might one achieve this?

with(plots):

animatecurve([2-2*sin(theta),theta,theta=0.. 2*Pi],coords=polar,axiscoordinates=polar,frames=250, numpoints=300, scaling=constrained)

Thanks.

 1 2 3 4 5 6 7 Last Page 1 of 146
﻿