📄 unit1.~cpp
字号:
//---------------------------------------------------------------------------
#include <vcl.h>
#pragma hdrstop
#include "Unit1.h"
#include "matlib.h"
#include "Yh.cpp"
//---------------------------------------------------------------------------
#pragma package(smart_init)
#pragma resource "*.dfm"
TForm1 *Form1;
//---------------------------------------------------------------------------
__fastcall TForm1::TForm1(TComponent* Owner)
: TForm(Owner)
{
}
//---------------------------------------------------------------------------
void __fastcall TForm1::Button1Click(TObject *Sender)
{
// double a[11]={0,0.1,0.2,0.3,0.4,0.5,0.6,0.7,0.8,0.9,1};
// double b[11]={-0.447,1.978,3.28,6.16,7.08,7.34,7.66,9.56,9.48,9.30,11.2} ;
int a[4]={1,2,3,4};
int b[4]={1,4,9,16} ;
double p2;
initM(MATCOM_VERSION);
Mm x,y,pp2;
M_VECTOR(x,a);
M_VECTOR(y,b);
pp2=Yh(x,y);
/* for(int i=1;i<4;i++)
{
b[i-1]=*xx.addr(i);
}*/
for(int i=0;i<3;i++)
{
for(int j=0;j<3;j++)
{
p2=*pp2.addr(i+1,j+1);
Memo1->Lines->Add(FloatToStr(p2)) ;
}
}
exitM();
// Edit1->Text=FloatToStr(p2);
}
//---------------------------------------------------------------------------
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -