Control, structure and syntax.

Table of Content:

Control, structure and syntax.

This chapter provides information on the basic structure of a calculation (workbook and sheets). It explains how to control the calculation, how to enter input values, where and how to get help immediately, how to get a correct solution and what to avoid during the calculation. Some rules for work with the calculation workbooks and calculated data can be found at the end.

All the calculations are produced as workbooks in MS Excel. One calculation = one workbook. It is, therefore, good (however, not necessary) to have basic knowledge of MS Excel (or a similar table calculator) and how to work with this program. Knowledge of MS Excel enables you to more easily understand the method of control, entry of input data and a number of other standard operations such as saving, printing documents, formatting or sharing them with others.

Structure of the calculation workbook.

Most calculation workbooks consist of the following sheets:

If it is necessary for the algorithm and solution of the task, some sheets may be omitted in the workbook or, on the contrary, other sheets may be present with auxiliary inputs, auxiliary algorithms, etc.

Start of calculation.

The calculation can be started in several ways. The description can be found in the chapter "Installation, HW and SW requirements, starting". After starting, a "Calculation" sheet is displayed in MS Excel. This sheet contains everything for the immediate solution of the problem.

Warning: If you save a workbook with a calculation with another active sheet, the state of the last saving is displayed at startup.

Description of the "Calculation" sheet.

The "Calculation" sheet is the most important sheet of the workbook. It contains formulas, input and output cells and usually includes the algorithm of the calculation as well.

Sheet division.

The sheet is divided horizontally into two differently sized parts. The upper, narrower part is a header, which contains the name of the calculation and the basic control and information elements. The header is anchored and always visible, even if you roll the lower part of the sheet upwards. On the illustration below, the extent of the header is marked with the number [1].

The lower part of the sheet is divided into three chapters, while the division is based on the natural procedure of the solution of the majority of technical tasks.

Individual chapters consist of numbered paragraphs and rows. Each paragraph associates parameters that are connected logically or parameters of similar character (for example: power, dimension, strength, etc.) so that the structure of the task is well arranged and logical.

Note: If the chapter includes only 2 to 3 paragraphs, the title of the chapter is omitted and the meaning of the paragraphs (relative to the respective chapter) is marked in its color (light green, light yellow, light red) to simplify the appearance.

Control elements.

Control elements are explained in the following illustration.

  1. Header - The first row of the header shows (from left): The button for starting the "Integrated environment", the button for displaying "Help" and the name of the calculation. The right part of the row in some calculations includes the buttons that initiate the solution implemented in VBA language.
  2. Header - The second row of the header is the state row. It displays the calculation state. If a result is outside of the recommended values, a list of problematic rows is displayed here.
  3. Project - Help on the "Project" is given in a separate chapter.
  4. Chapter - The row specifying the chapter. Pressing the "[+]/[ - ]"button in this row displays/hides all the rows in all the paragraphs of the given chapter.
  5. Paragraph - The row specifying the paragraph. Enabling/disabling the check box displays/hides all the rows of the respective paragraph.
  6. Comment - Comments can be displayed by positioning the cursor onto the cell marked by a small red triangle in the upper right corner. The comment contains important information on the respective row (instructions, recommended values).
  7. Selection list - Clicking on the selection list rolls it up and the desired value or option can be set by selecting the respective row.
  8. Input cell - Numerical values are entered into cells with a white background. The values are entered with the keyboard.
  9. Automatic filling - If the check box is located next to the input cell, enabling it causes the input cell to be automatically filled with the recommended value. Enabling the check box also causes a change in color of the input cell to light blue. The recommended value is usually located next to the input cell, in a green cell.
  10. Name of the sheet - The lower edge contains the names of the sheets included in the workbook. Clicking on the respective folder toggles between the sheets.

Meaning of the color of cells.

Entering values.

Enter the numerical values from the keyboard into the respective white field and confirm them using the "ENTER" key. A majority of input fields are provided with preset ranges of valid values. If you try to enter a value outside the permitted range, a warning message is displayed. In such case, repeat the entry of a correct value. Ranges and recommended values can be found in the on-line help - in the commentary next to the row number.

Warning: Never copy another cell into the input cell (Command Ctrl+C, Ctrl+V). This might cause the preset values of input cells to be deleted (formatting, conditioned format, range verification). If you need to copy a value into the input cell, copy the content (value) of the cell only. Command: Editing->Paste new->Paste values.

Types of calculations.

In view of the control, two basic types of calculations are distinguished.

Automatic calculation.

These are the calculations, in which the algorithm of the solved task is written directly into the "Calculation" sheet using the formulas and functions of MS Excel. The calculation then behaves as a common table in MS Excel. After a change in any input value, the complete result displays immediately. (Example: Calculation of gearing, belt or chain transmissions, etc.).

Note: Automatic calculations usually do not include auxiliary functions (algorithms) that optimize or help entry of some input parameters to give the calculation as natural a structure as possible. However, these functions will be initiated using a button located inside the respective paragraph.

Calculation on request.

It is a type of calculation where it is necessary to perform a series of iterations and the algorithm of the task is written in VBA language. Enter and set all the input parameters in the calculation. Results are then displayed/refreshed after running through the calculation, which can be initiated by clicking on the button. The button is located on the upper anchored edge of the "Calculation" sheet so that it is easily available anytime.
(Example: Calculation of beams, shafts and profiles)

Note: The calculation on request is also usually solved using MS Excel formulas and functions. Therefore, certain parts (paragraphs) of the calculation reflect the changes in the entered values. However, the solution to the task MUST/b> always be started to recalculate it completely.

From the aspect of the bearing of the calculation, it is distinguished:

Design calculation.

Design calculations are the calculations that provide a design of some part(s) of particular dimensions based on the input parameters.

Examples of a design calculation:

Check calculation.

Check calculations are the calculations where the calculation finds deformations and the levels of safety of a particular loaded part.

Examples of a check calculation:
Note: Even with the design calculation, it is certainly possible to check the existing parts and, on the contrary, design a part with the correct dimensions using the check calculation. However, it is necessary to perform several iterations or use some auxiliary calculations, which can be usually found in the third chapter - Chapter of supplements.

Calculation procedure.

Because it is difficult to give a uniform procedure that is generally valid for all types of calculations, this section gives a summary of rules, which, if followed, should lead to a suitable solution.

Units and standards.

Calculation module - workbooks are designed according to particular standards, generally applicable procedures and the recommendations of producers, or a combination of these sources. These can be further used for a particular unit system, or it is possible to specify the units directly in the calculation.

Generally, you can encounter the following types of calculations and their characteristic features.

  1. SI Calculations
    - The icon of the module contains the letter "M" in a yellow square
    - only in SI units (mm, N, kW)
    - Orientation, above all, is towards the standards of ISO, DIN, JIS, BS, etc.

  2. Imperial Calculations
    - The icon of the module contains the letter "I" in a green square
    - only in Imperial units (in, lbf, HP....)
    - Orientation, above all, is towards the standards (associations) of ANSI, AGMA, ASME, etc.

  3. Calculations for both unit systems
    - Icon without any special marking
    - Toggling between the units inside the module
    - Selection of a standard or a calculation procedure inside the module
    - Basic documents of particular producers

  4. Calculations independent of the unit
    - Icon without any special marking
    - Independent of the unit
    - Containing mostly various recommendations and tables

Toggling between the units.

If the calculation - workbook supports both unit systems, toggling between the units can usually be found on the "Calculation" sheet in the first paragraph on the first row [1.1]

Toggling between the standards (producers, procedures).

If the module - workbook supports calculations according to various standards or procedures, this option can usually be found on the "Settings" sheet or on a suitable place in the calculation.

Recommended values.

Recommended values (or their minimums/maximums) are given for most of the input parameters in the calculation (comments) and in help. This data is based on common conditions and experience, and these values can be exceeded in special and reasonable cases. Recommended values can be found in green cells.

Excess of the recommended values is indicated by a change in color of the parameter to red. Substantial excess of the recommended values, which may cause a breakdown, make the unit impossible to assemble or create a critical decrease in the service life or level of safety, is indicated by a change in color of the field to red.

Saving results.

After installation, the workbooks containing calculations are not protected against overwriting. You can set your own input values, save the calculation and, if you just start up, the calculation will contain your entered values. This procedure is suitable for setting the parameters common for most of your tasks.

If you solve various tasks or calculate more alternatives in one task, it is advisable to save such calculations under new names. This saves not only the task, but also the complete calculation, including all results. If the calculation is saved under a new name, you can use the "Information on the project" paragraph. For searching for a calculation, you can use the tool for "Retrieval of a calculation", which is delivered in the MITCalc package.

Hint: The calculations that in the final version shall be provided with the "Read only" option (Menu: File -> Save as -> Tools -> Options -> Setting of attribute "Read only"). This may avoid undesired changes in parameters.