Skip to content
Snippets Groups Projects
Commit ddd99a63 authored by mathias.chouet's avatar mathias.chouet
Browse files

Merge branch 'exemple-simplification' into update-dependencies

parents d396ab26 a092bc6d
No related branches found
No related tags found
1 merge request!30Resolve "Mettre à jour proprement vers Angular 7"
/**
* Stores app preferences
* @TODO save in cookie / localStorage ?
*/
export class ApplicationSetupService {
private _displayPrecision: number;
private _computePrecision: number;
private _newtonMaxIter: number;
constructor() {
this.defaults();
}
public defaults() {
this._displayPrecision = 0.001;
this._computePrecision = 0.0001;
this._newtonMaxIter = 50;
}
public get displayPrecision() {
return this._displayPrecision;
}
public set displayPrecision(p: number) {
this._displayPrecision = p;
}
public displayPrecision = 0.001;
public computePrecision = 0.0001;
public newtonMaxIter = 50;
public get displayDigits() {
return -Math.log10(this._displayPrecision);
}
public get computePrecision() {
return this._computePrecision;
}
public set computePrecision(p: number) {
this._computePrecision = p;
}
public get newtonMaxIter() {
return this._newtonMaxIter;
}
public set newtonMaxIter(p: number) {
this._newtonMaxIter = p;
return -Math.log10(this.displayPrecision);
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment