private void btnStepOK_Click(object sender, System.EventArgs e) { double StartValue = 0; double EndValue = 0; double StepValue = 0; StartValue = double.Parse(NumberCheck(edtFrom.Text)); EndValue = double.Parse(NumberCheck(edtTo.Text)); StepValue = double.Parse(NumberCheck(edtStep.Text)); SAClass1.StartValue = StartValue; SAClass1.EndValue = EndValue; SAClass1.StepValue = StepValue; frmCalc frmCalc1 = new frmCalc(); frmCalc1.SAClass1 = SAClass1; frmCalc1.SAClass_Mode = 2; frmCalc1.ShowDialog(); //SAClass1.SensCalc(); GraphDraw_Step(); btnSave_Enable(false); pnlParameter_Enable(true); }
public void ucAnalysisSetup1_MyButtonClickedEvent(string strName, string strAddition) { switch (strName) { case "Analysis": frmCalc frmCalc1 = new frmCalc(); if (ucAnalysisSetup1.IsSingle() == true) { frmCalc1.MPALayer1 = ucAnalysisSetup1.MPALayer1_Single; } else { frmCalc1.MPALayer1 = ucAnalysisSetup1.MPALayer1_Multi; } frmCalc1.ShowDialog(this); //ucAnalysisSetup1.MPALayer1.Calc(); ucMaterialPerformanceAnalysis1.dOctave = ucAnalysisSetup1.GetFreqBand(); ucMaterialPerformanceAnalysis1.MPALayer1 = frmCalc1.MPALayer1; ucMaterialPerformanceAnalysis1.GraphDraw(""); ucAnalysisSetup1.SaveButtonEnable(true); break; } }
public void FileAllParsing(ucMaterialPropertiesEstimation ucMaterialPropertiesEstimation1, string strName) { bool result; for (int i = 0; i < lstFileList.Items.Count; i++) { MPEClass1 = new MPEClass(); MPEData MPEData1 = MPEClass1.NewMPEData(); result = MPEData1.FileLoad(lstFileList.Items[i].SubItems[1].Text); if (result == false) // 유효한 화일이 아니면 삭제한다 { MPEClass1.DeleteMPEData(MPEData1); } else { MPEClass1.Name = strName; ParameterInput(MPEData1, ucMaterialPropertiesEstimation1); MaterialTypeInput(MPEData1); //MPEData1.Calc(); } } if (MPEClass1 != null) { frmCalc frmCalc1 = new frmCalc(); frmCalc1.MPEClass1 = MPEClass1; frmCalc1.ShowDialog(); } }
private void btnOK_Click(object sender, System.EventArgs e) { double SelectedValue = 0; SelectedValue = double.Parse(NumberCheck(edtParameter.Text)); SAClass1.SelectedValue = SelectedValue; frmCalc frmCalc1 = new frmCalc(); frmCalc1.SAClass1 = SAClass1; frmCalc1.SAClass_Mode = 3; frmCalc1.ShowDialog(); //SAClass1.ResultingCalc(); GraphDraw_Result(strPerformance); btnSave_Enable(true); }
public void DataBaseLoad(ucMaterialPropertiesEstimation ucMaterialPropertiesEstimation1, string strName) { MPEClass1 = new MPEClass(); MPEData MPEData1 = MPEClass1.NewMPEData(); MPEData1.Name = strName; DB_Load(MPEData1); ParameterInput(MPEData1, ucMaterialPropertiesEstimation1); MaterialTypeInput(MPEData1); MPEClass1.SID = int.Parse(lblDataBaseLoad_ID.Text); MPEClass1.Name = lblDataBaseLoadName.Text; frmCalc frmCalc1 = new frmCalc(); frmCalc1.MPEClass1 = MPEClass1; frmCalc1.ShowDialog(); //MPEData1.Calc(); //MPEClass1.Temp(); //MPEClass1.Calc(); }
private void btnAnalysis_Click(object sender, System.EventArgs e) { if (edtName.Text != "") { if (DataBaseLoadCheck() == true) { SAClass1 = new SAClass(); /////////////////////////////////////////// SAClass1.Temperature = double.Parse(edtTemperature.Text); /////////////////////////////////////////// if (rdoNormalIncidence.Checked == true) { SAClass1.Incidence = 1; SAClass1.IncAngle = 0.0; } else { SAClass1.Incidence = 2; SAClass1.IncAngle = double.Parse(edtLimitAngle.Text); } /////////////////////////////////////////// if (rdoTransmissionLoss.Checked == true) { dSelectedPerformance = 1; } else if (rdoAbsorptionCoefficientRigidBacking.Checked == true) { dSelectedPerformance = 2; } else if (rdoAbsorptionCoefficientAnechoicTermination.Checked == true) { dSelectedPerformance = 3; } SAClass1.GraphType = dSelectedPerformance; /////////////////////////////////////////// switch (cboMeterialType.SelectedItem.ToString()) { case "Air": SAClass1.MID = 1; break; case "Panel": SAClass1.MID = 2; break; case "Impermeable membrane": SAClass1.MID = 3; break; case "Permeable membrane": SAClass1.MID = 4; break; case "Limp porous material": SAClass1.MID = 5; break; case "Rigid porous material": SAClass1.MID = 6; break; case "Elastic porous material": SAClass1.MID = 7; break; case "Panel-elastic (BU)": SAClass1.MID = 8; break; case "Elastic-panel (UB)": SAClass1.MID = 9; break; case "Panel-elastic-panel (BB)": SAClass1.MID = 10; break; } /////////////////////////////////////////// SAClass1.Name = edtName.Text; /////////////////////////////////////////// SAClass1.FlowRes = double.Parse(edtFlowResistivity.Text); SAClass1.Thick = double.Parse(edtThickness.Text); SAClass1.LossFactor = double.Parse(edtLossFactor.Text); SAClass1.BulkDens = double.Parse(edtBulkDensity.Text); SAClass1.Ymodulus = double.Parse(edtYoungsModulus.Text); SAClass1.PoissionR = double.Parse(edtPoissionsRatio.Text); SAClass1.ThermalCL = double.Parse(edtThermalCharLength.Text); SAClass1.ViscousCL = double.Parse(edtViscousCharLength.Text); SAClass1.Porosity = double.Parse(edtProsity.Text); SAClass1.SFactor = double.Parse(edtStructureFactor.Text); /////////////////////////////////////////// SAClass1.VarID = GetVar(); frmCalc frmCalc1 = new frmCalc(); frmCalc1.SAClass1 = SAClass1; frmCalc1.SAClass_Mode = 1; frmCalc1.ShowDialog(); //SAClass1.InitCalc(); MyButtonClicked("Analysis", ""); } } else { MessageBox.Show("Name 을 입력하여 주십시오."); } }
private void btnAnalysis_Click(object sender, System.EventArgs e) { if(edtName.Text != "") { if(DataBaseLoadCheck() == true) { SAClass1 = new SAClass(); /////////////////////////////////////////// SAClass1.Temperature = double.Parse(edtTemperature.Text); /////////////////////////////////////////// if(rdoNormalIncidence.Checked == true) { SAClass1.Incidence = 1; SAClass1.IncAngle = 0.0; } else { SAClass1.Incidence = 2; SAClass1.IncAngle = double.Parse(edtLimitAngle.Text); } /////////////////////////////////////////// if(rdoTransmissionLoss.Checked == true) { dSelectedPerformance = 1; } else if(rdoAbsorptionCoefficientRigidBacking.Checked == true) { dSelectedPerformance = 2; } else if(rdoAbsorptionCoefficientAnechoicTermination.Checked == true) { dSelectedPerformance = 3; } SAClass1.GraphType = dSelectedPerformance; /////////////////////////////////////////// switch (cboMeterialType.SelectedItem.ToString()) { case "Air": SAClass1.MID = 1; break; case "Panel": SAClass1.MID = 2; break; case "Impermeable membrane": SAClass1.MID = 3; break; case "Permeable membrane": SAClass1.MID = 4; break; case "Limp porous material": SAClass1.MID = 5; break; case "Rigid porous material": SAClass1.MID = 6; break; case "Elastic porous material": SAClass1.MID = 7; break; case "Panel-elastic (BU)": SAClass1.MID = 8; break; case "Elastic-panel (UB)": SAClass1.MID = 9; break; case "Panel-elastic-panel (BB)": SAClass1.MID = 10; break; } /////////////////////////////////////////// SAClass1.Name = edtName.Text; /////////////////////////////////////////// SAClass1.FlowRes = double.Parse(edtFlowResistivity.Text); SAClass1.Thick = double.Parse(edtThickness.Text); SAClass1.LossFactor = double.Parse(edtLossFactor.Text); SAClass1.BulkDens = double.Parse(edtBulkDensity.Text); SAClass1.Ymodulus = double.Parse(edtYoungsModulus.Text); SAClass1.PoissionR = double.Parse(edtPoissionsRatio.Text); SAClass1.ThermalCL = double.Parse(edtThermalCharLength.Text); SAClass1.ViscousCL = double.Parse(edtViscousCharLength.Text); SAClass1.Porosity = double.Parse(edtProsity.Text); SAClass1.SFactor = double.Parse(edtStructureFactor.Text); /////////////////////////////////////////// SAClass1.VarID = GetVar(); frmCalc frmCalc1 = new frmCalc(); frmCalc1.SAClass1 = SAClass1; frmCalc1.SAClass_Mode = 1; frmCalc1.ShowDialog(); //SAClass1.InitCalc(); MyButtonClicked("Analysis",""); } } else { MessageBox.Show("Name �� �Է��Ͽ� �ֽʽÿ�."); } }
public void ucAnalysisSetup1_MyButtonClickedEvent(string strName,string strAddition) { switch(strName) { case "Analysis" : frmCalc frmCalc1 = new frmCalc(); if(ucAnalysisSetup1.IsSingle() == true) { frmCalc1.MPALayer1 = ucAnalysisSetup1.MPALayer1_Single; } else { frmCalc1.MPALayer1 = ucAnalysisSetup1.MPALayer1_Multi; } frmCalc1.ShowDialog(this); //ucAnalysisSetup1.MPALayer1.Calc(); ucMaterialPerformanceAnalysis1.dOctave = ucAnalysisSetup1.GetFreqBand(); ucMaterialPerformanceAnalysis1.MPALayer1 = frmCalc1.MPALayer1; ucMaterialPerformanceAnalysis1.GraphDraw(""); ucAnalysisSetup1.SaveButtonEnable(true); break; } }
public void DataBaseLoad(ucMaterialPropertiesEstimation ucMaterialPropertiesEstimation1,string strName) { MPEClass1 = new MPEClass(); MPEData MPEData1 = MPEClass1.NewMPEData(); MPEData1.Name = strName; DB_Load(MPEData1); ParameterInput(MPEData1,ucMaterialPropertiesEstimation1); MaterialTypeInput(MPEData1); MPEClass1.SID = int.Parse(lblDataBaseLoad_ID.Text); MPEClass1.Name = lblDataBaseLoadName.Text; frmCalc frmCalc1 = new frmCalc(); frmCalc1.MPEClass1 = MPEClass1; frmCalc1.ShowDialog(); //MPEData1.Calc(); //MPEClass1.Temp(); //MPEClass1.Calc(); }
public void FileAllParsing(ucMaterialPropertiesEstimation ucMaterialPropertiesEstimation1,string strName) { bool result; for(int i = 0 ; i < lstFileList.Items.Count ; i++) { MPEClass1 = new MPEClass(); MPEData MPEData1 = MPEClass1.NewMPEData(); result = MPEData1.FileLoad(lstFileList.Items[i].SubItems[1].Text); if(result == false) // ��ȿ�� ȭ���� �ƴϸ� �����Ѵ� { MPEClass1.DeleteMPEData(MPEData1); } else { MPEClass1.Name = strName; ParameterInput(MPEData1,ucMaterialPropertiesEstimation1); MaterialTypeInput(MPEData1); //MPEData1.Calc(); } } if(MPEClass1 != null) { frmCalc frmCalc1 = new frmCalc(); frmCalc1.MPEClass1 = MPEClass1; frmCalc1.ShowDialog(); } }