Skip to content
Snippets Groups Projects
Commit 1ad90e45 authored by Christophe Geuzaine's avatar Christophe Geuzaine
Browse files

*** empty log message ***

parent 441490f4
No related branches found
No related tags found
No related merge requests found
......@@ -348,7 +348,9 @@ int MergeFile(std::string fileName, bool warnIfMissing)
if(status > 1) status = PView::readMSH(fileName);
#endif
if(CTX::instance()->mesh.order > 1)
SetOrderN(GModel::current(), CTX::instance()->mesh.order, false, false);
SetOrderN(GModel::current(), CTX::instance()->mesh.order,
CTX::instance()->mesh.secondOrderLinear,
CTX::instance()->mesh.secondOrderIncomplete);
}
#if !defined(HAVE_NO_POST)
else if(!strncmp(header, "$PostFormat", 11) ||
......
......@@ -5,7 +5,6 @@
#include <sstream>
#include <algorithm>
#include <limits>
#include "GmshConfig.h"
#include "GmshDefines.h"
......@@ -199,22 +198,19 @@ GPoint GEdge::closestPoint(const SPoint3 & q,double& t) const
Range<double> interval = parBounds(0);
double tMin = std::min(interval.high(),interval.low());
double tMax = std::max(interval.high(),interval.low());
double tMin = std::min(interval.high(), interval.low());
double tMax = std::max(interval.high(), interval.low());
double relax = 1.;
double dt,dt0,t0;
double dt, dt0, t0;
int nb = 10;
t = (tMin + tMax) * 0.5;
while (relax > 0.1) {
int i = 0;
t = 0.5 * (tMin + tMax);
dt0 = tMax - tMin;
dt = dt0;
t = 0.5 * (tMin + tMax);
dt0 = tMax - tMin;
dt = dt0;
while (dt > tolerance * dt0 && i++ < nb) {
t0 = t;
dt0 = dt;
......
......@@ -67,9 +67,10 @@ class GEdge : public GEntity {
virtual bool containsParam(double pt) const;
// get the position for the given parameter location
virtual SVector3 position(double p) const {
virtual SVector3 position(double p) const
{
GPoint gp = point(p);
return SVector3(gp.x(),gp.y(),gp.z());
return SVector3(gp.x(), gp.y(), gp.z());
}
// get first derivative of edge at the given parameter
......@@ -130,7 +131,8 @@ class GEdge : public GEntity {
virtual bool periodic(int dim) const { return v0 == v1; }
// true if edge is used in hyperbolic layer on face gf
virtual bool inHyperbolicLayer(GFace* gf) {
virtual bool inHyperbolicLayer(GFace* gf)
{
return bl_faces.find(gf) != bl_faces.end();
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment