dharr

Dr. David Harrington

8270 Reputation

22 Badges

20 years, 359 days
University of Victoria
Professor or university staff
Victoria, British Columbia, Canada

Social Networks and Content at Maplesoft.com

Maple Application Center
I am a retired professor of chemistry at the University of Victoria, BC, Canada. My research areas are electrochemistry and surface science. I have been a user of Maple since about 1990.

MaplePrimes Activity


These are answers submitted by dharr

restart: z:=1; type(z,Range(1,10)); is(z,RealRange(1,10)); returns false true
pointplot will plot points: with(plots): pointplot([[1,1],[2,2],[3,5],[4,4],[5,3]]); If you have lists you need to manipulate into this form, you can use zip: ycoord:=[1,2,5,4,3]:xcoord:=[1,2,3,4,5]: zip((x,y)->[x,y],xcoord,ycoord);
A lot depends on how you are generating your lists of numbers. If I understand correctly, you want something like this: f:=proc(C,D,E,F,G,H,K,L,M,N,O,P) local A,B,II,J; A:=3;B:=5;II:=5;J:=6; ((A/B)^(3/2)*(C*D*E/F*G*H)/(II/J)^(3/2)* (K*L*M/N*O*P)) end proc: Define a sequence or list of numbers seq1:=1,2,3,4,5,2,3,4,5,3,3,1; list1:=[1,2,3,4,5,2,3,4,5,3,3,1]; then the following are equivalent: f(seq1); f(op(list1)); f(list1[]); And pass the 11 lists to the procedure in a loop. You could also pass the list rather than its contents to the procedure and have the procedure get the numbers out of the list with op(list) But perhaps you want the 11 lists related in some way; I'm not sure I understand since there are more than 11 values which are not constant.
Since you want a numerical answer, just give values of mu or T. Success may depend on the values (x>mu or not, perhaps), but this works for at least one set of values. f:=sqrt(x)/(exp((x-mu)/T)+1); eval(f,{mu=-10,T=300}); evalf(Int(%,x=0..infinity));
I'd leave out the integral in dsolve, get the answer with an unknown constant, and then use the equation with the integral to find the unknown constant: sol2:=rhs(dsolve({diff(c(x),x,x)=c(x) , c(0)=5},c(x))); sol2 := (5 - _C2) exp(x) + _C2 exp(-x) > eq:=int(sol2,x=0..1)=3; eq := -5 + 2 _C2 + 5 exp(1) - _C2 exp(1) - exp(-1) _C2 = 3 > solve(eq,_C2); > eval(sol2,_C2=%);
The following works, but I'll let someone else explain why your code doesn't. TestProc:= proc (s) subsop(3=5,s) end proc;
diffEq := (diff(y(x), x, x))-7*(diff(y(x), x)) = 7*exp(3*t); dsolve({diffEq, y(0) = 1, D(y)(0) = 3}, y(x)); exp^(3*t) should be exp(3*t), and the second initial condition needs to be D(y)(0)=3.
if you use infolevel[dsolve]:=4; before using dsolve, it will print out some information about what it is doing (larger number, more detailed information.
As far as I know, Maple cannot work with matrices of an unspecified (abstract) size. You can get the inverse by working from its definition in terms of the adjugate; Maple's help system gives the definition.
Find the Jacobian, say using: with(plots):with(LinearAlgebra):with(VectorCalculus): LV := [diff(x(t), t) = 0.2e-1*x(t)-0.5e-2*x(t)*y(t), diff(y(t), t) = 0.1e-1*x(t)*y(t)-0.1e-1*y(t)]: map(rhs,LV):subs(x(t)=X,y(t)=Y,%): J:=Jacobian(%,[X,Y]); Then find the eigenvalues as a function of x(t) and y(t): ev1,ev2:=subs(X=x(t),Y=y(t),Eigenvalues(J,output=list))[]; Solve the odes for some set of initial conditions (I'm assuming you want a numerical solution): ans:=dsolve({LV[],x(0)=1,y(0)=0.2},{x(t),y(t)},numeric); And then plot things using odeplot, e.g., for ev1 as a function of time: odeplot(ans,[t,ev1],t=0..10); If you want numerical values, e.g. ev1 at t=5: subs(ans(5),ev1);
Construct your matrix M and then use collect(M,beta);
For example, f:=x->2*x; # simple function with some negative values plot(f(x), x = -10 .. 10, -10 .. 10, axis = [mode = log]); plots (in Maple 10) a nice log-log plot, but only from 10^(-6) to 10^1, since log of a negative number is not defined.
Perhaps you have some particular functions in mind? But in the general case: A:=int(int(F(u)*G(u,v),v=0..infinity),u=0..max); B:=int(F(u)*int(G(u,v),v=0..infinity),u=0..max); then simplify(A-B); returns 0, indicating they are the same. Is this what you meant?
See the help page on convert,base
You are right that Maple's densityplot seems not to accept polar coordinates (using coords=polar). You can get it to work by converting to cartesian and then restricting to the section you want. So to do the 3px orbital and look at the section through the x-y plane you would convert to cartesian coordinates and then set z=0. (My Orbitals package, available from the applications centre, has commands to simplify this and gives an example of a density plot in the ?Orbitals,plots help page (though you need to square it to get the probability density)). As you note, there will not be a density plot in spherical coordinates because you can only plot surfaces in 3D. If you don't want the density of a planar section of the wavefunction, but, say, one of those random dot pictures, then you would have to generate the dots using the probability and plot using pointplot3D.
First 76 77 78 79 80 81 82 Page 78 of 82