, , , , , . , .

 

 

!

 

:

:

 

 

 

?

 


:


- " "

:

: . : 01.06.2012. : 2011. : 36. antiplagiat.ru: < 30%

():














1.
1.1
N . : N, , . N=10 .

1.2
,
(1)

. i- , . , ai1. i- . t1 = . .
(2)

, ,
(3)
. , , , .
, ( ) .
.(4)
.
1.3.
1.3.1.
:
;
;
.
:
;
;
:
;
1.3.2.
, :
;
;
;
t1;
;
;
4 6 (3);
(4) ( );
;
.
1.3.3.
: Microsoft Windows XP
:
- Intel Pentium/Celeron, AMD Athlon/Duron/Semprion 1 ;
- 256 Ӡ. 64 ;
- VGA;
- .






2.

2.1.

, - . , - C++.
. (. 1).



1-
:
1. , . 2. .
3. . 4. .
5. .


.
:
1. , 2. include ( ).
4. include ( )
5. .


.
:
1. ,
2.
3. .


.

2.2.
: CAboutDlg, CfilereadApp, CfilereadDlg. , :
CfilereadDlg:
ReadFile() . .
OnBnClickedOk() - . .
OnBnClickedButton1() .
OnBnClickedButton2() , .
OnExit() . .
2 , . .

2 " ".

2.3.
: -.
OnBnClickedButton2() , . OnBnClickedButton2() :



row =
x farray
farray

k=0
m_nRows=row
m_nCols=m_nRows+1
- k<row-1
colPos=k
rowPos=k
max=farray[k][k]
i=k
- i<m_nRows
j=k+1
- j<m_nCols-1
(farray[i][j])>max

max=farray[i][j]
rowPos=i
colPos=j
-
j++
-
i++
-
i=0
- i<m_nRows
temp=farray[i][k]
farray[i][k]=farray[i][colPos]
farray[i][colPos]=temp
i++
-
j=0
- j<m_nCols
temp=farray[k][j]
farray[k][j]=farray[rowPos][j]
farray[rowPos][j]=temp
j++
-
j=m_nCols-1
- j>=0
farray[k][j]/=farray[k][k]
j--
-
i=k+1
- i<m_nRows
j=m_nCols-1
- j>=0
farray[i][j]-=farray[k][j]*farray[i][k]
j--
-
i++
-
farray
k++
-
s=0
x[m_nRows-1]=farray[m_nRows-1][m_nCols-1]/farray[m_nRows-1][m_nCols-2]
i=m_nRows-2
- i>=0
s=0
k=i+1
- k<m_nRows
s+=farray[i][k]*x[k]
x[i]=farray[i][m_nCols-1]-s
k++
-
i--
-
x





4 - OnBnClickedButton2

3. ɠ .
3.1. .
. . filereadDlg.cpp.
CfilereadDlgDlg:
- ReadFile() , .
- OnBnClickedOk() - , .
- OnBnClickedButton1() , .
- OnBnClickedButton2() , , .
- OnExit() , .
3.2.
.
, . . , . , . . , . .
, .
1)

5 -


    6

    3)

    7
8.

8 - " "
4.
.
, 9.

9 - " "
, 10.

10 .
:

11 " ".

.

:

12
, .


13 " " .

14 .
.
, 15.

15 .
, .






. Visual C++. MFC Microsoft Visual Studio 6.
, , , .























    , .. : - / ... : - , 2007. 55.: .
    , .. : / .. . .: - .., 2002. 320.
    01-01 : (). . 01-97. . 2001. 01. 07. : , 2001. 35 .
    , ., , ., , .. Visual C++ MFC. .
    , . Visual C++ 7: . .: , 2001. 528 .: .


















Š
Visual C++:
filereadDlg.cpp
// filereadDlg.cpp : implementation file
//

#include "stdafx.h"
#include "fileread.h"
#include "math.h"
#include "filereadDlg.h"
#include ".\filereaddlg.h"

#ifdef _DEBUG
#define new DEBUG_NEW
#endif


// CAboutDlg dialog used for App About

class CAboutDlg : public CDialog
{
public:
CAboutDlg();

// Dialog Data
enum { IDD = IDD_ABOUTBOX };

protected:
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support

// Implementation
protected:
DECLARE_MESSAGE_MAP()
};

CAboutDlg::CAboutDlg() : CDialog(CAboutDlg::IDD)
{
}

void CAboutDlg::DoDataExchange(CDataExchange* pDX)
{
CDialog::DoDataExchange(pDX);
}

BEGIN_MESSAGE_MAP(CAboutDlg, CDialog)
END_MESSAGE_MAP()


// CfilereadDlg dialog



CfilereadDlg::CfilereadDlg(CWnd* pParent /*=NULL*/)
: CDialog(CfilereadDlg::IDD, pParent)
, m_FileTitle(_T(""))
, m_FilePath(_T(""))
{
m_hIcon = AfxGetApp()->LoadIcon(IDR_MAINFRAME);
}

void CfilereadDlg::DoDataExchange(CDataExchange* pDX)
{
CDialog::DoDataExchange(pDX);
DDX_Control(pDX, IDC_LIST1, listbox);
}

BEGIN_MESSAGE_MAP(CfilereadDlg, CDialog)
ON_WM_SYSCOMMAND()
ON_WM_PAINT()
ON_WM_QUERYDRAGICON()
//}}AFX_MSG_MAP
ON_BN_CLICKED(IDOK, OnBnClickedOk)
ON_BN_CLICKED(IDC_BUTTON1, CfilereadDlg::OnBnClickedButton1)
ON_BN_CLICKED(IDC_BUTTON2, CfilereadDlg::OnBnClickedButton2)
END_MESSAGE_MAP()


// CfilereadDlg message handlers

BOOL CfilereadDlg::OnInitDialog()
{
CDialog::OnInitDialog();

// Add "About..." menu item to system menu.

// IDM_ABOUTBOX must be in the system command range.
ASSERT((IDM_ABOUTBOX & 0xFFF0) == IDM_ABOUTBOX);
ASSERT(IDM_ABOUTBOX < 0xF000);

CMenu* pSysMenu = GetSystemMenu(FALSE);
if (pSysMenu != NULL)
{
CString strAboutMenu;
strAboutMenu.LoadString(IDS_ABOUTBOX);
if (!strAboutMenu.IsEmpty())
{
pSysMenu->AppendMenu(MF_SEPARATOR);
pSysMenu->AppendMenu(MF_STRING, IDM_ABOUTBOX, strAboutMenu);
}
}

// Set the icon for this dialog. The framework does this automatically
// when the application's main window is not a dialog
SetIcon(m_hIcon, TRUE);// Set big icon
SetIcon(m_hIcon, FALSE);// Set small icon

// TODO: Add extra initialization here

return TRUE; // return TRUE unless you set the focus to a control
}

void CfilereadDlg::OnSysCommand(UINT nID, LPARAM lParam)
{
if ((nID & 0xFFF0) == IDM_ABOUTBOX)
{
CAboutDlg dlgAbout;
dlgAbout.DoModal();
}
else
{
CDialog::OnSysCommand(nID, lParam);
}
}

// If you add a minimize button to your dialog, you will need the code below
// to draw the icon. For MFC applications using the document/view model,
// this is automatically done for you by the framework.

void CfilereadDlg::OnPaint()
{
if (IsIconic())
{
CPaintDC dc(this); // device context for painting

SendMessage(WM_ICONERASEBKGND, reinterpret_cast<WPARAM>(dc.GetSafeHdc()), 0);

// Center icon in client rectangle
int cxIcon = GetSystemMetrics(SM_CXICON);
int cyIcon = GetSystemMetrics(SM_CYICON);
CRect rect;
GetClientRect(&rect);
int x = (rect.Width() - cxIcon + 1) / 2;
int y = (rect.Height() - cyIcon + 1) / 2;

// Draw the icon
dc.DrawIcon(x, y, m_hIcon);
}
else
{
CDialog::OnPaint();
}
}

// The system calls this function to obtain the cursor to display while the user drags
// the minimized window.
HCURSOR CfilereadDlg::OnQueryDragIcon()
{
return static_cast<HCURSOR>(m_hIcon);
}

int CfilereadDlg::ReadFile(void)
{
CFileDialog OpenDialog(true,"txt",m_FileTitle,OFN_FILEMUSTEXIST|OFN_HIDEREADONLY);
OpenDialog.DoModal();

m_FileTitle=OpenDialog.GetFileTitle();
m_FilePath=OpenDialog.GetPathName();

listbox.AddString(" <>");

return 0;
}

void CfilereadDlg::OnBnClickedOk()
{
// TODO: Add your control notification handler code here
ReadFile();
}

void CfilereadDlg::OnBnClickedButton1()
{
// TODO:
OnSysCommand(IDM_ABOUTBOX,SC_SCREENSAVE);
}

void CfilereadDlg::OnBnClickedButton2()
{
CStdioFile fOpen(m_FilePath,CFile::modeRead);
CString st="";
..................



90% antiplagiat.ru, etxt.ru advego.ru




* . , .