Optics Workbench

Have some feature requests, feedback, cool stuff to share, or want to know where FreeCAD is going? This is the place.
Forum rules
Be nice to others! Read the FreeCAD code of conduct!
drmacro
Veteran
Posts: 8862
Joined: Sun Mar 02, 2014 4:35 pm

Re: Optics Workbench

Post by drmacro »

Boogieman wrote: Sun Aug 29, 2021 4:40 pm Ah, yes. This happens when you choose a non existing Material, which happened because now there are fewer Materials. And by luck/accident you saved a lens with one of theses materials.
Would be sufficient to just change the material.
Thanks for the tip!
Star Trek II: The Wrath of Khan: Spock: "...His pattern indicates two-dimensional thinking."
drmacro
Veteran
Posts: 8862
Joined: Sun Mar 02, 2014 4:35 pm

Re: Optics Workbench

Post by drmacro »

I get this if I attempt to add a Beam:

Code: Select all

11:15:27  Running the Python command 'Beam' failed:
Traceback (most recent call last):
  File "/home/mac/.FreeCAD/Mod/OpticsWorkbench/Ray.py", line 417, in Activated
    doCommand('import OpticsWorkbench')

name 'doCommand' is not defined
OS: Debian GNU/Linux 10 (buster) (XFCE/lightdm-xsession)
Word size of FreeCAD: 64-bit
Version: 0.20.25645 (Git)
Build type: Release
Branch: master
Hash: 37d9757399b4c2ec30318eb88d7cd7c508246345
Python version: 3.7.3
Qt version: 5.11.3
Coin version: 4.0.0a
OCC version: 7.3.0
Locale: English/UnitedStates (en_US)
Star Trek II: The Wrath of Khan: Spock: "...His pattern indicates two-dimensional thinking."
User avatar
Boogieman
Posts: 34
Joined: Wed Apr 18, 2018 9:03 am

Re: Optics Workbench

Post by Boogieman »

drmacro wrote: Sun Sep 05, 2021 3:19 pm I get this if I attempt to add a Beam:

Code: Select all

11:15:27  Running the Python command 'Beam' failed:
Traceback (most recent call last):
  File "/home/mac/.FreeCAD/Mod/OpticsWorkbench/Ray.py", line 417, in Activated
    doCommand('import OpticsWorkbench')

name 'doCommand' is not defined
Thanks for reporting, will be fixed soon.
https://github.com/chbergmann/OpticsWor ... l/18/files

Btw, i think it is a bit cleaner to report bugs in github (create new issue) and not in the forum which is more for general discussion.
abhaymi2
Posts: 2
Joined: Thu Jul 12, 2018 3:24 pm

Re: Optics Workbench

Post by abhaymi2 »

Started using optics WB recently. I get following message when "(Re)start simulation" is clicked after making some changes to the beam or lense:

name 'isOpticalObject' is not defined.

Then the beam in tree shows error icon.

Please advise.
User avatar
christi
Posts: 203
Joined: Wed Oct 24, 2018 7:03 am
Location: Karlsruhe, Germany
Contact:

Re: Optics Workbench

Post by christi »

abhaymi2 wrote: Sun Oct 17, 2021 5:14 pm Started using optics WB recently. I get following message when "(Re)start simulation" is clicked after making some changes to the beam or lense:

name 'isOpticalObject' is not defined.

Then the beam in tree shows error icon.

Please advise.
Please update the workbench. These issues should have been solved with the version from 9.9.2021
Cobras62
Posts: 14
Joined: Thu Oct 28, 2021 9:37 am

Re: Optics Workbench

Post by Cobras62 »

Hello,
Congratulations on this simple and functional workbench. Great job! I discovered it yesterday and I am amazed!
But I have a small question:
For one of my applications, I need to be able to move two mirrors independently or simultaneously. Both mirrors have their own mounts, themselves on a larger common mount. To do this, I placed the two mirrors in the same part (same icon as body but in yellow) and I use the part placement options to rotate the whole.
But it doesn't work: if I change the rotation of each mirror independently, the optical path is well changed, but if I move the whole (with part placement), the optical path remains the same.
I don't know if you understand ..
Do you have any idea how to do it?
Thank you so much.
Sorry for my bad english, I'm french^^
Pierre
User avatar
christi
Posts: 203
Joined: Wed Oct 24, 2018 7:03 am
Location: Karlsruhe, Germany
Contact:

Re: Optics Workbench

Post by christi »

Hi Pierre,
You cannot move the mirror item itself, only the parts inside the mirror. You can bundle the two mirrors in a Compound object (Part workbench -> Compound -> make compound), and then move the compound.
Cobras62
Posts: 14
Joined: Thu Oct 28, 2021 9:37 am

Re: Optics Workbench

Post by Cobras62 »

Hi Christi,
Thanks for the tip!
I did a quick test and it seems to work. I will try on the project I am working on.
Thank you very much and once again, great job!
Pierre
Cobras62
Posts: 14
Joined: Thu Oct 28, 2021 9:37 am

Re: Optics Workbench

Post by Cobras62 »

Hi,
Here are the results in pictures of what I wanted to do.
I had the authorization to show the visuals, because it will be the subject of a scientific publication.
This is a Chernin-type multi-pass cell, installed inside an atmospheric simulation chamber that we have where I work.
Thanks to the round trips of the laser, we increase the length of the optical path (and therefore virtually the length of the simulation chamber), to increase the interaction between the light and the gases that we inject into the chamber and that we want to analyze. .
Here I modeled some molecules of N2O and O3 that we used to validate and test the correct functioning of the manipulation.
I won't go into details, but this manipulation was carried out and was a world first by injecting a teraherzt laser beam with a multi-pass cell into an atmospheric simulation chamber.
Here, thanks to the Optics workshop, I was able to recreate the optical path with a 6x5 matrix. The simulation chamber is about 5m in length, so we have an optical path of about 300m. On the global view, on the left we see two red rays, the top one is the entrance, the laser source, and the bottom one, the exit, where the detectors are placed.
Thank you for your workbench.
Pierre
Attachments
Charme_Chernin_FB1.jpg
Charme_Chernin_FB1.jpg (118.51 KiB) Viewed 3731 times
Charme_Chernin_FB2.jpg
Charme_Chernin_FB2.jpg (148.67 KiB) Viewed 3731 times
Charme_Chernin_FB3.jpg
Charme_Chernin_FB3.jpg (128.55 KiB) Viewed 3731 times
User avatar
christi
Posts: 203
Joined: Wed Oct 24, 2018 7:03 am
Location: Karlsruhe, Germany
Contact:

Re: Optics Workbench

Post by christi »

Wow !
Post Reply