gkokovidis

2335 Reputation

13 Badges

20 years, 299 days
Draeger Medical Systems, Inc.

 

 

Regards,
Georgios Kokovidis
Dräger Medical

MaplePrimes Activity


These are answers submitted by gkokovidis

Here is another way, similar to the above, without the use of single quotes.  It is a little bit faster for larger ranges of 'x'.

restart:

plot(int(exp(-x^2),x),x=-4..4);

 

 

 

Download int_plot.mw

Look at help page for ?Digits to control how many Digits get used during the computation.  This will also affect the number of digits that get displayed.

for i from 1 to 5 do
    A:= i:
    B:= 2*i:
    C:= A+B;
    print(C);
end do:

                               3
                               6
                               9
                               12
                               15


The code modification above does what you are looking for.


Regards,

Georgios

Look at the help file for the ?coeffs command.

 

restart:

eq:=23*x^4 + (12*h)*x^2;

coeffs(eq,x);

There is another command as well.  See help pages here.

 

Regards,

Georgios

The issue with the Integration Tutor, or any other tutor for that matter, has to do with how you enter your functions.  In your specific case, you have to include the multiplication sign after the 5.  See image below.

Regards,

Georgios

Hello tantan.  This is a place to get help with Maple related questions.  You will have better chances with help to your question here.

Regards,

Georgios

The Maple equivalent of the Matlab .* command is *~.  See here for more details.

Regards,

Georgios

You can combine plots with the ?display function.  See below.  If this is not what you are looking for, let us know.


restart:with(plots):

p1:=dualaxisplot(sin(x), cos(x), x = 0 .. 2*Pi, color = ["Blue", "Green"]):

p2:=dualaxisplot(2*sin(x), 2*cos(x), x = 0 .. 2*Pi, color = ["Orange", "Brown"]):

display(p1,p2);

 

 

Download dualaxisplotcombine.mw

Regards,

Georgios

See link here as a starting point.

 

Regards,

Georgios

 

 

I am not too familiar with the Calculator, but this works;

cos(X)-X

Then click graph, and you will see the plot. In Maple, you can do it as follows.  There are other ways as well.

restart;

plot(cos(x)-x,x);

 

fsolve(cos(x)-x,x);

.7390851332

(1)

 

Download cos(x)-x.mw

 

Regards,

Georgios

Here is one way:

 

restart:printlevel:=0:

for alpha from .4 by .1 to 5 do
S := solve(x^4-alpha, x);
print(S[2]):
end do:

 

Regards,

Georgios

It might have to do with how you entered your data.


restart:with(Statistics):

A :=<21.5, 22, 22, 22, 22, 22.5, 22.5, 23, 23, 23, 23, 23.5, 24, 24, 25>;

A := Vector(15, {(1) = 21.5, (2) = 22, (3) = 22, (4) = 22, (5) = 22, (6) = 22.5, (7) = 22.5, (8) = 23, (9) = 23, (10) = 23, (11) = 23, (12) = 23.5, (13) = 24, (14) = 24, (15) = 25})

(1)

Mode(A);

23.

                                                       (2)

 


Download Mode.mw

Regards,

Georgios

Here is one way to do this, using the Roots function.

restart:with(Student[Calculus1]):

eq:=sin((Pi*x^2)/2);

plot(eq,x=-5..5);

Roots(eq, -5 .. 5);

evalf(%);

 

Regards,

Georgios Kokovidis

Dräger Medical

This has nothing to do with your functions, since the built ins have the same effect.  You can impose floating point approximations by including a decimal point after each of your numbers, or executing an evalf after the fact.

 

restart:

Vector[column]([ cos(6) ,
                 cos(90) ]);

Vector(2, {(1) = cos(6), (2) = cos(90)})

(1)

evalf(%);

Vector(2, {(1) = .9601702867, (2) = -.4480736161})

(2)

restart:

Vector[column]([ cos(6.) ,
                 cos(90.) ]);

Vector(2, {(1) = .9601702867, (2) = -.4480736161})

(3)

Matrix([[ cos(6) ],
        [ cos(90) ]]);

Matrix(2, 1, {(1, 1) = cos(6), (2, 1) = cos(90)})

(4)

evalf(%);

Matrix(2, 1, {(1, 1) = .9601702867, (2, 1) = -.4480736161})

(5)

restart:

Matrix([[ cos(6.) ],
        [ cos(90.) ]]);

Matrix([[.9601702867], [-.4480736161]])

(6)

 

Download FuncMatrixVector.mw

Regards,

Georgios Kokovidis

Dräger Medical

Here is another way, using the float option to ?writedata.  For this specific example, the output, on a WinXP machine, with be in the C:\temp drive. If you edit the file "mpltest.dat", you will see 20 digits of precision.

restart:Digits:=20:

f:=x->0.3333334444433332211*x^2;        

f := proc (x) options operator, arrow; .3333334444433332211*(x^2) end proc

        Data:=[seq([i,f(i)],i=1..10)];

Data := [[1, .3333334444433332211], [2, 1.3333337777733328844], [3, 3.0000009999899989899], [4, 5.3333351110933315376], [5, 8.3333361110833305275], [6, 12.000003999959995960], [7, 16.333338777723327834], [8, 21.333340444373326150], [9, 27.000008999909990909], [10, 33.333344444333322110]]

You have to edit the file address to a diskette or directory where you have write privileges to execute this yourself:

writedata("c:/temp/mpltest.dat",Data);

To see the output, you can write it to your screen:

writedata(terminal,Data,float);

1        0.3333334444433332211
2        1.3333337777733328844
3        3.0000009999899989899
4        5.3333351110933315376
5        8.3333361110833305275
6        12.00000399995999596
7        16.333338777723327834
8        21.33334044437332615
9        27.000008999909990909
10        33.33334444433332211

   

Download writedata.mw

 

Regards,

Georgios Kokovidis

Dräger Medical

Are you looking for a numeric result, or something else, where the output is in terms of log10, and not a ratio of ln, as shown below.  For numeric results, just include a decimal point after your number for force a floating point apporoximation of the result.

restart:

log10(65);

ln(65)/ln(10)

(1)

log10(65.);

1.812913357

(2)

 

 

Download log10.mw

 

Regards,

Georgios Kokovidis

Dräger Medical

First 7 8 9 10 11 12 13 Last Page 9 of 75