First things first. It is important to note that you don't have to
start over with each t.
This is because exp(A(t+s))v = exp(As)*exp(At)v. So if you already
have w(t) = exp(At)v, then getting the delta in w(t+s) = exp(As)w(t)
is faster than starting over.
I received a similar query a while back - the request was to take an
input t as a vector t = [t1, ..., tk], and compute w = [w1, ..., wk] =
[exp(t1*A)*v, ..., exp(tk*A)*v]. I have attached thet script
multi_expv that I made for that in Malab. That might give you a clue
if you want to exploit the history between runs a little more -- the
intermediate data points are overwritten in your case. But already
getting the delta per my comment above with the DMEXPV code as-is
should be good enough to get you going.
> So I'm wondering if parameter "m" ( the size for the Krylov basis )
> can play a significant role in the time calculation and in this case
> if there is an efficient method to reduce his value without loosing
> too much accuracy ?
Accuracy is always enforced no matter the m. There is an m that should
give the best trade-off in speed, but it is not going to be a
constant. Try what I mentioned above with m=10 or m=15 to see if yout
get a boost.
> Another problem, related to the first one, append when the size of the
> markov matrix "n" is of order 10^5.
> In this case the value of "lwsp" (the size of the workspace) is of
> order n*m and so can go over 2^31 -1 that is the maximum value for an
> array (the workspace). So I have to choose m << n and that why I
> wonder once again if there is an efficient method to choose "m"?
You could try m=10, or 15. Or perhaps a latest workstation (with a
bigger RAM and faster swap) if you are dealing with much harder
problems. We have run larger problems than yours with sizes in the
order of 10^6 on workstations. But the biggest improvement in your
case will likely come from exploiting the separability per my coment
above.
---
RBS
>
> best regards,
> Anton
> >
>