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
Snippets
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
Sean Leavey
pykat
Commits
51d0dbcd
Commit
51d0dbcd
authored
8 years ago
by
Daniel Brown
Browse files
Options
Downloads
Patches
Plain Diff
adding setRTL method for BS and mirror, fixing db plotting with out.plot
parent
3c94b18d
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/components.py
+6
-1
6 additions, 1 deletion
pykat/components.py
pykat/finesse.py
+12
-2
12 additions, 2 deletions
pykat/finesse.py
with
18 additions
and
3 deletions
pykat/components.py
+
6
−
1
View file @
51d0dbcd
...
@@ -335,6 +335,11 @@ class AbstractMirrorComponent(Component):
...
@@ -335,6 +335,11 @@ class AbstractMirrorComponent(Component):
self
.
_default_fsig_param
=
self
.
__phi
self
.
_default_fsig_param
=
self
.
__phi
def
setRTL
(
self
,
R
=
None
,
T
=
None
,
L
=
None
):
if
R
is
not
None
:
self
.
R
.
value
=
R
if
T
is
not
None
:
self
.
T
.
value
=
T
if
L
is
not
None
:
self
.
L
.
value
=
L
@property
@property
def
z
(
self
):
return
self
.
__z
def
z
(
self
):
return
self
.
__z
@property
@property
...
...
This diff is collapsed.
Click to expand it.
pykat/finesse.py
+
12
−
2
View file @
51d0dbcd
...
@@ -331,6 +331,8 @@ class katRun(object):
...
@@ -331,6 +331,8 @@ class katRun(object):
if
kat
.
noxaxis
==
True
:
if
kat
.
noxaxis
==
True
:
raise
pkex
.
BasePyKatException
(
"
This kat object has noxaxis=True, so there is nothing to plot.
"
)
raise
pkex
.
BasePyKatException
(
"
This kat object has noxaxis=True, so there is nothing to plot.
"
)
original_yaxis
=
kat
.
yaxis
if
yaxis
is
not
None
:
if
yaxis
is
not
None
:
kat
.
yaxis
=
yaxis
kat
.
yaxis
=
yaxis
...
@@ -367,7 +369,11 @@ class katRun(object):
...
@@ -367,7 +369,11 @@ class katRun(object):
dual_plot
=
True
dual_plot
=
True
elif
"
db:deg
"
in
kat
.
yaxis
:
elif
"
db:deg
"
in
kat
.
yaxis
:
if
"
db
"
not
in
original_yaxis
:
_func1
=
lambda
x
:
10
*
np
.
log10
(
x
)
_func1
=
lambda
x
:
10
*
np
.
log10
(
x
)
else
:
_func1
=
lambda
x
:
x
_func2
=
lambda
x
:
np
.
rad2deg
(
np
.
angle
(
x
))
_func2
=
lambda
x
:
np
.
rad2deg
(
np
.
angle
(
x
))
plot_cmd1
=
plot_cmd
plot_cmd1
=
plot_cmd
...
@@ -379,7 +385,11 @@ class katRun(object):
...
@@ -379,7 +385,11 @@ class katRun(object):
_func1
=
np
.
real
_func1
=
np
.
real
plot_cmd1
=
plot_cmd
plot_cmd1
=
plot_cmd
elif
"
db
"
in
kat
.
yaxis
:
elif
"
db
"
in
kat
.
yaxis
:
if
"
db
"
not
in
original_yaxis
:
_func1
=
lambda
x
:
10
*
np
.
log10
(
x
)
_func1
=
lambda
x
:
10
*
np
.
log10
(
x
)
else
:
_func1
=
lambda
x
:
x
plot_cmd1
=
plot_cmd
plot_cmd1
=
plot_cmd
elif
"
deg
"
in
kat
.
yaxis
:
elif
"
deg
"
in
kat
.
yaxis
:
_func1
=
lambda
x
:
np
.
rad2deg
(
np
.
angle
(
x
))
_func1
=
lambda
x
:
np
.
rad2deg
(
np
.
angle
(
x
))
...
...
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