## Using dsolve events to avoid singularities in rung...

Hey there,

I'm trying to numerically intergrate a function s(K,i,j) dK using runge kutta over a 2D grid of i,j values. Essentialy, performing the same sort of integral many different times for slightly different combinations of i and j. The function is more or less gaussian, and so the bulk of the result will come from the values of K around the peak of said gaussian. For some combinations of i and j, the function seems to have a singularity on the right edge of the gaussian peak, which causes my script to spit out an error, telling me the calculation cannot be performed further to the right past the singularity. Now, like i said before, the singularity is on the very edge of the gaussian and therefore I am perfectly happy to stop the integration before the singularity, because anything past it wont contribute very much to the result.

How can I use dsolve events to halt my integration just before hitting the singularity?

`RK := (i, j) -> dsolve({diff(n(K), K) = K*s(K, a[i], b[j]), n(0) = 0}, numeric, method = rkf45)`

## harmless assumptions changes the form of the final...

trying some examples from 209970-Exact-Solutions-For-PDE-And-Boundary--Initial-Conditions-2018

I noticed some answer change when adding assumptions which should not really cause the answer to change. Numerically, both answers seem to be the same. But one is series solution and the other with assumptions added uses integrals.

In wave pde on string where left end at x=0 and adding assumptions x>0,t>0 to pdsolve should produce the same form and it does on some problems but no on others.

Compare

```#example 19, wave pde, on string left end fixed, right end moving, with source, no initial velocity
restart;
pde := diff(u(x, t), t\$2) = 4*diff(u(x, t), x\$2)+(1+t)*x;
bc := u(0,t)=0,u(Pi,t)=sin(t);
ic := u(x,0)=0,eval(diff(u(x,t),t),t=0)=0;

sol:=pdsolve([pde, bc,ic],u(x,t));  #1
sol:=pdsolve([pde, bc,ic],u(x,t)) assuming t>0; #2
sol:=pdsolve([pde, bc,ic],u(x,t)) assuming x>0; #3
sol:=pdsolve([pde, bc,ic],u(x,t)) assuming t>0,x>0;  #4
```

(1,2,3) above give same answer which is

but (4) gives

Tried random points and numerically they are the same (set the sum to n=100 to evaluate).

my question is why would adding no assuming, or adding t>0 on its own or adding x>0 on its own give same answer, but adding  t>0,x>0 at same time give such a different looking soution.

I typically adding such assumptions to be safe, but here it seems to had some side effect I have not noticed before.

```Physics:-Version();

10:41 hours, version in the MapleCloud: 265, version installed in this computer: not installed

kernelopts(version)
Maple 2018.2, X86 64 WINDOWS, Nov 16 2018, Build ID 1362973
```

## Can't solve ODE...

I try to solve ODE with conditions, but it give answer only without conditions:

SOT.mw

Thank you.

## Finite Volume Method...

Is there any facility to apply Finite Volume Method to Partial idifferential equation on MAPLE?
Any comand?

Any Code?

## Modify secant and tangent...

Modify the procedure that implements the secant and tangent routines in such a way that instead of the number of iterations in the beginning give the given accuracy E, with which the approximation is to be determined.

As a result, the procedure should return the last approximation along with the iteration number.

===

===

I need help.

## How to install MapleToolbox2018.0LinuxX64?...

Hello,

I try to install MapleToolbox2018.0LinuxX64Installer.run I run it as root or with sudo command, but everytime I finish with below message:

Choose Maple 2018 Folder

[/opt/maple2018]:  /opt/exp_soft/local/generic/maple/2018

----------------------------------------------------------------------------
Choose MATLAB Folder

[]: /opt/exp_soft/local/generic/matlab/R2016b

Warning: The installer has detected a previous version of the Maple Toolbox in
Press [Enter] to continue:
Warning: The directory
/opt/exp_soft/local/generic/matlab/R2016b
is not writable by the current user

I'm not sure what to do with it.

---
Regards,

Bartek

## Re-indexing A vector...

I have a vector A. I want to re-index vector A.

After re-indexing it, I will use the elements of the vector in new calculations.

For example:

```k:=2:
M:=3:
A:=Vector[column]([seq(seq(p*q,q=0..M-1),p=1..2^(k-1))]);
C:=Vector[column]([seq(seq(c(p,q),q=0..M-1),p=1..2^(k-1))]);
Equate(C,A);
c(1,0)+c(2,1);```

c(1,0)+c(2,1)=2.

But the above code doesn' t work.

## condition on applyrule while reading in a list...

I have two list in which I need to substitute variables from on elist with variables in other list in an expression.

rootElements := [[a, Integer, c, Integer, -k*a, b], [Integer, c, a, Integer, b, -k*a], [Integer, a, b, -k*a, c, Integer], [Integer, a, Integer, c, -k*a, b]];

list1 := [[a[maximum], 0, c[maximum], 0, (-k*a)[minimum], b[minimum]], [0, c[minimum], a[maximum], 0, b[maximum], (-k*a)[maximum]], [0, a[minimum], b[maximum], (-k*a)[maximum], c[maximum], 0], [0, a[minimum], 0, c[minimum], (-k*a)[minimum], b[minimum]]]

let the term be

term :=a*c/(k*a+b);

Terms := seq(applyrule([seq(rootElements[i][j] = list1[i][j], j = 1 .. nops(list1[i]))], term), i = 1 .. nops(list1));

my outputs  are

a[maximum]*c[maximum]/(k*a[maximum]+b[minimum]),# k*a should be minimum, becuae I substituted a earlier it is failing
a[maximum]*c[minimum]/(k*a[maximum]+b[maximum]),
a[minimum]*c[maximum]/(k*a[minimum]+b[maximum]),# k*a should be maximum, becuae I substituted a earlier it is failing
a[minimum]*c[minimum]/(k*a[minimum]+b[minimum]);

is there a way to substitute larger terms first[like -k*a first] and goes to smaller variable??

I am using applyrule since algsubs cannot do for more than one substitution.Also, I would be glad if any other alternative is provided.
thank you

## how to automate control maple ?...

```>>> maple = pywinauto.application.Application().start(r'C:\Program Files\Maple 2015\bin.win\maplew.exe')
C:\Users\mas\AppData\Local\Programs\Python\Python36-32\lib\site-packages\pywinauto\application.py:1044: RuntimeWarning: Application is not loaded correctly (WaitForInputIdle failed)
warnings.warn('Application is not loaded correctly (WaitForInputIdle failed)', RuntimeWarning)
>>> maple.Maple.PrintControlIdentifiers()
__main__:1: DeprecationWarning: Method .PrintControlIdentifiers() is deprecated, use .print_control_identifiers() instead.
Traceback (most recent call last):
File "C:\Users\mas\AppData\Local\Programs\Python\Python36-32\lib\site-packages\pywinauto\application.py", line 246, in __resolve_control
criteria)
File "C:\Users\mas\AppData\Local\Programs\Python\Python36-32\lib\site-packages\pywinauto\timings.py", line 453, in wait_until_passes
raise err
pywinauto.timings.TimeoutError

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "C:\Users\mas\AppData\Local\Programs\Python\Python36-32\lib\site-packages\pywinauto\__init__.py", line 50, in wrap
return method(*args, **kwargs)
File "C:\Users\mas\AppData\Local\Programs\Python\Python36-32\lib\site-packages\pywinauto\application.py", line 585, in print_control_identifiers
this_ctrl = self.__resolve_control(self.criteria)[-1]
File "C:\Users\mas\AppData\Local\Programs\Python\Python36-32\lib\site-packages\pywinauto\application.py", line 249, in __resolve_control
raise e.original_exception
File "C:\Users\mas\AppData\Local\Programs\Python\Python36-32\lib\site-packages\pywinauto\timings.py", line 431, in wait_until_passes
func_val = func(*args, **kwargs)
File "C:\Users\mas\AppData\Local\Programs\Python\Python36-32\lib\site-packages\pywinauto\application.py", line 191, in __get_ctrl
dialog = self.backend.generic_wrapper_class(findwindows.find_element(**criteria[0]))
File "C:\Users\mas\AppData\Local\Programs\Python\Python36-32\lib\site-packages\pywinauto\findwindows.py", line 84, in find_element
elements = find_elements(**kwargs)
File "C:\Users\mas\AppData\Local\Programs\Python\Python36-32\lib\site-packages\pywinauto\findwindows.py", line 303, in find_elements
elements = findbestmatch.find_best_control_matches(best_match, wrapped_elems)
File "C:\Users\mas\AppData\Local\Programs\Python\Python36-32\lib\site-packages\pywinauto\findbestmatch.py", line 533, in find_best_control_matches
raise MatchError(items = name_control_map.keys(), tofind = search_text)
pywinauto.findbestmatch.MatchError: Could not find 'Maple' in 'dict_keys([])'
>>> maple.Maple.print_control_identifiers()
Traceback (most recent call last):
File "C:\Users\mas\AppData\Local\Programs\Python\Python36-32\lib\site-packages\pywinauto\application.py", line 246, in __resolve_control
criteria)
File "C:\Users\mas\AppData\Local\Programs\Python\Python36-32\lib\site-packages\pywinauto\timings.py", line 453, in wait_until_passes
raise err
pywinauto.timings.TimeoutError

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "C:\Users\mas\AppData\Local\Programs\Python\Python36-32\lib\site-packages\pywinauto\application.py", line 585, in print_control_identifiers
this_ctrl = self.__resolve_control(self.criteria)[-1]
File "C:\Users\mas\AppData\Local\Programs\Python\Python36-32\lib\site-packages\pywinauto\application.py", line 249, in __resolve_control
raise e.original_exception
File "C:\Users\mas\AppData\Local\Programs\Python\Python36-32\lib\site-packages\pywinauto\timings.py", line 431, in wait_until_passes
func_val = func(*args, **kwargs)
File "C:\Users\mas\AppData\Local\Programs\Python\Python36-32\lib\site-packages\pywinauto\application.py", line 191, in __get_ctrl
dialog = self.backend.generic_wrapper_class(findwindows.find_element(**criteria[0]))
File "C:\Users\mas\AppData\Local\Programs\Python\Python36-32\lib\site-packages\pywinauto\findwindows.py", line 84, in find_element
elements = find_elements(**kwargs)
File "C:\Users\mas\AppData\Local\Programs\Python\Python36-32\lib\site-packages\pywinauto\findwindows.py", line 303, in find_elements
elements = findbestmatch.find_best_control_matches(best_match, wrapped_elems)
File "C:\Users\mas\AppData\Local\Programs\Python\Python36-32\lib\site-packages\pywinauto\findbestmatch.py", line 533, in find_best_control_matches
raise MatchError(items = name_control_map.keys(), tofind = search_text)
pywinauto.findbestmatch.MatchError: Could not find 'Maple' in 'dict_keys([])'
>>>```

## How to make numerical result...

I've made calculation as array := function(array1,array2). Then summ of all array[i] all in one cycle. If I look in summ variable I see fu(0+fu() +.. agebraical representation. I tried evalf(summ). still algebraical. How to derive numerically?

## parametric algebraic equation involving more than ...

Hi

I want to solve quadratic eqution involving more than 2 parameters...want to analize unique soltuions and real roots also want to plot the real and unique region on graphs ....thanx

the equation is -delta*(Q*S*alpha*b-a*alpha^2+M*c+b*delta) where alpha is the varible and rest are paramters

 >
 >
 (1)
 >
 (2)
 >
 >
 (3)
 >
 (4)
 >
 >
 (5)
 >
 (6)
 >
 (7)
 >
 (8)
 >
 (9)
 >
 >

## maple take long time...

why i can not evaluate 29 polynomial. maple try to evaluate last 7hr, how many time required too solve it?

## How to change the numbers shown in the diagram sha...

How to change the numbers shown in the diagram shapes from y=0.5- to rigth form y=-0.5a.mw