Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/dangom/mr-sequence-diagrams
Draw MR Sequence Diagrams for LaTeX / MetaPost
https://github.com/dangom/mr-sequence-diagrams
latex metapost mri
Last synced: about 1 month ago
JSON representation
Draw MR Sequence Diagrams for LaTeX / MetaPost
- Host: GitHub
- URL: https://github.com/dangom/mr-sequence-diagrams
- Owner: dangom
- Created: 2017-04-03T09:11:04.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2020-07-03T01:58:45.000Z (over 4 years ago)
- Last Synced: 2023-10-05T20:31:22.734Z (about 1 year ago)
- Topics: latex, metapost, mri
- Homepage:
- Size: 128 KB
- Stars: 30
- Watchers: 5
- Forks: 9
- Open Issues: 0
-
Metadata Files:
- Readme: README.org
Awesome Lists containing this project
README
#+TITLE: Pulse Sequence Graphics
#+begin_quote
The files "pulses.mp" and "seq.mp" found in this repository were originally created by Mark J White for his PhD Thesis and were hosted at his website /celos.net/, which unfortunately does not exist anymore. A snapshot is available in the Internet Archive [[http://web.archive.org/web/20160629144038/http://www.celos.net/comp/pulses/][here]], though.
According to his website:
You're free to use, modify or copy the files in any way you like, as long as you credit Mark with copyright and authorship for the bits he wrote, and understand that it comes without any kind of guarantee.
As a further note: Two of the macros found in /pulses.mp/, namely =tablegrf= and =xtablegr= were written by T. A. Wilkinson and can be found in his blog [[https://tinkertailorsoldiersponge.com/blog/2013/12/17/pulse-sequence-diagrams-using-metapost][here]].
#+end_quoteThis repository contains a MetaPost file called /pulses.mp/ which contains a set of macros for easily generating MR Pulse Sequence Diagrams programatically. It also contains a file called /seq.mp/ with examples of how to use the macros.
To generate example images from those files simply run:
#+BEGIN_SRC sh
mpost seq.mp
#+END_SRCFor this to work, MetaPost has to be installed in the system, which should be the case if you have a proper LaTeX distribution. Should ImageMagick also be installed, it is possible to convert images to PNG by calling ~convert -density 300 input.mps output.png~. Alternatively, to include .mps files directly into a LaTeX file you can use the graphicx package and add a =\includegraphics{input.mps}= wherever the figure should be included.
* Examples
** FID Acquisition
#+ATTR_ORG: :width 400
[[./images/figs-0.png]]
** Spin Echo Fragment
#+ATTR_ORG: :width 400
[[./images/figs-1.png]]
** Gradient Echo Fragment
#+ATTR_ORG: :width 400
[[./images/figs-2.png]]
** Slice Selection Fragment
#+ATTR_ORG: :width 400
[[./images/figs-3.png]]
** Readout Encoding Fragment
#+ATTR_ORG: :width 400
[[./images/figs-4.png]]
** Phase Encoding Fragment with Spin Echo
#+ATTR_ORG: :width 400
[[./images/figs-5.png]]
** Multislice SE volume acquisition
#+ATTR_ORG: :width 400
[[./images/figs-6.png]]
** 3D GRE with EPI Factor 3
#+ATTR_ORG: :width 400
[[./images/figs-7.png]]
** Echo Symbol
[[./images/figs-100.png]]