我的方程似乎有问题,我想解决这样的问题Z= A/(C*B),其中A等于F/G(i.e A=F/G)但似乎我在计算时得到了相同的答案,A无论Z我改变程序输出的值多少次A,Z相等,这在数学上是不正确的,因为如果我说A=4/2我得到 a2并且Z = 2/(8*1)应该0.25认为我错过了什么?我的代码
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
namespace trafic_model
{
public partial class Form1 : Form
{
double a = 0, b = 0;
public Form1()
{
InitializeComponent();
}
private void button1_Click(object sender, EventArgs e)
{
//С1
a = Convert.ToDouble(textBox1.Text) / Convert.ToDouble(textBox2.Text);
label3.Text = "C1 = " + a.ToString() + " Мбит/с.";
//end of c1
//N1
z = (a / (Convert.ToDouble(textBox3.Text) * Convert.ToDouble(textBox5.Text)));
label6.Text = "N1 = " + a.ToString() ;
//
}
}