yes, have you tried it? It should work, at least if pos has the right shape
(maybe you need to transpose it).

Otherwise you can also do:

pts = [[x1,x2,...],[y1,y2,...],[z1,z2,...]] # or read pts from a file in
this format
sl_tracked = gf.Slice("points", mesh, pts)
...
u = gf.compute_interpolate_on(mfub, md.variable("ub"), sl_tracked)

This option is faster if the gf.compute_interpolate_on needs to be called
many times.

BR
Kostas

On Wed, Jan 26, 2022 at 10:10 PM Lesage,Anne Cecile J <
ajles...@mdanderson.org> wrote:

> Dear all
>
>
>
> Imagine I read a set of points that are not on my mesh nodes nor on my dof
> nodes
>
>
>
>    file  = open("pos.txt","r")
>
>    pos = np.loadtxt(file,dtype=float)
>
>
>
> how do I interpolate my displacement results on them?
>
>
>
> Something like
>
> tracked_u = gf.compute_interpolate_on(mfub, md.variable("ub"), pos)?
>
>
>
> thank you
>
> regards
>
> Anne-Cecile
> The information contained in this e-mail message may be privileged,
> confidential, and/or protected from disclosure. This e-mail message may
> contain protected health information (PHI); dissemination of PHI should
> comply with applicable federal and state laws. If you are not the intended
> recipient, or an authorized representative of the intended recipient, any
> further review, disclosure, use, dissemination, distribution, or copying of
> this message or any attachment (or the information contained therein) is
> strictly prohibited. If you think that you have received this e-mail
> message in error, please notify the sender by return e-mail and delete all
> references to it and its contents from your systems.
>

Reply via email to