Skip to content

Latest commit

 

History

History
210 lines (155 loc) · 4.43 KB

README.md

File metadata and controls

210 lines (155 loc) · 4.43 KB

Computer Aided Geometric Design

WindowsCodacy Badge

Introduction

MATH6110P: Computer Aided Geometric Design (Autumn-Winter 2021-2022)

Instructors: Renjie Chen

Webpage: http://staff.ustc.edu.cn/~renjiec/Courses/CAGD_2021S1/default.htm

Build

  • Visual Studio 2019
  • CMake >= 3.14
git clone https://github.com/Chaphlagical/CAGD --recursive

Configure, Generate, and run Homework

Assignments

Homework#1: Data Interpolation

$$ \begin{pmatrix} \varphi_1(x_1) & \varphi_2(x_1) & \cdots & \varphi_n(x_1)\\\ \varphi_1(x_2) & \varphi_2(x_2) & \cdots & \varphi_n(x_2)\\\ \vdots & \vdots & \ddots & \vdots\\\ \varphi_1(x_n) & \varphi_2(x_n) & \cdots & \varphi_n(x_n) \end{pmatrix} \begin{pmatrix} \alpha_1\\\alpha_2\\\vdots\\\alpha_n \end{pmatrix}= \begin{pmatrix} y_1\\y_2\\\vdots\\y_n \end{pmatrix}\notag $$

Homework#2: Bézier Curve(De Casteljau Algorithm)

$$ \begin{aligned} \begin{matrix} \pmb b^0_i(t)=\pmb b_i,&i=0,\cdots,n \end{matrix}\\\ \pmb b_i^r(t)=(1-t)\pmb b_i^{r-1}(t)+t\pmb b_{i+1}^{r-1}(t)\\\ \begin{matrix} r=1,\cdots,n&i=0,\cdots,n-r \end{matrix} \end{aligned} $$

Homework#3: Bézier Curve(Bernstein Basis)

$$ \begin{align} \pmb f(t)&=\sum_{i=0}^nB_i^{(n)}(t)\pmb p_i\\\ &=\sum_{i=0}^n\left(\begin{matrix}n\\i\end{matrix} \right)t^i(1-t)^{n-i}\pmb p_i \end{align}\notag $$

Homework#4: Curve Differential Geometry

Frenet Frame $$ \begin{aligned} e_1(t)&=\frac{c'(t)}{|c'(t)|}\ e_2(t)&=c''(t)-(c''(t),e_1)\cdot e_1\notag \end{aligned} $$ Curvature $$ \kappa(t)=\frac{|c'(t)\times c''(t)|}{|c'(t)|^3}\notag $$ Involute $$ \eta(t)=c(t)+\frac{1}{\kappa(t)}e_2(t)\notag $$ Curvature Circle $$ c(t)=\eta(t)+(\cos t/\kappa, \sin t/\kappa) $$ 4

Homework#5: Bézier Spline

  • Interpolation: $\pmb b_{3i}=\pmb k_i$

  • $C^1$ Continuity: $$ \dfrac{\pmb b_n^--\pmb b_{n-1}^-}{t_j-t_{j-1}}=\dfrac{\pmb b_1^+-\pmb b_0^+}{t_{j+1}-t_j} $$

  • $C^2$ Continuity: $$ \dfrac{\pmb b_n^--2\pmb b_{n-1}^-+\pmb b_{n-2}^-}{(t_j-t_{j-1})^2}=\dfrac{\pmb b_2^+-2\pmb b_1^++\pmb b_0^+}{(t_{j+1}-t_j)^2} $$

  • End Condition:

    • Natural
    • Bessel
    • Close
  • Parameterization

    • Uniform
    • Chordal
    • Centripetal

4

Homework#6: B Spline

  • Given

    • $n+1$ control points: $\pmb k_0,\cdots,\pmb k_n$
    • Knot sequence $s_0,\cdots,s_n$
  • B spline basis: $$ \begin{aligned} N_i^1(t)&=\begin{cases} 1,&t_i\leq t<t_{i+1}\\ 0,&\mathrm{otherwise} \end{cases}\\ N_{i,k}(t)&=\dfrac{t-t_i}{t_{i+k-1}-t_i}N_{i,k-1}(t)+\dfrac{t_{i+k}-t}{t_{i+k}-t_{i+1}}N_{i+1,k-1}(t)\notag \end{aligned} $$

  • B spline: $$ \pmb x(t)=\sum_{i=0}^nN_{i,k}(t)\cdot \pmb d_i $$

  • Support:

    • $C^2$ continuity points
    • Line points
    • Sharp points

Homework#7: Polar Form & Blossoming

$$ f(t_1,\cdots,t_n)=\sum_{i=0}^nc_i\begin{pmatrix}n\\ i\end{pmatrix}^{-1}\sum_{S\subseteq {1,\cdots,n},|S|=i}\prod_{j\in S}t_j $$

Homework#8: Rational Spline Curves

$$ \pmb f(t)=\sum_{i=0}^n R_{i,n}(t)\pmb p_i $$

with: $$ R_{i,n}(t)=\frac{B_{n,i}(t)w_i}{\sum_{j=0}^nB_{n,j}(t)w_j} $$

Homework#9: Spline Surfaces

$$ \pmb f(u,v)=\frac{\sum_{i=0}^d\sum_{j=0}^dB_i^{(d)}(u)B_j^{(d)}(v)\omega_{i,j}\pmb p_{i,j}}{\sum_{i=0}^d\sum_{j=0}^dB_i^{(d)}(u)B_j^{(d)}(v)\omega_{i,j}} $$

Homework#10: Loop Subdivision

  • Update old vertices $$ O_{new}=\frac{1}{8}(C+D)+\frac{3}{8}(A+B) $$

  • Update new vertices $$ \tilde O=(1-nu)O+u\sum_{i=1}^nv_i $$

    • n: vertex degree
    • u: $3/16$ if $n=3$, $3/(8n)$ otherwise

Homework#11: Tutte/Floater Parameterization

$$ v_i-\sum_{j\in\pmb N(i)}\lambda_{ij}v_j=0,\ i=0,1,\cdots,n $$

Homework#12: RBF Mesh Deformation

$$ \pmb f(\pmb x)=\sum_j\pmb w_j\varphi(|\pmb c_j-\pmb x|)+\pmb p(\pmb x) $$