-
Notifications
You must be signed in to change notification settings - Fork 0
/
SolvedSystemDialog.h
55 lines (46 loc) · 1.15 KB
/
SolvedSystemDialog.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
#ifndef SOLVEDSYSTEMDIALOG_H
#define SOLVEDSYSTEMDIALOG_H
#include <QWidget>
#include <QLineEdit>
#include <QHBoxLayout>
#include <QLabel>
#include <QDoubleValidator>
#include <QMessageBox>
#include <math.h>
#include "GaussJordano.h"
namespace Ui {
class SolvedSystemDialog;
}
class SolvedSystemDialog : public QWidget
{
Q_OBJECT
public:
explicit SolvedSystemDialog(QWidget *parent = 0);
~SolvedSystemDialog();
static double _round(double n);
void showHint();
private:
Ui::SolvedSystemDialog *ui;
quint8 m_row;
quint8 m_col;
QVector< QVector<QLineEdit*>* > m_wArray;
QVector<QHBoxLayout*> m_layouts;
QDoubleValidator *m_doubleValidator;
double **m_solvedArray;
//methods
void freeMemory();
void allocateMemory();
void placeWidgets();
bool check();
public slots:
void setCondition(double *genExprArray, double** varArray, double *constArray, quint8 row, quint8 col);
signals:
void next();
void back();
void result(double **array, quint8 row);
void userError();
private slots:
void on_backButton_clicked();
void on_nextButton_clicked();
};
#endif // SOLVEDSYSTEMDIALOG_H