Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Frida
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
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
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
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Coenen, Joachim
Frida
Commits
3f5ab60a
Commit
3f5ab60a
authored
15 years ago
by
Wuttke, Joachim
Browse files
Options
Downloads
Patches
Plain Diff
try to keep out-of-range points away from dualplot
parent
cd7665e1
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
pub/src/dualplot.cpp
+4
-9
4 additions, 9 deletions
pub/src/dualplot.cpp
pub/src/edif.cpp
+14
-0
14 additions, 0 deletions
pub/src/edif.cpp
with
18 additions
and
9 deletions
pub/src/dualplot.cpp
+
4
−
9
View file @
3f5ab60a
...
...
@@ -398,11 +398,9 @@ void CPlot::plotScan( const bool as_line, const int style_no,
uint
nout
=
0
;
for
(
uint
i
=
0
;
i
<
np
;
i
++
){
if
(
xp
[
i
]
<
X
.
inf
||
xp
[
i
]
>
X
.
sup
)
continue
;
// throw "Plot::Line: x["+strg(i)+"]="+strg(xp[i])+" out of range";
throw
"Plot::Line: x["
+
strg
(
i
)
+
"]="
+
strg
(
xp
[
i
])
+
" out of range"
;
if
(
yp
[
i
]
<
Y
.
inf
||
yp
[
i
]
>
Y
.
sup
)
continue
;
// throw "Plot::Line: y["+strg(i)+"]="+strg(yp[i])+" out of range";
throw
"Plot::Line: y["
+
strg
(
i
)
+
"]="
+
strg
(
yp
[
i
])
+
" out of range"
;
fprintf
(
gp_fd
,
"%16.8g %16.8g
\n
"
,
xp
[
i
],
yp
[
i
]);
nout
++
;
}
...
...
@@ -434,14 +432,11 @@ void CPlot::plotScan( const bool as_line, const int style_no,
else
snprintf
(
outlin
,
CPLOT_LINSIZ
,
"%2d pstyle"
,
style_no
+
1
);
ps_accu
.
push_back
(
outlin
);
snprintf
(
outlin
,
CPLOT_LINSIZ
-
2
,
" %% (%s -> %s)"
,
xco
.
c_str
(),
yco
.
c_str
()
);
snprintf
(
outlin
,
CPLOT_LINSIZ
-
2
,
" %% (%s -> %s)"
,
xco
.
c_str
(),
yco
.
c_str
()
);
strncat
(
outlin
,
"
\n
"
,
CPLOT_LINSIZ
);
ps_accu
.
push_back
(
outlin
);
for
(
uint
i
=
0
;
i
<
np
;
i
++
)
{
if
(
xp
[
i
]
<
X
.
inf
||
xp
[
i
]
>
X
.
sup
)
continue
;
if
(
yp
[
i
]
<
Y
.
inf
||
yp
[
i
]
>
Y
.
sup
)
continue
;
snprintf
(
outlin
,
CPLOT_LINSIZ
,
"%7.3f%7.3f%7.3f t%c %% %14.7g wx %14.7g wy
\n
"
,
X
.
pc
(
xp
[
i
]),
Y
.
pc
(
yp
[
i
]),
0.0
,
...
...
This diff is collapsed.
Click to expand it.
pub/src/edif.cpp
+
14
−
0
View file @
3f5ab60a
...
...
@@ -1147,6 +1147,7 @@ void NEdif::Plot( CPlot *plot, bool add )
e
->
P
()
->
xco
.
str
(),
e
->
P
()
->
yco
.
str
(),
"data file "
+
strg
(
k
)
+
" scan "
+
strg
(
j
)
);
}
/*
} else if ( fc && false ) {
// keep old vectorial version;
// might be useful for accelerated plotting
...
...
@@ -1158,6 +1159,7 @@ void NEdif::Plot( CPlot *plot, bool add )
plot->plotScan( true, cstyle++, xp, yp, e->Z(j),
e->P()->xco.str(), e->P()->yco.str(),
"curve file "+strg(k)+" scan "+strg(j) );
*/
}
else
if
(
fc
&&
fc
->
kconv
!=-
1
)
{
// plot only at x points of convolutand
uint
kconv
=
fc
->
kconv
;
...
...
@@ -1172,6 +1174,18 @@ void NEdif::Plot( CPlot *plot, bool add )
xp
.
push_back
(
x
);
}
fc
->
T
->
tree_curve_val_vec
(
&
yp
,
xp
,
k
,
j
);
vector
<
double
>
xo
,
yo
;
for
(
size_t
i
=
0
;
i
<
xp
.
size
();
++
i
){
if
(
plot
->
X
.
contained
(
xp
[
i
]
)
&&
plot
->
Y
.
contained
(
yp
[
i
]
)
)
continue
;
xo
.
push_back
(
xp
[
i
]
);
yo
.
push_back
(
yp
[
i
]
);
}
if
(
xp
.
size
()
==
0
){
cout
<<
"curve k="
<<
strg
(
k
)
<<
", j="
<<
strg
(
j
)
<<
" is empty
\n
"
;
return
;
}
plot
->
plotScan
(
true
,
cstyle
++
,
xp
,
yp
,
e
->
Z
(
j
),
e
->
P
()
->
xco
.
str
(),
e
->
P
()
->
yco
.
str
(),
"curve file "
+
strg
(
k
)
+
" scan "
+
strg
(
j
)
);
...
...
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