Carl Love

Carl Love

28025 Reputation

25 Badges

12 years, 308 days
Himself
Wayland, Massachusetts, United States
My name was formerly Carl Devore.

MaplePrimes Activity


These are replies submitted by Carl Love

@digerdiga This expression contains I several times and contains no radicals. That is why evalc was my first choice. Note that evalc is a bit different from the other simplifiers in that it automatically assumes as real any variable for which there are no assumptions. 

@Christopher2222 Christopher wrote:

I calculated PowerTower(5) to 15005 digits and it took 200 seconds on my machine.

What do you mean by "to 15005 digits"? Do you mean that you were trying an approximation?

Christopher wrote:

I was trying to manually find the number of digits in PowerTower(5) maybe there's an easier way?

trunc(PowerTower(4)*log10(5.))+1 = 183230

@Christopher2222

Two possibilities:

  1. Your Maple doesn't understand thisproc. Fix: Change it to procname.
  2. Your Maple doesn't understand numtheory:-phi. Fix: Change it to numtheory[phi].

@samiyare Amir, with your permission I'd like to rename this thread to "BVP with constraining integrals" so that it will be easier to find in the future. I'm open to suggestions for a better name.

@samiyare Amir, with your permission I'd like to rename this thread to "BVP with constraining integrals" so that it will be easier to find in the future. I'm open to suggestions for a better name.

@Preben Alsholm Excellent solution, Preben! But how did you choose the weights? Why not put both solutions on the same scale? And did it seem like fsolve cared?

@Preben Alsholm Excellent solution, Preben! But how did you choose the weights? Why not put both solutions on the same scale? And did it seem like fsolve cared?

@erik10

Just guessing here. Try a compiled but non-parallelized version: the one that Acer posted.

@erik10

Just guessing here. Try a compiled but non-parallelized version: the one that Acer posted.

I just uploaded the worksheet for my numeric solution and put it as a Reply to my numeric Answer below. There is a disturbing difference in the plot of V(t). The symbolic solution is more believable: Since L(t) is nearly linear, ode1 implies that V(t) is nearly constant.

I am going to try adjusting error parameters on the numeric solution.

I just uploaded the worksheet for my numeric solution and put it as a Reply to my numeric Answer below. There is a disturbing difference in the plot of V(t). The symbolic solution is more believable: Since L(t) is nearly linear, ode1 implies that V(t) is nearly constant.

I am going to try adjusting error parameters on the numeric solution.

 



restart:

ode1:=diff(L(t),t)*(V(t))=0.682*10^(-7):

ode2:=137*10^6*diff(V(t),t)*V(t)=(1/(4*3.14))*1.66*10^(-10)*L(t)^2*(3.5*10^3-V(t))^2:

ic1:=V(0)=0.01:

ic2:=L(0)=0:

sys:= {ode1,ode2,ic1,ic2}, {V(t),L(t)}, numeric:

Sol:= dsolve(sys):

plots:-odeplot(Sol, [t,L(t)], t= 0..100);

plots:-odeplot(Sol, [t,V(t)], t= 0..100);

The plot for V(t) is not believable. I expect something nearly constant. But if I narrow the range:

plots:-odeplot(Sol, [t,V(t)], t= 0..15);

Ah ha.

 

Try an implict numeric solver.

Sol:= dsolve(sys, method= mebdfi):

plots:-odeplot(Sol, [t,V(t)], t= 0..15);

Sol:= dsolve(sys, method= lsode):

plots:-odeplot(Sol, [t,V(t)], t= 0..15);

Sol:= dsolve(sys, method= rosenbrock, range= 0..15):

plots:-odeplot(Sol, [t,V(t)], t= 0..15);

 



Download moji_numeric.mw

 



restart:

ode1:=diff(L(t),t)*(V(t))=0.682*10^(-7):

ode2:=137*10^6*diff(V(t),t)*V(t)=(1/(4*3.14))*1.66*10^(-10)*L(t)^2*(3.5*10^3-V(t))^2:

ic1:=V(0)=0.01:

ic2:=L(0)=0:

sys:= {ode1,ode2,ic1,ic2}, {V(t),L(t)}, numeric:

Sol:= dsolve(sys):

plots:-odeplot(Sol, [t,L(t)], t= 0..100);

plots:-odeplot(Sol, [t,V(t)], t= 0..100);

The plot for V(t) is not believable. I expect something nearly constant. But if I narrow the range:

plots:-odeplot(Sol, [t,V(t)], t= 0..15);

Ah ha.

 

Try an implict numeric solver.

Sol:= dsolve(sys, method= mebdfi):

plots:-odeplot(Sol, [t,V(t)], t= 0..15);

Sol:= dsolve(sys, method= lsode):

plots:-odeplot(Sol, [t,V(t)], t= 0..15);

Sol:= dsolve(sys, method= rosenbrock, range= 0..15):

plots:-odeplot(Sol, [t,V(t)], t= 0..15);

 



Download moji_numeric.mw

@N00bstyle 

I'm sorry, I led you astray with SUBS (3). The `if` command has very special evaluation rules that I don't fully understand. Consequently, the subs needs to be done twice. Below, I make the "substituter" a local procedure so that the whole subs command does not need to entered twice.

modalmasspedestriansfail:= proc(_h)
local Ev:= x-> subs(height= _h, x);
     Ev(
           `if`(
                 Ev(qpercentagedifference) >= 5/100
,
              modalmasswithpedestrians,
                 modalmasswithoutpedestrians
           )
     )
end proc:

or

modalmasspedestriansfail:= proc(_h)
local Ev:= x-> subs(height= _h, x);
     `if`(
            Ev(qpercentagedifference) >= 5/100
,
          Ev(modalmasswithpedestrians),
            Ev(modalmasswithoutpedestrians)
     )
end proc:

@N00bstyle 

I'm sorry, I led you astray with SUBS (3). The `if` command has very special evaluation rules that I don't fully understand. Consequently, the subs needs to be done twice. Below, I make the "substituter" a local procedure so that the whole subs command does not need to entered twice.

modalmasspedestriansfail:= proc(_h)
local Ev:= x-> subs(height= _h, x);
     Ev(
           `if`(
                 Ev(qpercentagedifference) >= 5/100
,
              modalmasswithpedestrians,
                 modalmasswithoutpedestrians
           )
     )
end proc:

or

modalmasspedestriansfail:= proc(_h)
local Ev:= x-> subs(height= _h, x);
     `if`(
            Ev(qpercentagedifference) >= 5/100
,
          Ev(modalmasswithpedestrians),
            Ev(modalmasswithoutpedestrians)
     )
end proc:

First 641 642 643 644 645 646 647 Last Page 643 of 708