⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 solveview.h

📁 经典四阶龙哥库塔法解方程组
💻 H
字号:
// SolveView.h : interface of the CSolveView class
//
/////////////////////////////////////////////////////////////////////////////

#if !defined(AFX_SOLVEVIEW_H__1B47B0AF_9D5C_49AA_9E8D_503119E6CBB1__INCLUDED_)
#define AFX_SOLVEVIEW_H__1B47B0AF_9D5C_49AA_9E8D_503119E6CBB1__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
#include "MemDC.h"

class CSolveView : public CView
{
protected: // create from serialization only
	CSolveView();
	DECLARE_DYNCREATE(CSolveView)

// Attributes
public:
	CSolveDoc* GetDocument();

// Operations
public:

// Overrides
	// ClassWizard generated virtual function overrides
	//{{AFX_VIRTUAL(CSolveView)
	public:
	virtual void OnDraw(CDC* pDC);  // overridden to draw this view
	virtual BOOL PreCreateWindow(CREATESTRUCT& cs);
	virtual void OnInitialUpdate();
	protected:
	virtual BOOL OnPreparePrinting(CPrintInfo* pInfo);
	virtual void OnBeginPrinting(CDC* pDC, CPrintInfo* pInfo);
	virtual void OnEndPrinting(CDC* pDC, CPrintInfo* pInfo);
	//}}AFX_VIRTUAL

// Implementation
public:

	float t[2000];
	float x1[2000],x2[2000],x3[2000];
	float h;
	int n;
	BOOL bSolved;
	void RungeKutta(float t0,float x10, float x20,float x30, float h, int n);
	
	CPen penGreen,penRed,penBlue,penBlack,*oldPen;
	float  f1(float t,float x1,float x2,float x3);
	float  f2(float t,float x1,float x2,float x3);
	float  f3(float t,float x1,float x2,float x3); 

	void DrawSolves(CDC *pDC);
	CDC m_memDC;
	void InitMemDC();
	virtual ~CSolveView();
#ifdef _DEBUG
	virtual void AssertValid() const;
	virtual void Dump(CDumpContext& dc) const;
#endif

protected:

// Generated message map functions
protected:
	//{{AFX_MSG(CSolveView)
	afx_msg void OnSolve();
	afx_msg void OnOutput();
	//}}AFX_MSG
	DECLARE_MESSAGE_MAP()
};

#ifndef _DEBUG  // debug version in SolveView.cpp
inline CSolveDoc* CSolveView::GetDocument()
   { return (CSolveDoc*)m_pDocument; }
#endif

/////////////////////////////////////////////////////////////////////////////

//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.

#endif // !defined(AFX_SOLVEVIEW_H__1B47B0AF_9D5C_49AA_9E8D_503119E6CBB1__INCLUDED_)

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -