Maple 17 Questions and Posts

These are Posts and Questions associated with the product, Maple 17

Vector using package Physics, LinearAlgebra.

Vectores.mw     (in spanish)

I have a rational function

R(s)=(s+21.2618806754099918582959684287)*(s+11.5825785765671047665686926962)*(s+2.32652929385663964079968631791)*(s+1.59184930187007023058678840475)*(s+.810126597053864402120805704729)*(s+.767936478999246633196341750975)*(s+.389728032793176474756405528288)*(s+.389709386740696868210134112440)*(s+.384534001672741409749016411776)*(s+.211738661184088496193941380283)*(s+.211735400886327624028116769728)*(s+0.123260440562617421046327062708e-1)*(s+0.749282759458414677904525855939e-2)*(s+0.129947118285955895103018704133e-2)*(s+0.128454333534479589397814117349e-2)*(s+0.342482256507583139104896521750e-3)*(s+0.342471571076865824849860353286e-3)/(s+21.2618806754099918582960530179)*(s+21.1471825573992794470615428324)*(s+2.32652929385663964079964525218)*(s+2.28350165975702233286000082419)*(s+.810126597053864402120855775248)*(s+.804997206582678244211665005890)*(s+.389728032793176474755312749208)*(s+.389718248252695846631246554139)*(s+.384534001672741409750430258543)*(s+.243633167007009257956784127718)*(s+.211735400886327624028133231990)*(s+.211726934369736929202050835884)*(s+0.749282759458414677904914554540e-2)*(s+0.555247691543530827690454070563e-2)*(s+0.128454333534479589395816020810e-2)*(s+0.126961222591792792857168643430e-2)*(s+0.342471571076865824866184397991e-3)*(s+0.342461825593204099734633561207e-3)

I want to cancell the roots which are equal up to 7 digits?

How to write a maple code for this problem?

okay so im quite confused, im trying to write a procedure that prints the orbit of a 2x2 matrix through a given list of points.  our arguments should be a a (2x2) matrix, a list L of points represented by 2 vectors, ie (2x1) matrices and a natural number N. Returnvalue : NULL

a side effect should be to 

A^i.L[j] for i = 0 ... N and j = 1 ... nops(L)

thus, an example, if the proc is called P, then 

P(Matrix([[0,-1],[1,0]]),[Matrix([[1],[1]]),Matrix([[1],[0]])],2) 

should plot the points  

(1,1) ,(-1,1) , (-1,-1)  for the 1st point  and 

(1,0)  ,(0,1) , (-1,0) for the second

thanks for any help in advance

I wrote the following code inside a code region in order to implement a scalar product for lists:

m:= module() option package; export `*`;
    `*`:= proc( a::list, b::list) option overload;
        return add(i, i  in zip((x, y)-> x*y, a, b));
    end proc;    
end module;
l1:=[1,2,3,4];
l2:=[4,1,0,5];
with(m);
l1*l2;

when i run the code I sometimes get the desired result ->26

but sometimes I get

I don't have any clue, where this weird behaviour comes from.

Any help would be greatly appreciated.

 

Hi there,

I'm quite new to Maple so please forgive me! I have a system of partial differential equations I'm trying to solve in Maple as such below 

 

df/dt = f(1-f) - f * h

dg/dt = g(1-g) * Gradient(1-f * gradient(g))

dh/dt = (g - h) + Laplacian(h),

where f,g,h are functions of space and time (i.e. f(x,y,z,t)). I guess my first question is - is this possible in Maple to evaluate? (I'm currently unsure on ICs as I'm figuring it out from the model - it's a model for cancer growth I'm trying to evaluate but have a rough idea of what I'd use).

If it is possible, can you please share how I'd write this? Everytime I've tried I seem to be failing to define anything properly, so your expertise would be greatly appreciated!

Hello, 

So I have two simultaneous equations, 

T= n1/(1+|T-S|) and S=n2/(n3+|T-S|) 

Where n1, n2 and n3 are constant parameters (from here on I fix n1=1 and n3=0.3). So I want to plot T, S against n2 for different values of n2. 

If I also fix n2 (say, n2=1.5) I  can get values for T and S no problem. 

But I've no idea (after many hours of searching) how to progresss. I know I need the program to put various values of n2 into the two equations and then plot the solutions numerically but I'm unsure what to try next.

Could anyone please shed some light on this?!

Thanks!

solve matrix equation Ax+Bx=C,x is n*n matrix ,forA,B,C is n*n matrix . write maple procedure and check a 2*2 case.

Hi Maple Prime-ers!

I have a question about efficiency.  I have a set of algebraic equations with some polynomials, that I would like to solve at different points.  I've tried using a for-loop and a map-loop.  Here is a example:

 

n:=10000;  #Number of solving points
eq1:={b = ''a^2'', c = b^3/2, d = c^(1/2)*4 + b^2}; #Equation to solve

a := convert([seq(i,i=1..n)],Vector);  #timesteps

ans := Vector[column](n)

## Try solving in a for-next loop
t1 := time():
for q from 1 to n do
ans(q):=solve(subs({'a' = a(q)},eq1)):
od:
t2 := time() - t1;

## try solving in a map loop
t1s := time():
ans_s := map(q->solve(subs({'a' = a(q)},eq1)),a);
t2s := time() - t1s;

On my computer (2.2Ghz, 2 cores), these both take 115s to solve.  Using Map over For-Next did not speed up computational speed.  

The problem I wish to tackle has 12 equations, invovles 5th order polynomials, and n ~= 300000.  Solving this set of equations takes 2-3 hours.

Anyone know a more efficient method?  Thanks for reading :D

 

I'd expect the following to give the result "c+2".

> c := a+b

> simplify(a+b+2)

How can I let Maple know that I'd prefer it to write "c" in place of "a+b" when possible?

The result of the following lines in Maple is V := [5., 3.,5. 11., 6.] that I think should be V := [5., 3.,5. 0., 6.], is there somthing wrong?

 

v1:= Vector([-28., -63., -17., -55., 17.], datatype= float[8]):

V:= LinearAlgebra:-Modular:-Mod(11, v1, float[8]);

bug.mw



Hello, Please how do I compute cdf of student t distribution in maple Tξ+1(.). I have a function that i nvolves student t distribution but finding it difficult to compute student t in the funcion. I am new to maple.

I downloaded Maple 17 student eddition for linux and when I click on the bin file to install it I get an error that says "This file is of unknown type". It gives the option to find an aplication local or online and it says no aplications available or the "MIME" file type canot be installed on this system. Im not sure what to do, do I need somthing to unpack the file or is it just not aplicable on my linux operating system (version: Cinnamon version 1.8.8 LinuxMint: olivia(X86-64))?

Write a procedure which inverts a given 2x2 matrix ie
Given a list of 4 numbers (a,b,c,d) return numbers (x,yz,w) such that
Matrix(a,b,c,d)(Matrix(x,y,z,w)) =Identity matrix

Hi guys! Maple noob here.

I want to get an array of the sums of each and every row of a matrix which I imported from Excel. I can't manage to work my way around with LinearAlgebra-Add, Sum and eval. Maple always shows me the table and not the scalar I am looking for.

I'd also like to know how to tell Maple how to do something on a certain interval of cells of the matrix.

I hope I have been clear and you can help me out :D

Cheers from Italy!

I would like to express 2*sin(x+Pi/4) in the form sqrt(2)*sin(x)+sqrt(2)*cos(x). I've tried many variations using simplify/expand/combine/etc. to no avail. Any ideas?

First 38 39 40 41 42 43 44 Last Page 40 of 61