chiark / gitweb /
helixish: wip
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Wed, 22 Nov 2017 00:46:42 +0000 (00:46 +0000)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Wed, 22 Nov 2017 00:46:42 +0000 (00:46 +0000)
Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
helixish.py

index 541bb79ec5777a58df1c78bac0a6e233f883ae72..549452f9588349be68e17e4639c3013674a0a77e 100644 (file)
@@ -97,7 +97,25 @@ class HelixishCurve():
     start_kappa = 0
     start_gamma = 1
 
+    tilt = atan(mu)
+    tilt_basis = np.array([
+      1,     0,           0,         0,
+      0,   cos(tilt), -sin(tilt),    0,
+      0,   sin(tilt),  cos(tilt),    0,
+      0,     0,           0,         1,
+    ])
+    findcurve_basis = dPQplane_basis * tilt_basis
+    findcurve_into = np.linalg.inv(findcurve_basis)
+
+    q_findcurve = unaugment(findcurve_into, augment(q))
+    dq_findcurve = unaugment(findcurve_into, augment0(dq))
+
+    findcurve_target = np.concatenate(q_findcurve, dq_findcurve)
+    findcurve_start = (sqrt(start_s), sqrt(start_t), start_la,
+                       start_mu, start_gamma, start_kappa)
     
+    
+                                                  
 
     # we work in two additional coordinate systems:
     # for both these: