?? fdtd_2d_te_periodic.h
字號:
// FDTD_2D_TE_PERIODIC.h: interface for the FDTD_2D_TE_PERIODIC class.
//
//////////////////////////////////////////////////////////////////////
#if !defined(AFX_FDTD_2D_TE_PERIODIC_H__C0FA6DDF_CA34_410F_ADDA_5B3F2DE95FAC__INCLUDED_)
#define AFX_FDTD_2D_TE_PERIODIC_H__C0FA6DDF_CA34_410F_ADDA_5B3F2DE95FAC__INCLUDED_
#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
#include "FDTD_1D_HzEy.h"
class FDTD_2D_TE_PERIODIC:public FDTD_1D_HzEy
{
private:
double pi;
double eps_0, mu_0;
int ** Index;
double ** Mater;
double **Fz, **Hz;
double **Ex, **Gx;
double **Ey, **Gy;
double Fz_r, Gx_r, Gy_r;
double *K_E2_a, *K_E4_a, *K_E5_a;
double *K_E2_b, *K_E4_b, *K_E5_b;
//dimensions of the computational space
int nx, ny;
double dx, dy, dt;
//number of materials present in the investigated geometry
int n_Mat;
//dimension of the PML region
int n_PML;
int i, j;
double mu_r, eps_r;
int jel_source_type; //the type of the excitation
double H0, t0, tw, omega, phi; //parameters of the excitation
//Soft source
int n_x_P, n_y_P; //coordinates of the point source
int **Coord; //line source (multiple point source)
int n_Coord; //the number of points in the line source
//Total field - Scattered field plane wave formulation
int n_x_a, n_x_b; //coordinates of the Total field-Scattered field region
int **Ind_Foll; //the coordinates of the followed field components
int length_Ind_Foll, n_tot; //number of the followed points and the number of iterations
double **Hz_Foll, **Ex_Foll, **Ey_Foll;//strores the followed field components
public:
FDTD_2D_TE_PERIODIC();
virtual ~FDTD_2D_TE_PERIODIC();
BOOL Init_Main_Param(int ** &index, int n_x, int n_y, double ** &mater, int n_mat,
int n_pml, double d_t, double d_x, double d_y);
void Set_PML_Param();
void calc_Hz_TE();
void calc_Ex_TE();
void calc_Ey_TE();
//Functions referring to excitation
//Point Source
void Init_Gauss_Point_Source(int n_x_p, int n_y_p, double h0, double t_0, double t_w);
void Init_Sinus_Point_Source(int n_x_p, int n_y_p, double h0, double omega,
double phase);
void Init_PulseGS_Point_Source(int n_x_p, int n_y_p, double h0, double t_0, double t_w,
double omega, double phase);
void Point_Source(double time);
//Line Source
void Init_Gauss_Line_Source(int ** &Coord, int n_Co, double h0, double t_0, double t_w);
void Line_Source(double time);
//Plane wave with Total field - Scattered field formulation
void Init_TotFScatF(int n_xa, int n_xb, double H0, double t0, double tw, double omega,
double phi, int jel);
void incident_Hz();
void incident_Ex();
void incident_Ey();
//Periodic Boundary conditions
void periodic_Hz();
void periodic_Ex();
//Free the allocated memory
void Free_Mem();
//the coordinates of the followed field components
BOOL Init_Followed(int **Ind_Followed, int n, int n_t);
void Set_Data_Followed(int n_t);
void Get_Data_Followed(double **&A, double **&B, double **&C);
//Outputs the field components
void Get_Data(double **&A, double **&B, double **&C);
};
#endif // !defined(AFX_FDTD_2D_TE_PERIODIC_H__C0FA6DDF_CA34_410F_ADDA_5B3F2DE95FAC__INCLUDED_)
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -