Skip to main content

Tools to create FFD operator from point cloud.

Project description

PyFFD

PyFFD is an open-source Free Form Deformation (FFD) library.

Mathematics

We define the FFD opperator as $R_s = \left[ B_i \left( x_j \right) \right]_{(i,j)}$ using B-Spline functions such as:

B(x) = 
    \begin{bmatrix}
        B_1(x) \\
        B_2(x)\\
        \vdots\\
        B_i(x)
    \end{bmatrix}

We can easily project a vector like :

$$ b_s = R_s^T ~ b $$

Code

Quick start

(1) Define a FEM mesh :

n = np.array([[x0, y0], [x1, y1], ...])

(2) Define the elements size and degree for the B-Spline box in each direction :

# Element size per directions
size = [size_x, size_y]
# global setting
size = 0.1 # example

# Element degree per directions
deg = [deg_x, deg_y]
# global setting
deg = 3 # example

(3) Create the B-Spline box python object :

sbox = pf.FFD(n, size, deg)

(4) Compute the FFD opperator $R_s$ :

Rs = sbox.OperatorFFD()

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

PyFFD-0.0.6.tar.gz (8.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

PyFFD-0.0.6-py3-none-any.whl (8.4 kB view details)

Uploaded Python 3

File details

Details for the file PyFFD-0.0.6.tar.gz.

File metadata

  • Download URL: PyFFD-0.0.6.tar.gz
  • Upload date:
  • Size: 8.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.4

File hashes

Hashes for PyFFD-0.0.6.tar.gz
Algorithm Hash digest
SHA256 f4197e2bbe658ba28f9b5242fc944ab173e36b4165a230788937b89f8bccb8cb
MD5 0c1f7ceda3fbc766931f4246f1b27ea4
BLAKE2b-256 08a3047ef7db93d27c412f0ceb6b73cd0b5a3f21db4a175e8d52b194c1024c2e

See more details on using hashes here.

File details

Details for the file PyFFD-0.0.6-py3-none-any.whl.

File metadata

  • Download URL: PyFFD-0.0.6-py3-none-any.whl
  • Upload date:
  • Size: 8.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.4

File hashes

Hashes for PyFFD-0.0.6-py3-none-any.whl
Algorithm Hash digest
SHA256 e5a7dfb6c7c4bee65bc7b27d4ee5db370c2c435319c862cdd7a7040803cfc9f6
MD5 9703a920587fdc75ebf824f72c292ffc
BLAKE2b-256 4dfd807dcec71f9f6307bb8b4c490d0cbe83facdd4e4732493c535af8e0d6a5e

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page