legume.Ellipse

class legume.Ellipse(eps=1.0, x_cent=0.0, y_cent=0.0, rx=0.0, ry=0, phi=0)

Ellipse shape

__init__(eps=1.0, x_cent=0.0, y_cent=0.0, rx=0.0, ry=0, phi=0)

Create an ellipse shape

Note

If rx = ry the ellipse is equivalent to a Circle with radius r = rx = ry. For rx > ry the ellipse is elongated in the x direction.

Parameters:
  • eps (float) – Permittivity value

  • x_cent (float) – x-coordinate of ellipse center

  • y_cent (float) – y-coordinate of ellipse center

  • rx (float) – x-axis length

  • ry (float) – y-axis length

  • phi (float) – rotation of the ellipse

Methods

__init__([eps, x_cent, y_cent, rx, ry, phi])

Create an ellipse shape

compute_ft(gvec)

Compute Fourier transform of a 2D shape function

is_inside(x, y)

Elementwise indicator function for the shape