semvec/pypi-packages huggingface dataset:
symmeplot 0.2.2
SymPy Mechanics Plotter
Requires Python: >=3.10

# SymMePlot

[![PyPI](https://img.shields.io/pypi/v/symmeplot.svg)](https://pypi.org/project/symmeplot/)
[![Tests](https://github.com/tjstienstra/symmeplot/workflows/Tests/badge.svg)](https://github.com/tjstienstra/symmeplot/actions?workflow=Tests)

SymMePlot is a visualization tool designed for mechanical systems created using
the mechanics module in [SymPy], `sympy.physics.mechanics`.

The `sympy.physics.mechanics` module allows users to define mechanical systems
symbolically to derive their analytic equations of motion. During this process,
users can construct various objects such as reference frames, points, bodies,
and more.

SymMePlot enhances this process by providing a way to visualize these
constructed objects. It integrates with visualization backends like
[Matplotlib], and creates visual representations based on the parametrization of
the symbols involved in the system.

SymMePlot is available on both PyPI and Conda-Forge. To install the latest
release including [Matplotlib] from PyPI, run:

```bash
pip install symmeplot matplotlib
```

## Usage

Most of your programs are expected to follow this structure:

1. Creation of the system in sympy using the objects from
   `sympy.physics.mechanics`.
2. Initiate a `Scene` with the inertial frame and absolute origin.
3. Add your frames, vectors and points to the plotter instance.
4. Lambdify and evaluate the system.
5. Plot the system.

Below is a basic example of how this looks in practise:

```python
import numpy as np
from symmeplot.matplotlib import Scene3D
from sympy.physics.mechanics import Point, ReferenceFrame, dynamicsymbols

# Create the system in sympy
N = ReferenceFrame("N")
A = ReferenceFrame("A")
q = dynamicsymbols("q")
A.orient_axis(N, N.z, q)
N0 = Point("N_0")
v = 0.2 * N.x + 0.2 * N.y + 0.7 * N.z
A0 = N0.locatenew("A_0", v)
# Create the instance of the scene specifying the inertial frame and origin
scene = Scene3D(N, N0, scale=0.5)
# Add the objects to the system
scene.add_vector(v)
scene.add_frame(A, A0, ls="--")
scene.add_point(A0, color="g")
# Evaluate the system.
scene.lambdify_system(q)
scene.evaluate_system(0.5)
# Plot the system
scene.plot()

# You can also animate this system.
ani = scene.animate(lambda q: (q,), frames=np.linspace(0, 2 * np.pi, 60))
ani.save("animation.gif", fps=30)
```

![](docs/animation.gif)

[Matplotlib]: https://matplotlib.org/
[SymPy]: https://www.sympy.org
suou 0.12.2
casual utility library for coding QoL
Requires Python: >=3.10

# SIS Unified Object Underarmor

Good morning, my brother! Welcome **SUOU** (**S**IS **U**nified **O**bject **U**nderarmor), the Python library which speeds up and makes it pleasing to develop API, database schemas and stuff in Python.

It provides utilities such as:
* SIQ ([specification](https://yusur.moe/protocols/siq.html) - [copy](https://suou.readthedocs.io/en/latest/iding.html))
* signing and generation of access tokens, on top of [ItsDangerous](https://github.com/pallets/itsdangerous) *not tested and not working*
* helpers for use in Flask, [SQLAlchemy](https://suou.readthedocs.io/en/latest/sqlalchemy.html), and other popular frameworks
* i forgor 💀

**It is not an ORM** nor a replacement of it; it works along existing ORMs (currently only SQLAlchemy is supported lol).

## Installation

**Python 3.10**+ with Pip is required.

```bash
$ pip install sakuragasaki46-suou
```

To install optional dependencies (i.e. `sqlalchemy`) for development use:

```bash
$ pip install sakuragasaki46-suou[sqlalchemy]
```

Please note that you probably already have those dependencies, if you just use the library.

## Features

Read the [documentation](https://suou.readthedocs.io/).

## Support

### Disclaimer

Just a heads up: SUOU was made to support Sakuragasaki46 (me)'s own selfish, egoistic needs. Not certainly to provide a service to the public.

As a consequence, 'add this add that' stuff is best-effort.

Expect breaking changes, disruptive renames in bugfix releases, sudden deprecations, years of unmantainment, or sudden removal of SUOU from GH or pip.

Don't want to depend on my codebase for moral reasons (albeit unrelated)? It's fine. I did not ask you.

**DO NOT ASK TO MAKE SUOU SAFE FOR CHILDREN**. Enjoy having your fingers cut.

### "LTS"

The following versions are supported: the latest, the second-to-latest, 0.12.x and 0.7.x.

## License

Licensed under the [Apache License, Version 2.0](LICENSE), a non-copyleft free and open source license.

This is a hobby project, made available “AS IS”, with __no warranty__ express or implied.

I (sakuragasaki46) may NOT be held accountable for Your use of my code.

> It's pointless to file a lawsuit because you feel damaged, and it's only going to turn against you. What a waste of money you could have spent on a vacation or charity, or invested in stocks.

Happy hacking.