private void AddMatrixControls()
        {
            MaxRowsNumericUpDown     = new EzNumericUpDown(1, MATRIX_ROWS, MATRIX_ROWS);
            MaxColumnsNumericUpDown  = new EzNumericUpDown(1, MATRIX_COLUMNS, MATRIX_COLUMNS);
            DenominatorNumericUpDown = new EzNumericUpDown(1, MATRIX_COLUMNS * MATRIX_ROWS + 1, MATRIX_COLUMNS * MATRIX_ROWS + 1);
            MaxRowsNumericUpDown.NumericScrollBar.ValueChanged    += ChangeRowColumnCount;
            MaxColumnsNumericUpDown.NumericScrollBar.ValueChanged += ChangeRowColumnCount;

            var sp = new StackPanel {
                Margin = new Thickness(0, 4, 0, 4)
            };

            sp.Orientation = Orientation.Horizontal;
            var tb = new TextBlock {
                Text = "行", VerticalAlignment = VerticalAlignment.Center
            };

            sp.Children.Add(tb);
            sp.Children.Add(MaxRowsNumericUpDown);
            sp.Children.Add(new TextBlock {
                Text = "列", VerticalAlignment = VerticalAlignment.Center
            });
            sp.Children.Add(MaxColumnsNumericUpDown);
            sp.Children.Add(new TextBlock {
                Text = "分母", VerticalAlignment = VerticalAlignment.Center
            });
            sp.Children.Add(DenominatorNumericUpDown);
            MyStackPanel.Children.Add(sp);
        }
        private void SetMatrixNumericUpDown()
        {
            MatrixNumericUpDown = new EzNumericUpDown[MATRIX_ROWS][];

            for (int i = 0; i < MATRIX_ROWS; ++i)
            {
                EzNumericUpDown[] stackPanel = new EzNumericUpDown[MATRIX_COLUMNS];
                for (int j = 0; j < MATRIX_COLUMNS; ++j)
                {
                    stackPanel[j] = new EzNumericUpDown(0, MATRIX_COLUMNS * MATRIX_ROWS + 1);
                }
                MatrixNumericUpDown[i] = stackPanel;
            }
        }