taro

445 Reputation

12 Badges

6 years, 96 days
Maple is to me difficult. The first version I bought was Maple9, and it was more than 15 years ago. But, I couldn't use it, feeling it too difficult. But, three years ago, I thought Maple might be helpful to my study, and since then, I have continued to learn Maple. As I got able to read the Maple help, I think that I could get to use maple better now than before. But, I feel that I am a beginner yet.

MaplePrimes Activity


These are questions asked by taro

Hello people in mapleprime,

Though I wrote the title as Fundamental theorem of calculus,

what I am considering is just how to continue the chain of codes in calculation.

restart;

#I defined F__0 as

F__0:=x->Int(f(t),t=a..x);

#Then, the difference between a primitive function of f(x), F(x), and F__0 is no more than a constant C, so I write.

bb:=F(x)-F__0(x)=C;

#Then, substituting "a" into equation "bb", I obtain the value of F(a)

bb1:=subs(x=a,bb):cc:=simplify(%);

#Then, I substituted the value of C in "bb1" into "bb,"  obtaining the following "cc1."

cc1:=subs(isolate(cc,C),bb);

#And, then, I isolated the term of Int(f(t),t=a..x)  in cc1,

dd:=isolate(cc1,Int(f(t), t = a .. x));

#And, then, I substitute x=b into the outcome of dd, and obtain the final equation.

subs(x=b,dd);

 

Surely, with the above code, I could get the fundamental theorem. But, it looks in a little roundabout way.

So, I thought I would ask here about whether there aren't any better ways to do the fundamentally the same thing or

hints to improve the above code.

Please teach me about this.

 

Thanks in advance.

 

taro

Hello people in the mapleprimes,

I have a question, so I hope someone give me answers to it.

I calculated for the solution of the follwing differential equation.

restart
b:=diff(y(x),x)+a*y(x)=f(x);#where a and f(x) is not specified.
dsolve(b,y(x));

subs({f(x)=exp(x),a=2},%);where f(x) and a are specified.

c:=value(%);

The solution of the above was

y(x) = (1/3)*exp(x)+_C1/(exp(x))^2,  (A)

where please note that the second term takes

the form of fraction _C/(exp(x))^2.

 

On the other hand, next I calculated the following differential equation where f(x) and a are specified from the start.

restart
d:=diff(y(x),x)+2*y(x)=exp(x);

dsolve(b,y(x));

Then,

y(x) = (1/3)*exp(x)+exp(-2*x)*_C1  (B)

was the obtained solution.

 

Each (A) and (B) are the same substantially mathematically. But, for Maple, the variable powered to minus brabra

is not the same as one over variable powered to brabra, so that (A) and (B) takes different forms, and maple will see them 

different with each other.

 

  Surely, with algsubs, algsubs(_C1/(exp(x))^2=exp(-2*x)*_C1,c) transforms (A) to (B).

But, I want to know whether there are some other ways than that  to modify (A) to (B).

If there are any good ways for it, I will be happy if you teach them to me.

Thanks in advance.

 

taro

Hello people in mapleprimes,

 

I tried to solve y=x^3 for x, expecting of getting a result of x^(1/3),

through using restart;assume(x::real,y::real);
b:=y=x^3;
solve(b,x);

But, the result was:

Warning, solve may be ignoring assumptions on the input variables.
             (1/3)    1  (1/3)   1    (1/2)  (1/3)  
            y     , - - y      + - I 3      y     ,
                      2          2                  

                1  (1/3)   1    (1/2)  (1/3)
              - - y      - - I 3      y     
                2          2                

.

It means that solve couldn't use the assumption of x and y being real.

On the other hand, reading RealDomain package, y^(1/3) is returned properly:

 

with(RealDomain):
solve(b,x);
                              (1/3)
                             y     

What I want to ask you is

Aren't there ways other than using the RealDomain package, to obtain the solution of y^(1/3)?

 

I will be very glad if you give me answers.

 

Best wishes.

taro

Hello people in mapleprimes

In the help of parse, there is the following example.

I could not understand why the first one is 4, and next 4^2, and the last 4^3 appeared, there.

Please tell me the way n is increased with the output taking 4, 4^2 and 4^3 sequentially in this example.

n := 0;
                             n := 0
input := "a := 4; a^2; a^3;";
                  input := "a := 4; a^2; a^3;"
parse(input,'lastread'='n','offset'=n,statement);
                               4
parse(input,'lastread'='n','offset'=n,statement);
                               16
parse(input,'lastread'='n','offset'=n,statement);
                               64

I know that it is written in the help that lastread shows the next unparsed character,

with the offset the next statement.

Thanks in advance

taro

Hello people in mapleprimes,

 

I cannot obtain a proper result from the following code.

a:=int(((beta/beta[1,2])^(-theta/(1-theta))-kappa[1]^(-theta/(1-theta)))*m*beta^(m-1),beta=0 .. kappa[1]*beta[1,2]);

 

Please tell me if you know how to have maple calculate it.

 

Thanks in advance.

 

taro

First 8 9 10 11 12 13 14 Last Page 10 of 19