Package: optcom
Optcom: Open Source Optical System SimulatorWhat is Optcom ?Optcom is a Python library which aims to simulate optical systems.
Optcom has been build for both advanced research and teaching purposes.On one hand, Optcom can be used as an optical system simulation
framework in which users can create their own optical / electric
components and benefit from a wide range of helper functions. On the
other hand, Optcom can be used with the in-build components for
state-of-the art optical system simulation.Moreover, user-friendly experience is at the heart of Optcom approach.
In Optcom, an optical system is built by linking the ports of different
components to each other. Here is a small example of what can be done:importoptcomasoc# Create 2 Gaussian channelspulse=oc.Gaussian(channels=2,center_lambda=[1030.,1550.],peak_power=[0.5,1.0])# Create fiber with a user-defined attenuation coefficientfiber=oc.Fiber(length=1.0,alpha=[0.4],ATT=True,DISP=True,SPM=True,save_all=True)# Create an optical layout and link the first port of 'pulse' to the first port of 'fiber'layout=oc.Layout()layout.add_link(pulse.get_port(0),fiber.get_port(0))layout.run_all()# Extract outputs and plottime=fiber.storage.timepower=oc.temporal_power(fiber.storage.channels)space=fiber.storage.spaceoc.animation2d(time,power,space,x_label='t',y_label='P_t',plot_title='My first Optcom example',line_labels=['1030. nm channel','1550. nm channel'])TutorialsSeetutorials/for basic and advanced tutorials.RequirementsInstallation should be OS independent. Python3.7 or later version is
required. Seehttps://www.python.org/downloads/for more detail about
python installation.As an example, in Ubuntu, Debian or Mint, python 3 can be installed
with:sudoapt-getinstallpython3python3-pipInstallOptcom can be installed using pip with:python3-mpipinstalloptcomOr in order to run the latest version of the code from the git repo:python3-mpipinstallgit+git://github.com/optcom-org/optcom/The required dependencies should have been installed along the pip
installation, if any trouble is encountered, the dependencies can be
manually install by chance of the requirements.txt file with:python3-mpipinstall-rrequirements.txtIssues and QuestionsFor bug report or suggestion, please use the Optcom issue tracker:https://github.com/optcom-org/optcom/issuesTo ask questions about the usage of Optcom, use the Gitter repo:https://gitter.im/optcom-org/optcomFor any matter that does not concern the aforementioned ones, send an
email toinfo@optcom.orgContributingAny contribution is welcome !Optcom provides an optical system simulation framework and is as rich
as the number of components that can be used. You enjoy Optcom and
created your own component to fulfill your simulation need ? Share it
with the community!  Seetutorials/to learn
how to create your own component.Any help in testing, development or documentation is highly appreciated
and can be done from contributors of all experience levels. Please have
a look at theROADMAP.mdto see which tasks are available.For contribution instructions and guidelines, please seeCONTRIBUTING.md.DocumentationFind the built documentation athttps://readthedocs.org/projects/optcom/To manually build the documentation, go indocs/and type:makeclean&&makehtmlRelease History0.1.0 : The first Alpha version of Optcom0.2.0 : Complete refactoring of v0.1.0 and new features0.2.1 : Bug fix of v0.2.00.2.2 : Clear user interface0.3.0 : Change of License + all OS support0.3.1 : New parameters + additional doc0.3.2 : New components + multi-processing for Taylor series0.3.3 : New components + new parameters + 3D plot refactoring0.3.4 : Optical filter update0.3.5 : Noise management in ideal components0.3.6 : New componentsHostingThe source code is hosted athttps://github.com/optcom-org/optcomCitationIf you use Optcom, please cite it as:@misc{Optcom-org-optcom,
  title = {{Optcom}: A Python library for optical system simulation},
  author = "{Sacha Medaer}",
  howpublished = {\url{https://github.com/optcom-org/optcom}},
  url = "https://github.com/optcom-org/optcom",
  year = 2019
}LicenseOptcom is licensed under the terms of the Apache 2.0 License, seeLICENSE.DisclaimerOptcom is a free open source Software developed and maintained by
volunteers. The authors take no responsibility, seeLICENSE.