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

📄 sample.cpp

📁 用人工神经网络实现异或的功能。用反向传播算法(BP)来实现神经网络
💻 CPP
字号:
// Sample.cpp: implementation of the Sample class.
//
//////////////////////////////////////////////////////////////////////

#include "stdafx.h"
#include "Sample.h"

//////////////////////////////////////////////////////////////////////
// Construction/Destruction
//////////////////////////////////////////////////////////////////////

Sample::Sample()
{

}

Sample::~Sample()
{

}


Sample::Sample(int innum, int outnum, double inarray[], double outarray[])
{
	if(innum<MAX_INPUTNUM && outnum<MAX_OUTPUTNUM)
	{
		inputnum=innum;
	
		outputnum=outnum;

	
		for(int i=0;i<innum;i++)
		
			x[i]=inarray[i];

	
		for(int j=0;j<outnum;j++)
		
			y[j]=outarray[j];
	}

	else
		printf("every uint too many  input or output");


}

⌨️ 快捷键说明

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