【问题描述】 在一个N*N的点阵中,如N=4,你现在站在(1,1),出口在(4,4)。你可以通过上、下、左、右四种移动方法,在迷宫内行走,但是同一个位置不可以访问两次,亦不可以越界。表格最上面的一行加黑数字A[1..4]分别表示迷宫第I列中需要访问并仅可以访问的格子数。右边一行加下划线数字B[1..4]则表示迷宫第I行需要访问并仅可以访问的格子数。如图中带括号红色数字就是一条符合条件的路线。 给定N,A[1..N] B[1..N]。输出一条符合条件的路线,若无解,输出NO ANSWER。(使用U,D,L,R分别表示上、下、左、右。) 2 2 1 2 (4,4) 1 (2,3) (3,3) (4,3) 3 (1,2) (2,2) 2 (1,1) 1 【输入格式】 第一行是数m (n < 6 )。第二行有n个数,表示a[1]..a[n]。第三行有n个数,表示b[1]..b[n]。 【输出格式】 仅有一行。若有解则输出一条可行路线,否则输出“NO ANSWER”。
标签: 点阵
上传时间: 2014-06-21
上传用户:llandlu
asp 客户关系管理系统的实际与实现,包括源码和相关文档(论文)-asp customer relationship management system and implementation of practical, including source code and related documentation (Thesis)
上传时间: 2014-10-13
上传用户:qb1993225
The book uses a task-oriented structure that allows you to work through the steps necessary to install MySQL 4.1 on Linux and Windows platforms, create and manage MySQL databases, query and manipulate data stored in those databases, administer the MySQL database management system, and connect to MySQL databases from your PHP, JSP/Java, and ASP.NET/C# applications. The next section, which describes the book’s structure, provides additional details about the specifics of what the book covers.
标签: task-oriented structure necessary through
上传时间: 2017-09-06
上传用户:a673761058
switch power China IC, powerful and low cost
上传时间: 2015-09-29
上传用户:dxj1900
实验源代码 //Warshall.cpp #include<stdio.h> void warshall(int k,int n) { int i , j, t; int temp[20][20]; for(int a=0;a<k;a++) { printf("请输入矩阵第%d 行元素:",a); for(int b=0;b<n;b++) { scanf ("%d",&temp[a][b]); } } for(i=0;i<k;i++){ for( j=0;j<k;j++){ if(temp[ j][i]==1) { for(t=0;t<n;t++) { temp[ j][t]=temp[i][t]||temp[ j][t]; } } } } printf("可传递闭包关系矩阵是:\n"); for(i=0;i<k;i++) { for( j=0;j<n;j++) { printf("%d", temp[i][ j]); } printf("\n"); } } void main() { printf("利用 Warshall 算法求二元关系的可传递闭包\n"); void warshall(int,int); int k , n; printf("请输入矩阵的行数 i: "); scanf("%d",&k); 四川大学实验报告 printf("请输入矩阵的列数 j: "); scanf("%d",&n); warshall(k,n); }
上传时间: 2016-06-27
上传用户:梁雪文以
#include "iostream" using namespace std; class Matrix { private: double** A; //矩阵A double *b; //向量b public: int size; Matrix(int ); ~Matrix(); friend double* Dooli(Matrix& ); void Input(); void Disp(); }; Matrix::Matrix(int x) { size=x; //为向量b分配空间并初始化为0 b=new double [x]; for(int j=0;j<x;j++) b[j]=0; //为向量A分配空间并初始化为0 A=new double* [x]; for(int i=0;i<x;i++) A[i]=new double [x]; for(int m=0;m<x;m++) for(int n=0;n<x;n++) A[m][n]=0; } Matrix::~Matrix() { cout<<"正在析构中~~~~"<<endl; delete b; for(int i=0;i<size;i++) delete A[i]; delete A; } void Matrix::Disp() { for(int i=0;i<size;i++) { for(int j=0;j<size;j++) cout<<A[i][j]<<" "; cout<<endl; } } void Matrix::Input() { cout<<"请输入A:"<<endl; for(int i=0;i<size;i++) for(int j=0;j<size;j++){ cout<<"第"<<i+1<<"行"<<"第"<<j+1<<"列:"<<endl; cin>>A[i][j]; } cout<<"请输入b:"<<endl; for(int j=0;j<size;j++){ cout<<"第"<<j+1<<"个:"<<endl; cin>>b[j]; } } double* Dooli(Matrix& A) { double *Xn=new double [A.size]; Matrix L(A.size),U(A.size); //分别求得U,L的第一行与第一列 for(int i=0;i<A.size;i++) U.A[0][i]=A.A[0][i]; for(int j=1;j<A.size;j++) L.A[j][0]=A.A[j][0]/U.A[0][0]; //分别求得U,L的第r行,第r列 double temp1=0,temp2=0; for(int r=1;r<A.size;r++){ //U for(int i=r;i<A.size;i++){ for(int k=0;k<r-1;k++) temp1=temp1+L.A[r][k]*U.A[k][i]; U.A[r][i]=A.A[r][i]-temp1; } //L for(int i=r+1;i<A.size;i++){ for(int k=0;k<r-1;k++) temp2=temp2+L.A[i][k]*U.A[k][r]; L.A[i][r]=(A.A[i][r]-temp2)/U.A[r][r]; } } cout<<"计算U得:"<<endl; U.Disp(); cout<<"计算L的:"<<endl; L.Disp(); double *Y=new double [A.size]; Y[0]=A.b[0]; for(int i=1;i<A.size;i++ ){ double temp3=0; for(int k=0;k<i-1;k++) temp3=temp3+L.A[i][k]*Y[k]; Y[i]=A.b[i]-temp3; } Xn[A.size-1]=Y[A.size-1]/U.A[A.size-1][A.size-1]; for(int i=A.size-1;i>=0;i--){ double temp4=0; for(int k=i+1;k<A.size;k++) temp4=temp4+U.A[i][k]*Xn[k]; Xn[i]=(Y[i]-temp4)/U.A[i][i]; } return Xn; } int main() { Matrix B(4); B.Input(); double *X; X=Dooli(B); cout<<"~~~~解得:"<<endl; for(int i=0;i<B.size;i++) cout<<"X["<<i<<"]:"<<X[i]<<" "; cout<<endl<<"呵呵呵呵呵"; return 0; }
标签: 道理特分解法
上传时间: 2018-05-20
上传用户:Aa123456789
The continuous progress in modern power device technology is increasingly supported by power-specific modeling methodologies and dedicated simulation tools. These enable the detailed analysis of operational principles on the the device and on the system level; in particular, they allow the designer to perform trade- off studies by investigating the operation of competing design variants in a very early stage of the development process. Furthermore, using predictive computer simulation makes it possible to analyze the device and system behavior not only under regularoperatingconditions, but also at the rim of the safe-operatingarea and beyond of it, where destructive processes occur that limit the lifetime of a power system.
标签: POWERHVMOS_Devices_Compact_Modeli ng
上传时间: 2020-06-07
上传用户:shancjb
Research on microwave power amplififiers has gained a growing importance demanded by the many continuously developing applications which require such subsystem performance. A broad set of commercial and strategic systems in fact have their overall performance boosted by the power amplififier, the latter becoming an enabling component wherever its effificiency and output power actually allows functionalities and operating modes previously not possible. This is the case for the many wireless systems and battery-operated systems that form the substrate of everyday life, but also of high-performance satellite and dual-use systems.
上传时间: 2021-10-30
上传用户:得之我幸78
通过采用无桥PFC和半桥LLC谐振变换器作为数字开关电源的主变换拓扑,基于STM32系列微控制器的全数字控制PFC和DC-DC变换器,首先对数字化开关电源方案进行对比,然后阐述了200W数字开关电源整体方案,并对数字开关电源的无桥PFC和半桥LLC变换器进行系统研究。By using a bridgeless PFC and a half-bridge LLC resonant converter as the main conversion topology of the digital switching power supply,the all-digital control PFC and DC-DC converter based on the STM32 series of microcontrollers,firstly the digital switching power supply scheme is compared,and then the overall scheme of 200 W digital switching power supply is expounded, and the bridgeless PFC and half-bridge LLC converter of digital switching power supply are systematically studied.
标签: 数字开关电源
上传时间: 2022-04-02
上传用户:qingfengchizhu
目的:自主研制一款超声手术刀电源控制系统,以减少能量的消耗,维持手术刀的正常温度。方法:对超声换能器在谐振附近的等效电路建立模型,并设计基于数字信号处理(DSP)的超声手术刀的硬件控制系统。结果:经对电源控制系统的电路和工作性能测试,生成的电流和电压的有效值等参数,能够及时调整电源的频率,并达到预期的功能指标,使超声手术刀工作在谐振状态。结论:以DSP为核心设计的超声手术刀电源控制系统,测试指标均能够达到预期的要求,能够使系统在谐振状态下工作。Objective: To independently develop a power control system of ultrasonic scalpel so as to reduce the energy consumption and maintain the normal temperature of ultrasonic scalpel. Methods: In this paper, the model of equivalent circuit of ultrasonic transducer nearby syntony was built up, and the hardware control system of ultrasonic scalpel based on digital signal processing(DSP) was designed. Results: Through testing the circuit and work performance of power control system, the series of parameters such as effective value and so on which were produced by this system could adjust frequency of power source in time and attain anticipative functional indicator, and it took the ultrasonic scalpel to work in syntonic situation. Conclusion: The tested indicators of power control system of ultrasonic scalpel based on the kernel design of DSP can attain anticipative requirement, and can take this system to work in syntonic situation.
上传时间: 2022-04-03
上传用户:bluedrops