Skip to main content

python基础物理计算库

Project description

nbphy

python基础物理库,可以做一些基础的物理计算

快速开始

import nbphy
F = nbphy.force(100, "N") #力100N
s = nbphy.displacement(5, "m") #距离5m
W = F*s #500
print(W)

模块介绍

core核心模块

  • displacement距离 forcework
  • time时间 lever杠杆 velocity速度
  • density密度 pressure压强 tabular表格绘制函数

nbphy.const常量模块

  • g重力加速度 c光速
  • pi圆周率 density_of_water水的密度

示例代码

import nbphy
field = ["钩码质量(g)", "弹簧测力计示数(N)"]
row = [
    [50, 0.5],
    [100, 1],
    [150, 1.5],
    [200, 2]
]
print(nbphy.tabular(field, row))
data = [3.40, 3.45, 3.47]
print(nbphy.average(data))

许可证

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

nbphy-0.1.0.tar.gz (3.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

nbphy-0.1.0-py3-none-any.whl (3.6 kB view details)

Uploaded Python 3

File details

Details for the file nbphy-0.1.0.tar.gz.

File metadata

  • Download URL: nbphy-0.1.0.tar.gz
  • Upload date:
  • Size: 3.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.7

File hashes

Hashes for nbphy-0.1.0.tar.gz
Algorithm Hash digest
SHA256 090528e660d09366170c090036e1846c37dc6a77321c933f2060966ad3964b8e
MD5 915f90f80b43105202e3bb9642065aed
BLAKE2b-256 ae5eced91c1ea1d7f4c0e5e7cde619a4a249948ac84c338be4c77d0fe232dd62

See more details on using hashes here.

File details

Details for the file nbphy-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: nbphy-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 3.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.7

File hashes

Hashes for nbphy-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 e08a4247c192f65029d218d409e15a3f6a97f1639b9e21d6db527b211c4498a7
MD5 390b7d08c0a12efb023dfdc9b5f96e39
BLAKE2b-256 f9075750dcd5ce03a393530182d32f6ee6ad409f729bcecbb27482f270850bb5

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page