0.2.15 • Published 3 years ago

mathrry v0.2.15

Weekly downloads
47
License
GPL-3.0
Repository
github
Last release
3 years ago

mathrry

Issues Stars Forks Downloads License

Simple Math Module

Usage

Basic arithmetic operations

Addition: mathrry.add
Subtraction: mathrry.sub
Multiplication: mathrry.multi
Division: mathrry.divi

Extra

mathrry.revdivi
mathrry.revmulti

mathrry.revdivi is calculated by inverting the value. Think of it as the opposite of mathrry.divi.

mathrry.revmulti also same as above.

2D

Coordinate things

Points

The Distance between two points

mathrry.Dbtp(x1,y1,x2,y2)

x1, x1 are the coordinates of the first point, x2, y2 are the coordinates of the second point.

The Distance between point and line

mathrry.Dbptl(x,y,exp-a,exp-b,exp-c)

x,y are the coordinates of the point, exp-a, exp-b exp-c are from ax+by+c=0. Put it in order.

Triangle

Centroid of Triangle

mathrry.CoT(x1,y1,x2,y2,x3,y3)
Extra
mathrry.CoTx(x1,y1,x2,y2,x3,y3)
mathrry.CoTy(x1,y1,x2,y2,x3,y3)

mathrry.CoTx returns the x-coordinate value of the centroid of triangle.
mathrry.CoTy returns the y-coordinate value of the centroid of triangle.

x1, y1 are the coordinates of the first point, x2, y2 are the coordinates of the second point, and x3, y3 are the coordinates of the third point.

Area things

Triangle

The Area of triangle with 3 points

mathrry.Aotw3p(x1,y1,x2,y2,x3,y3)

x1, y1 are the coordinates of the first point, x2, y2 are the coordinates of the second point, and x3, y3 are the coordinates of the third point.

The Area of triangle with 3 line segments

mathrry.Aotw3ls(l1, l2, l3)

l1, l2, and l3 are the lengths of the sides of the triangle, respectively.

Circle

Area of Circle

mathrry.AoC(r)

r is the radius of the circle for which you want to know the area.

3D

Coordinate things

Points

The Distance between two points in 3D

mathrry.TDbtp(x1,y1,z1,x2,y2,z2)

x1, x1, z1 are the coordinates of the first point, x2, y2, z2 are the coordinates of the second point.

Cube

The Diagonal of the cube

mathrry.TdoC(l)

l is the length of one side of the cube.

Volume of Cube

mathrry.TVoC(l)

l is the length of one side of the cube.

Sphere

Volume of Sphere

mathrry.TVoS(r)

r is the radius of Sphere.

Physics

Force

F = ma

mathrry.F(m,a)

m is the mass of an object. a is the Acceleration of an object.

Extra

m = F/a
mathrry.Fm(f,a)

Finding the mass of an object by force and acceleration.

a = F/m
mathrry.Fa(f,m)

Finding the acceleration of an object by force and mass.

S = V0t + 1/2at^2

mathrry.S(v,a,t)

v is the initial velocity of an object. t is the time of the force was applied to the object. a is the Acceleration of an object.

Extra

V0 = (S - 1/2at^2)/t
mathrry.Sv(s,a,t)

s is the moving space of the object. a is the Acceleration of an object. t is the time of the force was applied to the object.

a = (s - v0t)/(0.5t^2)
mathrry.Sa(s,v,t)

s is the moving space of the object. v is the initial velocity of an object. t is the time of the force was applied to the object.

2as = v^2 - v0^2

mathrry.A(v0,v,s)

v0 is the initial velocity of an object. v is the later speed of the object. s is the moving space of the object.

0.2.15

3 years ago

0.2.14

3 years ago

0.2.13

3 years ago

0.2.12

3 years ago

0.2.11

3 years ago

0.2.10

3 years ago

0.2.9

3 years ago

0.2.8

3 years ago

0.2.7

3 years ago

0.2.6

3 years ago

0.2.5

3 years ago

0.2.3

3 years ago

0.2.4

3 years ago

0.2.2

3 years ago

0.2.1

3 years ago

0.2.0

3 years ago

0.1.9

3 years ago

0.1.8

3 years ago

0.1.7

3 years ago

0.1.6

3 years ago

0.1.4

3 years ago

0.1.5

3 years ago

0.1.3

3 years ago

0.1.2

3 years ago

0.1.1

3 years ago

0.1.0

3 years ago

0.0.9

3 years ago

0.0.8

3 years ago

0.0.7

3 years ago

0.0.6

3 years ago

0.0.5

3 years ago

0.0.3

3 years ago

0.0.4

3 years ago

0.0.2

3 years ago

0.0.1

3 years ago