Items tagged with seq seq Tagged Items Feed

I'm taking calculus and my professor introduced us to maple software. The professor asked us to plot the families of curves for this orthogonal equation:

dy/dx = (x^2) - (2y^2) - C = 0

This is what I had so far:

 

restart;

with(DEtools):

with(plots):

 

Function:=unapply(simplify(x^2-2y^2-C),(x,y)):

'Function'(x,y) = Function(x,y);

plotFunction:=C->implicitplot(eval(F(x,y),a=C),x=-5..5,y=5..5,scaling=constrained):

plot1:=display(seq(plotFunction(a),a=-5..5)):

display(plot1);

 

This is only display one family. How do I code for it plot the other families?

(The graph should look like curves converging from left, top and right sides toward to the origin of the axes)

Please help.

Hi,

I have a 4-D function that I have found an analytic expression for in Maple, but I want to generate a numerical 4-D array, which I can export for use in Matlab. However, I don't think I'm using a very good solution, because it is extremely slow (several minutes for even 10x10x10x10 elements). My code is

NumRange:=10:
NumElements:=10:
dx:=2*NumRange/(NumElements-1):
A:=Array(1..NumElements,1..NumElements,1..NumElements,1..NumElements,[seq([seq([seq([seq(evalf(rho(ws1,ws2,ws1p,ws2p)),ws2p=-NumRange..NumRange,dx)],ws1p=-NumRange..NumRange,dx)],ws2=-NumRange..NumRange,dx)] , ws1=-NumRange..NumRange,dx)],datatype=float);

Rho is an exponential with 10 terms in the exponents.

I also tried using four for-loops but that was even slower!

Thanks for any input

I was trying to create a array or table with the following columns

1. angle in radians,

2. angle in grades

3. sinus (x)

4. cosinus (x)

5. tangent(x)

 

for x= 0, pi/12, 2pi/12.. 2pi.

I was trying to use seq()

 

seq([(1*Pi/12*j),sin(1*Pi/12*j)], j=0..24);

 

but I cannot get something nicely "arranged" (like in a table or matrix) to export to latex.

 

could somebody give me a help..please?

 

thanks in advance,

 

Jean

 

x11 := Vector([0.208408965651696e-3, -0.157194487523421e-2, -0.294739401402979e-2, 0.788206708183853e-2, 0.499394753201753e-2, 0.191468321959759e-3, 0.504980449104750e-2, 0.222150494088535e-2, 0.132091821964287e-2, 0.161118434883258e-2, -0.281236534046873e-2, -0.398055875132037e-2, -0.111753680372819e-1, 0.588868146012489e-2, -0.354191562612469e-2, 0.984082837373291e-3, -0.116041186868374e-1, 0.603027845850267e-3, -0.448778128168742e-2, -0.127561485214862e-1, -0.412027655195339e-2, 0.379387381798949e-2, -0.602550446997765e-2, -0.605986284736216e-2, -0.751396992404410e-2, 0.633613424008655e-2, -0.677581832613623e-2]):
y11 := Vector([ -21321.9719565717, 231.709204951251, 1527.92905167191, -32.8508507060675, 54.9408176234139, -99.4222178124229, -675.771433486265, 42.0838668074923, -12559.3183308951, 5.21412214166344*10^5, 1110.50031772203, 3.67149699000155, -108.543878970269, -8.48861069398811, -521.810552387313, 26.4792411876883, -8.32240296737599, -1085.40982521906, -44.1390030597906, -203.891397612798, -56.3746416571417, -218.205643256096, -178.991498697065, -42.2468018350386, .328546922634921, -1883.18308996621, 111.747881085748]):
z11 := Vector([ 1549.88755331800, -329.861725802688, 8.54200301129155, -283.381775745327, -54.5469129127573, 1875.94875597129, -16.2230517860850, 6084.82381954832, 1146.15489803104, -456.460512914647, 104.533252701641, 16.3998365630734, 11.5710907832054, -175.370276462696, 33.8045539958636, 2029.50029336951, 1387.92643570857, 9.54717543291120, -1999.09590358328, 29.7628085078953, 2.58210333216737*10^6, 57.7969622731082, -6.42551196941394, -8549.23677077892, -49.0081775323244, -72.5156360537114, 183.539911458475]):

 

> seq({round(x11[k]), round(y11[k]), round(z11[k])}, k = 1 .. 27);
{-21322, 0, 1550}, {-330, 0, 232}, {0, 9, 1528}, {-283, -33, 0}, {-55, 0, 55},

{-99, 0, 1876}, {-676, -16, 0}, {0, 42, 6085}, {-12559, 0, 1146},

{-456, 0, 521412}, {0, 105, 1111}, {0, 4, 16}, {-109, 0, 12}, {-175, -8, 0},

{-522, 0, 34}, {0, 26, 2030}, {-8, 0, 1388}, {-1085, 0, 10},

{-1999, -44, 0}, {-204, 0, 30}, {-56, 0, 2582103}, {-218, 0, 58},

{-179, -6, 0}, {-8549, -42, 0}, {-49, 0}, {-1883, -73, 0}, {0, 112, 184}

 

https://drive.google.com/file/d/0B2D69u2pweEvS0RVTFZWTnVKWms/edit?usp=sharing

{-49, 0}

there is a missing comma in this, is it the built in robot in maple playing human or my window make a joke?

 

this bug make me get an misunderstanding from mathematica stackexchange

 

https://drive.google.com/file/d/0B2D69u2pweEvZXp5WndMN0x5VGs/edit?usp=sharing

 

i can not display web correctly, What's wrong with me?

I have a command in Maple that looks like

Hi all,

I just learned about the with(Threads) package and I wanted to do a bit testing and see if it's 'faster' or more 'efficient'.

Test.pdf

 

This was done on a i7 940X (QuardCore) laptop.

I dont really see how it is better in a sense?

Or am I using Seq for the wrong purpose?

 

Casper

Is there a way to have Maple compute the limit of a recursive sequence? For example, the sequence below

a_n = (a_(n-1) +2)/(a_(n-1) + 3), a_1 =2

is bounded and montonically decreasing, thus has a limit, but Maple is not able to compute the limit. Any ideas?

Dear all,

need to take data(a,u) from eq1 and plug it in eq2

eq1 is:

eq2 is:

Then need to plot data (a,v)

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

I did that:

points:=seq([a,evalf(solve((alpha+(l+alpha)*u+alpha*k*u^2)*a=u*(alpha+(l+alpha)*u+alpha*k*u^2...

The mysterious `if`...

November 22 2012 PatrickT 1938 Maple


On several occasions, while working with lists or Matrices, I have been drawn to using a combination of seq and if, as in the following:

seq(`if`(a,b,c), i = 1 .. 10 )

This appears to be a powerful approach. Unfortunately, I have not found much documentation on it.

I have been able to pattern-guess to a limited extent for my limited needs.

Would you know of a good place to go for information?

My understanding is: "a" is the conditional...

I have written a procedure to overload a new "Subs" function. It uses a seq of equations as its first argument followed by the object to act upon (yes, it is to have subs functionality on these objects). I find the overloading works when I have just one equation in the argument list, but with more than one it never calls any of the procedures. The code worked with multiple equations before I overloaded it (i.e. the first proc was verified by itself). FWIW the objects (elemt or bm...

I have a somewhat time-consuming numerical integration which is needed for many different parameters so I'd like to parallelize the various integrations. Threads:-Seq should be just the ticket for this; so I write:

respr128:=[Threads:-Seq(evalf(Int(S(ener,Ecrit)*rangeexp(amp,depth/4,t0[128]),ener=0.001..10*Ecrit,method=_d01ajc,epsilon=1.0e-5)),depth=1..36)];

The functions S and rangeexp are defined thus:

S:=(omega,omega_c)->(9*sqrt(3)/(8*Pi)*omega/omega_c...

I have got the following instructions of computing the required trajectories (orbits). They have been done with Maple V3. I cannot get them going with Maple 16. I have just started with Maple and cannot see the mistake in the instruction. Can anybody help me? Thanks!


> with(LinearAlgebra);
> "A, B = Payoff matrices for players";
> A := matrix(2, 2, [4, 2, 1, 3]); B := matrix(2, 2, [1, 4, 3, 2]);
> "T defines the time interval [0,T], s is the step length";

Hi, here is what I have. How do I assign the each A please?

with(LinearAlgebra):
interface(rtablesize=infinity):

A:=seq(Matrix(18),i=1..21):
A[1]:=IdentityMatrix(18):

It wouldn't allow me to assign A[1]. May I know how do I do it please?

Thanks

Hi everyone,

 

Working on my project, I have this error "Error, (in VectorCalculus:--) too many levels of recursion".

The project is about filetring a stochastic process.

 

When I want to calculate one of the integrals, I have that error.

Here is the code:

 

Rxi:=sqrt(d)*IdentityMatrix(4):
xi:=WienerProcess(Rxi);
Reta:=sqrt(d)*IdentityMatrix(2):
eta:=Array([WienerProcess(Reta...

Hi,

See the code mli.mws

What is the mistake in this command ?

chfonc:=cat('piecewise(' , seq(cat(convert(t<lf[k],string) , ' , 1 , ' ,convert(t<lf[k],string), ' , 1 , ' ) , k=1..p) , '1) ') :

1 2 3 Page 1 of 3