예제 #1
0
    def _XYZ(self, uv):
        # https://math.stackexchange.com/questions/461547/whats-the-equation-of-helix-surface
        theta, t = uv

        f = self.curve._f
        N = self.curve._N
        B = self.curve._B
        r = self.radius

        XYZ = jnp.array(
            f(t)) + r * N(t) * jnp.cos(theta) + r * B(t) * jnp.sin(theta)

        return XYZ
예제 #2
0
 def _X(self, uv):
     return jnp.cosh(uv[1]) * jnp.cos(uv[0])
예제 #3
0
 def _Y(self, uv):
     return (self.a + (self.b * jnp.cos(uv[1]))) * jnp.sin(uv[0])
예제 #4
0
 def _Y(self, uv):
     return (self.R + self.r * jnp.cos(uv[1])) * jnp.sin(uv[0])
예제 #5
0
 def _Z(self, uv):
     u, v = uv
     return self.c * jnp.cos(v)
예제 #6
0
 def _X(self, uv):
     u, v = uv
     return self.a * jnp.cos(u) * jnp.sin(v)
예제 #7
0
 def _Z(self, uv):
     w, B = uv
     a, b, c = self.abc
     top = (a**2 * jnp.sin(w)**2) + (b**2 * jnp.cos(w)**2) - c**2
     return c * jnp.sin(B) * (jnp.sqrt(top) / jnp.sqrt(a**2 - c**2))
예제 #8
0
 def _Y(self, uv):
     w, B = uv
     a, b, c = self.abc
     return b * jnp.cos(B) * jnp.sin(w)
예제 #9
0
 def _X(self, uv):
     w, B = uv
     a, b, c = self.abc
     top = a**2 - (b**2 * jnp.sin(B)**2) - (c**2 * jnp.cos(B)**2)
     return a * jnp.cos(w) * (jnp.sqrt(top) / jnp.sqrt(a**2 - c**2))
예제 #10
0
 def _Z(self, uv):
     return self.r * jnp.cos(uv[1])
예제 #11
0
 def _X(self, uv):
     return self.r * jnp.cos(uv[0]) * jnp.sin(uv[1])
예제 #12
0
 def polar2cart(self, rt):
     r, theta = rt
     return [r * jnp.cos(theta), r * jnp.sin(theta)]
예제 #13
0
 def _X(self, uv):
     u, v = uv
     return self.curve._x(v) * jnp.cos(u)
예제 #14
0
 def _Y(self, t):
     return jnp.cos(t) - 2 * jnp.cos(2 * t)
예제 #15
0
 def _y(self, t):
     return self.a * (jnp.cos(t) + jnp.log(jnp.tan(t / 2.0)))
예제 #16
0
 def _Y(self, t):
     return self.R * jnp.cos(t)