Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Sebastian Steinlechner
pykat
Commits
3416fca0
Commit
3416fca0
authored
Apr 20, 2015
by
Daniel Brown
Browse files
adding in overlap function from Paul between two beam parameters
parent
8a1ff3f6
Changes
1
Hide whitespace changes
Inline
Side-by-side
pykat/optics/gaussian_beams.py
View file @
3416fca0
...
...
@@ -175,9 +175,25 @@ class gauss_param(object):
return
q
.
real
*
(
1
+
(
q
.
imag
/
q
.
real
)
**
2
)
@
staticmethod
def
overlap
(
q1
,
q2
):
"""
Computes the projection from one beam parameter to another to give a measure of the
overlap between the two beam parameters.
This function was provided by Paul Fulda and Antonio Perreca, which came originally
from Chris Mueller.
Added on 20/4/2015
"""
return
abs
(
4
*
q1
.
imag
*
q2
.
imag
)
/
abs
(
q1
.
conjugate
()
-
q2
)
**
2
def
conjugate
(
self
):
return
beam_param
(
self
.
__lambda
,
self
.
__nr
,
self
.
__q
.
conjugate
())
def
__abs__
(
self
):
return
abs
(
complex
(
self
.
__q
))
def
__complex__
(
self
):
return
self
.
__q
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment