Skip to content

A python module for mode calculations in cylindrical and planar fibers.


Notifications You must be signed in to change notification settings


Repository files navigation


by Scott Prahl

pypi github conda doi

License Testing Docs Downloads

Python code to calculate light propagation through optical fibers following the approach presented in Ghatak and Thyagarajan, An Introduction to Fiber Optics. Far-field fiber calculations are based on Chen, Foundations for Guided-Wave Optics.


Use pip:

pip install ofiber

or conda:

conda install -c conda-forge ofiber


A few examples are shown below. For all examples, see ofiber documentation

Symmetric planar waveguides

Planar Waveguide

Cylindrical fibers with step index profiles

Modes in Step Index Fiber Mode Irradiance Internal Modes

Far-field emission for step index fibers

Far-field Irradiance polar angle of the minimum of the central irradiance lobe

Fiber design

Fiber Design Dispersion

Google Colaboratory

Use a Jupyter notebook immediately by clicking the Google Colaboratory button below



ofiber is licensed under the terms of the MIT license.