Пример #1
0
 public OutputForm(EntropyData dat) : this()
 {
     infoDat        = dat;
     infoLabel.Text = "Hartly: " + Math.Round(dat.Hartly, 2) +
                      " bit; Shennon: " + Math.Round(dat.Shennon, 2) +
                      " bit \nEntropy: " + Math.Round(dat.Entropy, 2) +
                      " bit; Maximum entropy: " + Math.Round(dat.MaximumEntropy, 2) + " bit";
 }
Пример #2
0
        static void Main(string[] args)
        {
            string A = "Abakraba";
            string B = "Barbara tsucik";

            EntropyData ed1 = new EntropyData(A);
            EntropyData ed2 = new EntropyData(B);

            List <int> a = new List <int>();
            List <int> b = a;
        }
Пример #3
0
 private void Process_Click(object sender, EventArgs e)
 {
     if (!string.IsNullOrEmpty(MainInput.Text))
     {
         EntropyData     ed       = new EntropyData(MainInput.Text, Symbols.Checked, SpacesIgnore.Checked);
         OutputForm      form     = new OutputForm(ed);
         ShennonFanoForm fanoForm = new ShennonFanoForm(ed, this);
         form.Show();
         fanoForm.Show();
     }
     else
     {
         MessageBox.Show("The text field is empty", "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
     }
 }
Пример #4
0
        static void Main(string[] args)
        {
            EntropyData dat = new EntropyData("abcddd cabda");

            return;
        }
 public ShennonFanoForm(EntropyData ed, InputForm inputForm) : this()
 {
     entropyData = ed;
     Symbol.FigureEncoding(ed);
     this.inputForm = inputForm;
 }