From e571f94b54c899e211c86343edf9444b15d13ee5 Mon Sep 17 00:00:00 2001 From: Dtouch Date: Wed, 7 Dec 2022 18:41:14 +0800 Subject: [PATCH] adjust the .gitignore, README --- .gitignore | 4 ++-- README.md | 29 ++++++++++++++--------------- 2 files changed, 16 insertions(+), 17 deletions(-) diff --git a/.gitignore b/.gitignore index 3d4e6a2..8617437 100644 --- a/.gitignore +++ b/.gitignore @@ -32,5 +32,5 @@ *.out *.app -./cmake-build-debug/ -./.idea/ \ No newline at end of file +cmake-build-debug/ +.idea/ \ No newline at end of file diff --git a/README.md b/README.md index 9a56bb9..a1a4bb4 100644 --- a/README.md +++ b/README.md @@ -7,22 +7,21 @@ Judgment of C2 or C4 intersection of NURBS curve. ## 使用 ```C++ - C2C4 c2C4; - // 按tinynurbs的使用方式配置好左右公有成员的NURBS曲面srf1、srf2的各项属性 - c2C4.srf1.degree_u = 2; - ... - c2C4.srf2.degree_u = 2; +C2C4 c2C4; +// 按tinynurbs的使用方式配置好左右公有成员的NURBS曲面srf1、srf2的各项属性 +c2C4.srf1.degree_u = 2; +... +c2C4.srf2.degree_u = 2; +... + +// 检查是否配置成功 +if (!surfaceIsValid(c2C4.srf1) || !surfaceIsValid(c2C4.srf2)) { + // 曲面相关参数配置有误 ... - - // 检查是否配置成功 - if (!surfaceIsValid(c2C4.srf1) || !surfaceIsValid(c2C4.srf2)) { - // 曲面相关参数配置有误 - ... - return -1; - } - // 判断C2、C4情形,res.first表示是否为C2,res.second表示为C4 - pair res = c2C4.c2OrC4(); - + return -1; +} +// 判断C2、C4情形,res.first表示是否为C2,res.second表示为C4 +pair res = c2C4.c2OrC4(); ``` + C2情形:3*4的雅可比矩阵:存在一个2阶子式行列式非0+所有3阶子式行列式含0。 + C4情形:3*4的雅可比矩阵:去掉某一列后不含0(四个有一个即可)(也就是说存在一个3阶子式的行列式不含0)。若为C4,公有成员变量c4ExcludeCols中记录着去掉哪些列后子式行列式不含0 \ No newline at end of file