Code Monkey home page Code Monkey logo

picbench's Introduction

PiCbench

release v0.1.0 Semantic Versioning license GNU GPLv3 Mathematica 9.0 10.0

Tools for making Particle in Cell simulations in Mathematica. The package features C code compilation to produce fast simulations.

Features

1D1V plasma simulation with periodic boundaries with no magnetic fields are only implemented at the moment.

Usage example

Check the example notebook or the example script to see how it works.

Note that a C compiler have to be set in Mathematica for these to work. In case you have installed a C compiler it is sometimes automatically detected by Mathematica, but sometimes it is not. Check out the reference.

You may still use the package without a C compiler. Replace CompilationTarget -> "C" by CompilationTarget -> "WMV"to try the demos.

Installation

Automatic installation

To install the PiCbench package evaluate:

Get["https://raw.githubusercontent.com/dih5/PiCbench/master/BootstrapInstall.m"]

This method uses MathematicaBootstrapInstaller and will also install the ProjectInstaller package if you don't have it already installed.

To load the PiCbench package evaluate: Needs["PiCbench`"].

Manual installation

  1. Download latest released PiCbench.zip file.

  2. Extract downloaded PiCbench.zip to any directory which is on the Mathematica $Path, e.g. to install for the current user FileNameJoin[{$UserBaseDirectory,"Applications"}], for all users FileNameJoin[{$BaseDirectory,"Applications"}].

  3. To load the package evaluate: Needs["PiCbench`"].

No installation

To use package directly from the Web, without installation, evaluate:

Get["https://raw.githubusercontent.com/dih5/PiCbench/master/PiCbench/" <> # <> ".m"] & /@ {"Parameters", "Initialization", "Plot", "Compile", "Particle2Grid", "Maxwell", "Mover", "PiCbench"}

Note that with this method of initialization package documentation will not be available in Mathematica Documentation Center.

Documentation

This application comes with documentation integrated with the Mathematica Documentation Center. After installation search for "PiCbench" in documentation center or press F1 key with cursor on name of any of symbols introduced by this application.

Compatibility

The package has been tested with Mathematica 9.0 and 10.X on Windows and Linux. It will probably work in Mathematica 6.0+, but it has not been tested. If you do so, please let me know.

License

This package is released under the GNU GPLv3 license.

Versioning

Releases of this package will be numbered using Semantic Versioning guidelines.

Acknowledgements

The PiC notebook from the Berkley Plasma Simulation Group found here served as a motivation to try PiC simulations in Mathematica and also served as a model for the first implementation of some of the algorithms.

picbench's People

Contributors

dih5 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

Forkers

njisrawi geant44

picbench's Issues

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.