mirror of
https://github.com/NGSolve/netgen.git
synced 2024-12-26 05:50:32 +05:00
modified spline projection
This commit is contained in:
parent
6c44a273ce
commit
0eaedadf10
@ -197,11 +197,25 @@ namespace netgen
|
|||||||
{
|
{
|
||||||
double t_old = -1;
|
double t_old = -1;
|
||||||
|
|
||||||
|
/*
|
||||||
if(proj_latest_t > 0. && proj_latest_t < 1.)
|
if(proj_latest_t > 0. && proj_latest_t < 1.)
|
||||||
t = proj_latest_t;
|
t = proj_latest_t;
|
||||||
else
|
else
|
||||||
t = 0.5;
|
t = 0.5;
|
||||||
|
*/
|
||||||
|
double tmin = 1;
|
||||||
|
double dist_min2 = Dist2 (GetPoint(tmin), point);
|
||||||
|
for (double ti = 0; ti < 0.99; ti += 0.25)
|
||||||
|
{
|
||||||
|
double di = Dist2(GetPoint(ti), point);
|
||||||
|
if (di < dist_min2)
|
||||||
|
{
|
||||||
|
tmin = ti;
|
||||||
|
dist_min2 = di;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
t = tmin;
|
||||||
|
|
||||||
Point<D> phi;
|
Point<D> phi;
|
||||||
Vec<D> phip,phipp,phimp;
|
Vec<D> phip,phipp,phimp;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user