https://github.com/zpreisler/patchy2d
Simulation software for patchy particles in 2d
https://github.com/zpreisler/patchy2d
2d c computer-simulation opengl scientific sdl2 self-assembly
Last synced: 4 months ago
JSON representation
Simulation software for patchy particles in 2d
- Host: GitHub
- URL: https://github.com/zpreisler/patchy2d
- Owner: zpreisler
- License: mit
- Created: 2018-06-05T00:58:49.000Z (about 7 years ago)
- Default Branch: rods
- Last Pushed: 2018-11-14T00:57:20.000Z (over 6 years ago)
- Last Synced: 2025-01-11T08:51:38.953Z (5 months ago)
- Topics: 2d, c, computer-simulation, opengl, scientific, sdl2, self-assembly
- Language: C
- Homepage:
- Size: 15 MB
- Stars: 1
- Watchers: 1
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Patchy 2d
Simulation software to simulate patchy particles in 2d.
------
This is a Monte Carlo code. Number of ensembles are supported: Canonical (*NVT*), Grand-Canonical (mu VT), isothermal-isobaric ensemble (*NpT*).
The code is also able to simulate more complex particles such as rods composed by number of single discs.The code uses Kern-Frenkel interaction potential.
### Prerequisites
opengl, SDL### Installing
First one needs to compile & install *lib*
```
git clone https://github.com/zpreisler/lib.git
make
make install
```Get the source code
```
git clone https://github.com/zpreisler/patchy2d.git
make
make install
```### Examples
From the command line
```
patchy2d -n three_patch -s 10000000 -N 512 --npatch 3 --sigma_well 1.1 --patch_width 7 -g 0 -b 30 30 -e 7 --pmod 100 -m 1000
```
The above will generate 512 3-patch particles with interaction range 0.1 and the patch width 7### Patchy particles
### Rods
__Usage:__ patchy2d
[-n] [--name] {name:} Name
[-s] [--step] {step:} Number of MC steps
[-N] [--specie] {specie:} Species
[--new_sigma] {(null)} Update sigma
[--new_width] {(null)} Update width
[--new_mu] {(null)} Update mu
[--new_angle] {(null)} Update angles
[-b] [--box] {box:} Simulation box lengths x and y
[-c] [--copy] {copy:} Copy the simulation box in x and y direction
[-e] [--epsilon] {epsilon:} epsilon -- interaction strength
[--end_epsilon] {end_epsilon:} end epsilon -- final interaction strength
[-p] [--pressure] {pressure:} pressure
[-l] [--lambda] {lambda:} lambda
[-L] [--lambda_coupling] {lambda_coupling:} lambda coupling
[--uy] {uy:} uy -- box tilt
[--max_move] {maximum_displacement:} Maximum displacement
[--max_rot] {maximum_rotation:} Maximum rotation
[--max_vol] {maximum_volume:} Maximum volume change
[--max_uy] {maximum_shape:} Maximum shape change
[--max_dsigma] {maximum_dsigma:} Maximum dsigma
[-m] [--mod] {mod:} Write modulus
[--pmod] {pmod:} Print modulus
[-o] [--optimize] {optimize:} Step size optimization on/off
[-v] [--verbose] {verbose:} Verbose mode on/off
[--snapshot] {snapshot:} Snapshot mode on/off
[--seed] {seed:} Seed