Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
pykat
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Sebastian Steinlechner
pykat
Commits
a0cc00b5
Commit
a0cc00b5
authored
10 years ago
by
Andreas Freise
Browse files
Options
Downloads
Patches
Plain Diff
converting some optics functions from Simtools
parent
9ce10105
No related branches found
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
pykat/optics/FabryPerot.py
+39
-0
39 additions, 0 deletions
pykat/optics/FabryPerot.py
pykat/optics/__init__.py
+0
-0
0 additions, 0 deletions
pykat/optics/__init__.py
with
39 additions
and
0 deletions
pykat/optics/FabryPerot.py
0 → 100644
+
39
−
0
View file @
a0cc00b5
# ------------------------------------------------------
# Moving some utility function from Simtools
# http://www.gwoptics.org/simtools/
# to PyKat. Work in progress, currently these
# functions are not tested.
#
# Andreas 30.11.2014
# ------------------------------------------------------
from
__future__
import
absolute_import
from
__future__
import
division
from
__future__
import
print_function
from
__future__
import
unicode_literals
import
numpy
as
np
def
cavity_info
(
Lambda
,
L
,
Rc1
,
Rc2
):
g1
=
1
-
L
/
Rc1
g2
=
1
-
L
/
Rc2
G
=
g1
*
g2
G1
=
(
g1
+
g2
-
2
*
G
)
k
=
2.0
*
np
.
pi
/
Lambda
zr
=
np
.
sqrt
(
L
**
2
*
G
*
(
1.0
-
G
)
/
G1
**
2
)
z1
=
L
*
g2
*
(
1
-
g1
)
/
G1
z2
=
L
*
g1
*
(
1
-
g2
)
/
G1
w0
=
L
*
Lambda
/
np
.
pi
*
np
.
sqrt
(
G
*
(
1
-
G
)
/
G1
**
2
)
w1
=
np
.
sqrt
(
L
*
Lambda
/
np
.
pi
*
np
.
sqrt
(
g2
/
(
g1
*
(
1
-
G
))
))
w2
=
np
.
sqrt
(
L
*
Lambda
/
np
.
pi
*
np
.
sqrt
(
g1
/
(
g2
*
(
1
-
G
))
))
return
[
zr
,
w0
,
z1
,
w1
,
w2
]
def
cavity_w1w2_Rc1Rc2
(
Lambda
,
L
,
w1
,
w2
):
C
=
(
Lambda
*
L
/
np
.
pi
)
**
2
g1
=
-
1.0
*
np
.
sqrt
(
1
-
C
/
(
w1
*
w2
)
**
2
)
*
(
w2
/
w1
)
g2
=
-
1.0
*
np
.
sqrt
(
1
-
C
/
(
w1
*
w2
)
**
2
)
*
(
w1
/
w2
)
Rc1
=
L
/
(
1
-
g1
)
Rc2
=
L
/
(
1
-
g2
)
return
[
g1
,
g2
,
Rc1
,
Rc2
]
This diff is collapsed.
Click to expand it.
pykat/optics/__init__.py
0 → 100644
+
0
−
0
View file @
a0cc00b5
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment