Commit e51b9d57 authored by Dorchies David's avatar Dorchies David
Browse files

Fix #209 Add bounds to the Newton derivative

parent 246eefc5
......@@ -12,7 +12,7 @@ const resultSectCirc: {[name: string]: number} = {
'I-J': -0.00102, Imp: 5076.304, Tau0: 8.505
}
fdescribe("Section paramétrée circulaire ouverte: ", () => {
describe("Section paramétrée circulaire ouverte: ", () => {
beforeEach(() =>{
SessionSettings.precision = precDist;
});
......@@ -70,7 +70,7 @@ fdescribe("Section paramétrée circulaire ouverte: ", () => {
});
});
fdescribe("Section paramétrée circulaire fermée: ", () => {
describe("Section paramétrée circulaire fermée: ", () => {
beforeEach(() =>{
SessionSettings.precision = precDist;
});
......
......@@ -101,7 +101,7 @@ export abstract class acNewton extends Debug {
return rDER;
}
const rDer = rDER.vCalc;
const rDer = Math.max(-1E10, Math.min(rDER.vCalc, 1E10)); // Bornage de la dérivée pour éviter Delta=0
if (rDer !== 0) {
if (XOR(rFn < 0, this.rFnPrec < 0)) {
this.iOscil++;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment