Enhancing calculations (Australian design example)

Tekla Tedds
2022
Tekla Tedds Tekla Tedds for Word

Enhancing calculations (Australian design example)

There is even more functionality available for our calculations than we have seen so far. Whether you use these enhancements depends both on the purpose of the calculation, and on the time you have available. Certainly these features are very useful when you are writing calculations which others will use (as we do at Trimble). Hence the Tedds library is packed with examples which use these features, and you have already seen many of them when running our calculations.

In this exercise we will enhance the previous calculation and you will see what we are talking about.

Allow about 15 minutes to complete this exercise.

Buttons used in this exercise

The only new command you will be introduced to in this exercise is located on the Insert group of the Tedds Calcs ribbon as shown below:

Tedds Input Fields

The Tedds Input Field speeds up the editing and often the creating of input variables. We will replace all the existing variable definitions in the calculation:

  1. Delete the entire definition for the Yield strength, fu, from your page. Leave your cursor on the empty line.
  2. Click the Tedds Field button.
  3. The following dialog will appear.
    Tedds Input Field
    Prompt tells the user what the variable is and appears on the page
    Name the unique name of the variable
    Units if the property has dimensions then enter a unit here
    Default value this value will be displayed initially for user to edit or accept
    Format the format displayed on the page
    No. of decimal places the number of decimal places displayed on the page
  4. Enter the details shown to define the input for this variable:

    Prompt = Yield strength

    Name = fu

    Units = MPa

    Default value = 430

    Format = Fixed

    No. of decimal places = 0

  5. Accept the defaults for other options and click OK when you have everything entered.
    Note: We do not put a value in this dialog - this is entered when the statement is calculated.
  6. The following will appear on the line containing your cursor:
  7. With the Field Codes button on you will see the following Tedds Input Field preceding the text on the line.
  8. Calculate your document to run it.

    The Set Variable Value dialog appears, as shown above.

  9. Because we already have a value defined for this variable it is displayed in the input. You can accept it, or edit it as required. There is no need to find and edit the variable value on the page, as it is automatically updated when you enter a value in the Set Variable Value dialog.
  10. Delete and replace the 3 remaining variable definitions in the same manner – the table below shows what you need to enter in the Insert Tedds Field dialog for each of the three variables in order from left to right. When you have done this, recalculate your document to ensure that your definitions are correct.
    Insert Tedds Field Properties
    Input Tf Le λL
    Prompt Tie force Tie effective length Slenderness limit
    Name Tf Le λL
    Units kN m
    Default value 300
    Format fixed fixed fixed
    No. of decimal places 2 3 0
    Note: To enter Greek characters in the Insert Tedds Field dialog for variable names like λ simply click the Greek character button ( ) and then type in the equivalent Roman character, in this case you need to type l (i.e. lowercase letter L) to get λ. To enter Subscript or Superscript characters simply click the Subscript or Superscript button (, ) and then continue and type in the subscript or superscript. Once you have reached its end click the button again to switch back to typing normal text.

    The Default value is entirely optional. If you enter one it will be displayed the first time a calculation is run, otherwise the input box will be empty. Delete the stored variables and re-calculate to see the defaults in operation.

    Tedds Interface Designer
    Although The Tedds Input Field can be used to create all the variables required in a calculation, if you would like to give your calculations a slicker appearance we would strongly recommend using the Tedds Interface Designer instead. This easy to use tool allows you to place all the input variables on a single interface along with sketches and notes if required. For a worked example and further details of how to use the Tedds Interface Designer refer to the Tedds Help.

Tedds Show Fields

The final thing we would like the calculation to do is automatically assess our section and report in the document whether our chosen section is passing or failing and, if it is failing, why. We use a Tedds Show Field to do this.

  1. Enter the following two paragraphs after your existing calculations:
  2. These last two values help us assess the utilisation of the section for the two checks. Assigning them to output variables will help us with creating Tedds Show Fields. Calculate your document once you have written them to ensure they are working properly before proceeding.
  3. Place your cursor beneath these paragraphs and click the Insert Tedds Field button.
  4. Select the Show tab. The Show Field we want to create will test whether the section is failing stress and output a message to give the status of the check.
  5. Select the Condition type option and input the following information:
  6. The output of the Tedds Show Field consists of two text messages known as output strings. Only one output string is displayed in the document depending on the status of the condition.
  7. Check your input carefully, then click OK to enter the Tedds Show Field in the document.
  8. When you have OK'd the input, click the Field Codes button to view the resulting Tedds Show Field. It should be as shown below. If your Tedds Show Field is incorrect, the best thing to do at this stage is to delete it and run through the Insert Tedds Field dialog again.

Using logic In Tedds

Take a close look at this Tedds Show field, and you can see how we use a simple logic statement to output one of two pieces of text using the if logical operator.

if(check_stress > 1, “Section fails stress check” , “Section OK for stress”) 

The general form of this logic expression is as follows:

if(condition, true_output, false_output)
Note: You can use this kind of expression to define variables using a condition. The outputs can be values, expressions or further logic expressions.

For example:

a = if(b > c, 10, 20) = ? 

Check table of Logic Functions in the Mathematics topic for full details.

  1. Now calculate your document to calculate the Tedds Show Field. You should find you have something similar to the following in your Progress Log and you will also see the output text on the page where you placed the Tedds Show Field.
  2. Change some of your input values and re-calculate a few times to test your full calculation and both the pass and fail output of the Tedds Show Field.

Tedds Data List Fields

In the previous exercise we inserted a Data List Field into the calculation using the Engineering Data button. However, it could have been inserted more easily using the Tedds Field button:

  1. With the Field Codes button on you will see the following Tedds Data List Field:
  2. Delete the entire definition of this field from your page. Leave your cursor on the empty line.
  3. Click the Tedds Field button.
  4. Select the Data List option and scroll down to select the same .dls file name as that shown in the line you just deleted above.
  5. Input the Prompt as Select Section.
  6. To input the Default page and Default item click the ellipsis button ( ) and then select the page and section size that you want to appear as the default.
  7. Accept the defaults for other options and click OK when you have everything entered.
  8. Calculate your document to run it once more.

What next?

Congratulations! You have completed the final exercise in the guide and are ready to begin using Tedds to its full potential.

Here are a few things you could try next:

  • Create another Tedds Show Field similar to that above for the slenderness check - following is the logic statement you would use for this:
    Condition
       check_slender > 1
  • Create a Tedds Show Field to give the overall status of the section, checking both slenderness and stress. Try the following:
    Condition
       check_slender > 1
    Yes PASS
    No Section fails!
  • Take a look at Tedds Message Fields. The input for these is the same as Tedds Show Fields but their output is displayed in a Message box, rather than in the document. You will see examples of their use in the Tedds Engineering Library Calculations.
  • Try creating Messages using the Value of Variable option to show the values of the minimum area and radius of gyration in the Log before the Data List is displayed.

Of course there's much more for you to discover. We wish you an enjoyable and productive time in using the program in your day-to-day work, and exploring its capabilities more fully.

If you would like to read up on further information about Tedds, then we recommend the Tedds Help system, which you can access in the usual way.

Some Tedds dialogs have context sensitive help. To see this simply click the Help button in the dialog.

We also run training courses in most locales, for further information on availability contact the Tedds support team in your region, simply click the Support icon in any of Tedds’ automated calculations.

Bylo to užitečné?
Předchozí
Další