Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closes #215 , add overloading for addition and multiplication operators in TransverseProfile #216

Merged

Conversation

rob-shalloo
Copy link
Member

@rob-shalloo rob-shalloo commented Dec 11, 2023

I've followed @soerenjalas implementation of overloading in the Profile class and added it directly in the TransverseProfile class. This allows one to create a laser transverse profile from a sum of hermite gaussians without having to first create the full laser object. This makes things cleaner and should hopefully speed up calculations.

This should close #215

@rob-shalloo rob-shalloo added the new feature request or implementation of a new feature label Dec 11, 2023
@rob-shalloo rob-shalloo changed the title Closes #215 , add overloading for addition and multiplication operators in RransverseProfile Closes #215 , add overloading for addition and multiplication operators in TransverseProfile Dec 11, 2023
@soerenjalas
Copy link
Contributor

soerenjalas commented Dec 13, 2023

I think it would make sense to add some basic testing for these function. It would be good to have at least something like this.

@rob-shalloo
Copy link
Member Author

Hey @soerenjalas , thanks for the great suggestion. I've added the tests now, again shamelessly copying your code... but seems to work ;)

Copy link
Contributor

@MaxThevenet MaxThevenet left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great, thanks for this PR!

@MaxThevenet MaxThevenet merged commit dd26ee8 into LASY-org:development Feb 5, 2024
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
new feature request or implementation of a new feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Overloading Addition and Multiplication Operators of TransverseProfile
3 participants