Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Backward compatibility of pg.interpolate #131

Closed
florian-wagner opened this issue Feb 2, 2018 · 0 comments
Closed

Backward compatibility of pg.interpolate #131

florian-wagner opened this issue Feb 2, 2018 · 0 comments
Assignees
Milestone

Comments

@florian-wagner
Copy link
Member

Before pg.interpolate was a high-level Python function, the following worked for a 2D mesh:

# interpolate potential to surface
x = np.linspace(emesh.xmin(), emesh.xmax(), 100)
pot_surface = pg.interpolate(emesh, pot, x=x, y=np.ones_like(x) * height)

now the z argument has to be given explicitly:

# interpolate potential to surface
x = np.linspace(emesh.xmin(), emesh.xmax(), 100)
pot_surface = pg.interpolate(emesh, pot, x=x, y=np.ones_like(x) * height, z=np.zeros_like(x))
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants