Skip to content

How to define a temporal PDE library with multiple trajectories? #323

Answered by znicolaou
itsjacobhere asked this question in Q&A
Discussion options

You must be logged in to vote

Hi there @itsjacobhere. Enabling differing (spatio)temporal grids for different trajectories is on our list of features to implement (#222), so unfortunately, it isn't possible yet. I've been wanting to do this for a while, and it isn't that hard, but it will require a lot of small changes that will need to be validated.

Instead, the best current solution is to interpolate the trajectories onto a common temporal grid. If you have data x1 and x2 on grids t1=np.arange(0, T1, dt1) and t2=np.arange(0,T2,dt2), then maybe define t=np.arange(0,np.min(T1,T2),np.min(dt1,dt2)) and use scipy.interpolate.interp1d to produce x1_interp=interp1d(x1,t) and x2_interp=interp1d(x2,t), then model.fit([x1_int…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@itsjacobhere
Comment options

Answer selected by itsjacobhere
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants