Unanswered Questions

This page lists MaplePrimes questions that have not yet received an answer

after integration,
result is x^2

f := x^2

we know in the range 5..-5 = 5^2 - (-5)^2 = 0

this example is not good enough, as i can be any number x, -x

if in another example, i use a and b to represent that would like to find

3*a^2 - 3*b^2 = 0, how to find possible a and b?

my example is not good, is there example that a and b are different number, not only in sign

Notepad displays alt+1, alt+2 and alt+3 as ☺☻♥

Just wondering why Maple displays them as square boxes?  Shouldn't it have the font capability to display them as well?

Hi all,

I tried to create the*.exe file by C and call the kernel of maple for calculation.

To understand the OpenMaple, I ran the OpenMaple C code sample, “simple.c” in “<Maple>\ samples\OpenMaple\simple” through Microsoft Visual C++ 2008 but got the incorrect result:

 

It’s seems that the error is happen due to the wrong maple directory. But according to the description of "kernelopts" in help, the value of mapledir cannot be set.

 

Refer to the description of  "OpenMaple,Examples" in help , both header file path and library file path had been set:

O/S: Windows (32-bit)

Header file Directories: "C:\Program Files\Maple 17\extern\include"

Library Directories: "C:\Program Files\Maple 17\bin.win"

Environment Variable: "C:\program files\Maple 17\bin.win"

 

I'd appreciate any help on this topic. Thank a lot.

Has anyone used Maple for Empirical Mode Decomposition ? Any tips, Maple docs ? I can't seem to find anything when searching Maple sites.

I have recently written a maple program to deconvolute gamma-ray spectra using the Richardson-Lucy algrithm. Although this method works well I would prefer to use a method based on the Maximum Entropy algorithm, and would like to know if anyone has tried to write a Maple program to deconvolute 1 dimensional data?

In ode solve command i generated a large array data. The output shows a large order matrix of this form

 

[110001x6 Matrix

Datatype:Anything

Storage:rectangular

order:Fortran_order].

 

I want to export this matrix into a notepad. Which can then be used for plotting in TecPlot. 

 

Looking for good response

 

 

I'm trying to display some flow lines for a vector field. The vector field I have is:

What I put into Maple is:

I've tried this with a number of points, but I always get an error message along the lines of:

"Error, (in Student:-VectorCalculus:-FlowLine) cannot determine if this expression is true or false: (2.*(1)(0)-4.)^2+(-2.+4.*(1)(0))^2 < 0.9e-9"

Could someone please shed some light as to what's going wrong for me? I would be very grateful for any help.

Thanks.

a := matrix(...);
b := Convert to hermit matrix from a;
Norm(MatrixMatrixMultiply(b, a), 2) = Norm(a,2)^2

i have tried, but not exactly equal
Norm(MatrixMatrixMultiply(b, a), 2) = 0.01
Norm(a,2)^2 = 0.1

Guess what matrix a is?

How to calculate colimit with only substitution and solve? Any simple example to show the steps.

run a command string in C# by calling maple

it can run in maple if copy into maple

however return input string was not in correct format

String commandstring = "restart;with(LinearAlgebra):with(ExcelTools): filename := "0257.HK";open3 := Import(cat(cat("C://Temp//HK//Transportation//",filename),".xls"), filename, "B2:B100");high3 := Import(cat(cat("C://Temp//HK//Transportation//",filename),".xls"), filename, "C2:C100");low3 := Import(cat(cat("C://Temp//HK//Transportation//",filename),".xls"), filename, "D2:D100");close3 := Import(cat(cat("C://Temp//HK//Transportation//",filename),".xls"), filename, "E2:E100");n := 30;Round := proc(x,n::integer:=1) parse~(sprintf~(cat("%.",n,"f"),x)); end proc: t:=1; gg :=Matrix(n+1,1); ggg :=Matrix(n+1,1); for k from 0 to n do InputMatrix3 := Matrix([[close3[t+1+k] , close3[t+k], close3[t+2+k]],[close3[t+k], close3[t+2+k],0],[close3[t+2+k],0 , 0]]): InputMatrix3b := Matrix([[close3[t+2+k], close3[t+1+k] , close3[t+3+k]],[close3[t+1+k] , close3[t+3+k],0],[close3[t+3+k],0 , 0]]): InputMatrix3c := Matrix([[close3[t+3+k] , close3[t+2+k], close3[t+4+k]],[close3[t+2+k], close3[t+4+k],0],[close3[t+4+k],0 , 0]]): Old_Asso_eigenvector := Eigenvectors(MatrixMatrixMultiply(Transpose(InputMatrix3), InputMatrix3)): Old_Asso_eigenvector2 := Eigenvectors(MatrixMatrixMultiply(Transpose(InputMatrix3b), InputMatrix3b)): Old_Asso_eigenvector3 := Eigenvectors(MatrixMatrixMultiply(Transpose(InputMatrix3c), InputMatrix3c)): gg[k+1,1] :=Old_Asso_eigenvector[2][1,1]; od;Round(Re(gg[1,1][1,1]));";

 

(g o f ) o alpha =g o (f o alpha)
restart;alpha := (1/2)*(-x-x*t1-y*t2-y*t3+sqrt(x^2+2*x^2*t1+2*x*y*t2+2*x*y*t3+x^2*t1^2+2*x*t1*y*t2+2*x*t1*y*t3+y^2*t2^2+2*y^2*t2*t3+y^2*t3^2-4*x*t4*y*t9-4*x^2*t4*t7-4*x*t4*y*t8-4*y^2*t9-4*y*x*t7-4*y^2*t8-4*y^2*t5*t9-4*y*t5*x*t7-4*y^2*t5*t8-4*y^2*t6*t9-4*y*t6*x*t7-4*y^2*t6*t8))/(x*t4+y+y*t5+y*t6);
g := -y/x;
f := (-x+sqrt(x^2-x*y-2*y^2))/(2*y+x);
subs(p=f,subs(q=f,subs(x=p,subs(y=q,g)))); # -1
g := (-x+sqrt(x^2-x*y-2*y^2))/(2*y+x);
f := x*y;
gof := subs(p=f,subs(q=f,subs(x=p,subs(y=q,g)))); # -(1/3)*(y/x+sqrt(-2*y^2/x^2))*x/y
lhsgofoalpha := subs(q= alpha,subs(p=alpha, subs(x=p,subs(y=q,gof))));
foalpha := subs(p= alpha,subs(q=alpha,subs(x=p,subs(y=q,f))));
rhsgofoalpha := subs(x= foalpha,subs(y= foalpha, g));
osys := lhsgofoalpha = rhsgofoalpha;
sys1 := subs(x=0, osys);
sys2 := subs(y=0, osys);
sys3 := subs(x=1, osys);
sys4 := subs(y=1, osys);
sys5 := subs(x=2, osys);
sys6 := subs(y=2, osys);
sys7 := subs(x=3, osys);
sys8 := subs(y=3, osys);
sys9 := subs(x=4, osys);
sys1 := subs(x=3,subs(y=2, osys));
sys2 := subs(x=5,subs(y=1, osys));
sys3 := subs(x=1,subs(y=5, osys));
sys4 := subs(x=1,subs(y=2, osys));
sys5 := subs(x=2,subs(y=5, osys));
sys6 := subs(x=5,subs(y=2, osys));
sys7 := subs(x=2,subs(y=1, osys));
sys8 := subs(x=3,subs(y=5, osys));
sys9 := subs(x=5,subs(y=3, osys));
res:=solve([sys1, sys2, sys3, sys4, sys5, sys6, sys7, sys8, sys9], {t1,t2,t3,t4,t5,t6,t7,t8,t9});
eval(osys,res);
simplify(%);
`~`[lhs](select(evalb, res));

I want to begin by saying hello! im new to the forums i hope some one can give me a push in the right direction with some of my maple homework. im sort of stuck on a few of these questions and would be greatfull for some help. 

 

Let .

a) Let g be the tangent line to f when x = c. Use Maple to find g as a function of c.

b) Use Maple to plot f and g(3) using view = [0..5, -25..100].

c) Define a function called plot_tan that plots both f and g(c) where f is blue and g(c) is red. Also use the same view as in part (b). Note that plot_tan is also a function of c.

d) Using your function plot_tan, the following all in one graph using the display command:

plot_tan(1), plot_tan(1.5), plot_tan(2), plot_tan(2.5), plot_tan(3), plot_tan(3.5), plot_tan(4), plot_tan(4.5), plot_tan(5).

e) Try using the option insequence = true in the display command. What does this option do? (You will need to click on the graph and play around with some buttons).

now it seems to me i have to use the point slope formula to get to a fuction g of c. thanks in advance! i hope you can help

 

 

Question

Find t1,t2,t3,...t9 in Matrix
Matrix(3, 3, {(1, 1) = 1+t1, (1, 2) = t2, (1, 3) = t3, (2, 1) = t4, (2, 2) = 1+t5, (2, 3) = t6, (3, 1) = t7, (3, 2) = t8, (3, 3) = t9})

osys := (1/2)*(-x-x*t1-y*t2-y*t3+sqrt(x^2+2*x^2*t1+2*x*y*t2+2*x*y*t3+x^2*t1^2+2*x*t1*y*t2+2*x*t1*y*t3+y^2*t2^2+2*y^2*t2*t3+y^2*t3^2-4*x*t4*y*t9-4*x^2*t4*t7-4*x*t4*y*t8-4*y^2*t9-4*y*x*t7-4*y^2*t8-4*y^2*t5*t9-4*y*t5*x*t7-4*y^2*t5*t8-4*y^2*t6*t9-4*y*t6*x*t7-4*y^2*t6*t8))/(x*t4+y+y*t5+y*t6) = (-x+sqrt(x^2-x*y-2*y^2))/(2*y+x)
sys1 := subs(x=0, osys);
sys2 := subs(y=0, osys);
sys3 := subs(x=1, osys);
sys4 := subs(y=1, osys);
sys5 := subs(x=2, osys);
sys6 := subs(y=2, osys);
sys7 := subs(x=3, osys);
sys8 := subs(y=3, osys);
sys9 := subs(x=4, osys);
solve([sys1, sys2, sys3, sys4, sys5, sys6, sys7, sys8, sys9],[t1,t2,t3,t4,t5,t6,t7,t8,t9]);

 

since i have only one equation osys, to find t1..t9, i substitute some values into x and y to get enough equation to solve this , however, the result is not expected below

 

then i try without x= 0 or y = 0 , i failed

sys1 := subs(x=3,subs(y=2, osys));
sys2 := subs(x=5,subs(y=1, osys));
sys3 := subs(x=1,subs(y=5, osys));
sys4 := subs(x=1,subs(y=2, osys));
sys5 := subs(x=2,subs(y=5, osys));
sys6 := subs(x=5,subs(y=2, osys));
sys7 := subs(x=2,subs(y=1, osys));
sys8 := subs(x=3,subs(y=5, osys));
sys9 := subs(x=5,subs(y=3, osys));
solve([sys1, sys2, sys3, sys4, sys5, sys6, sys7, sys8, sys9],[t1,t2,t3,t4,t5,t6,t7,t8,t9]);

 

 

solution : Matrix(3, 3, {(1, 1) = 2, (1, 2) = 0, (1, 3) = 0, (2, 1) = 1, (2, 2) = 1, (2, 3) = 1, (3, 1) = 0, (3, 2) = 0, (3, 3) = 1})

 t1 = 1

t2 = 0

t3 = 0

t4 = 1

t5 = 0

t6 = 1 

t7 = 0

t8 = 0

t9 = 1

Data.xlsx

XY.mw

XYZ.mw

 

Hello,

I'm using the Global Optimization Toolbox to solve some examples and fit equations to a given data, finding "unknown" parameters. I generated the data on Excel, and I already know the values of these parameters.

The XY case is (there is no problem here, I just put as a example I follow):

> with(GlobalOptimization);
> with(plots);

> X := ExcelTools:-Import("F:\\Data.xlsx", "Plan1", "I5:I25");
> Y := ExcelTools:-Import("F:\\Data.xlsx", "Plan1", "J5:J25");

> XY := zip( (X, Y) -> [X, Y] , X, Y);
> fig1 := plot(XY, style = point, view = [.9 .. 3.1, 6 .. 40]);


> Model := A+B*x+C*x^2+D*cos(x)+E*exp(x):
> VarInterv := [A = 0 .. 10, B = 0 .. 10, C = -10 .. 10, D = 0 .. 10, E = 0 .. 10];

> ModelSubs := proc (x, val)

    subs({x = val}, Model)

    end proc;


> SqEr := expand(add((ModelSubs(x, X(i))-Y(i))^2, i = 1 .. 21));
> CoefList := GlobalSolve(SqEr, op(VarInterv), timelimit = 5000);

> Model := subs(CoefList[2], Model):

 

I could find the right values of A, B, C, D and E. 

 

My problem is in the XYZ case, where I don't know how to "write" the right instruction. My last attempt was:

> with(GlobalOptimization);
> with(plots);

> X := ExcelTools:-Import("F:\\Data.xlsx", "Plan1", "Q5:Q25"); X2 := convert(X, list);
> Y := ExcelTools:-Import("F:\\Data.xlsx", "Plan1", "R5:R25"); Y2 := convert(Y, list);
> Z := ExcelTools:-Import("F:\\Data.xlsx", "Plan1", "S5:S25"); Z2 := convert(Z, list);
> NElem := numelems(X);

> pointplot3d(X2, Y2, Z2, axes = normal, labels = ["X", "Y", "Z"], symbol = box, color = red);

 

> Model := A*x+B*y+C*sin(x*y)+D*exp(x/y);

> VarInterv := [A = 0 .. 10, B = 0 .. 10, C = 0 .. 10, D = 0 .. 10];

> ModelSubs:=proc({x,y},val)

subs({(x,y)=val},Model)

end proc:
Error, missing default value for option(s)

> SqEr := expand(add((ModelSubs(x, y, X(i), Y(i))-Z(i))^2, i = 1 .. NElem));
> CoefList := GlobalSolve(SqEr, op(Range), timelimit = 5000);
Error, (in GlobalOptimization:-GlobalSolve) finite bounds must be provided for all variables

 

My actual problem involves six equations, six parameters and four or five independent variables on each equation, but I alread developed a way to solve two or more equations simultaneously.

Thanks

Does anybody know why the answer of a equation i am getting on maple is coming with "eval" written?

Example:

 

the answer should be a number ...

Why does it happen?

 

 

First 243 244 245 246 247 248 249 Last Page 245 of 334