GithubHelp home page GithubHelp logo

notebook's Introduction

projective

import math import numpy as np R1=18.384 R2=13.560 + 0.2 x3 = 16.544 x2 = 12.157 y3 = 2.2046 y2 = 10.022

x3_0 = 16.544 x2_0 = 12.157 y3_0 = 2.2046 y2_0 = 10.022 a_R1 = ((x3_0-x2_0)(x3_0-x2_0)+(y2_0-y3_0)(y2_0-y3_0))**0.5 theta00= math.asin(0.5*a_R1/R2)*2 print(theta00)

delta = 0.150

for theta in np.linspace(theta00, theta00+ 0.2, 10): print('#######') x22 = np.linspace(12.157 - 1, 12.157, 10) theta0 = (math.pi-theta)*0.5 a_R1 = math.cos(theta0)R22 for x2 in x22: t0 = math.acos(x2/R1) x3 = x2+math.cos(math.pi - theta0 - t0)*a_R1 O2A = (R1-R2)*x2/R1 P4O2 = R2**2/(x3 - O2A) P4A = P4O2 + O2A x4 = (math.sin(t0 - theta)*R2 - delta)math.tan(t0 - theta) + x3 O1A = math.sin(t0)(R1-R2) y1 = R1 - O1A - delta y2 = math.sin(t0)*R1 - O1A -delta y3 = math.sin(t0 - theta)*R2 -delta

s1 = math.pi*R1**2*(math.asin(x2/R1)/math.pi) - O2A*O1A
s2 = math.pi*R2**2*theta/(2*math.pi)*2
s3 = P4O2 * math.sin(t0 - theta)*R2
s = s1 + s2 + s3

print('t0: %g '%t0, 'theta: %g '%theta, 'x2: %g '%x2, 'x3: %g '%x3, 'x4: %g '%x4, 'y1: %g '%y1, 'y2: %g '%y2, 'y3: %g '%y3, 's: %g '%s)

notebook's People

Contributors

kxuehen avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.