Vous êtes sur la page 1sur 139

Altair HyperGraph 2D 2019

Tutorials

altairhyperworks.com
Altair HyperGraph 2D 2019 Tutorials p.1

Contents
Intellectual Property Rights Notice ........................................................................................ 2
Technical Support .............................................................................................................................. 6
Accessing the Model Files .....................................................................................................8
Plotting Basics ...........................................................................................................................9
HG-1000: Plotting XY Data .................................................................................................................. 10
HG-1010: Changing Curve Display Attributes ..................................................................................... 22
HG-1011: Perform Math on Curves Using the Plot Browser .............................................................. 28
HG-1020: Modifying Plots ................................................................................................................... 37
HG-1021: Modifying Plots with the Plot Browser ............................................................................... 43
HG-1030: Referencing and Filtering Curves ........................................................................................ 61
HG-1040: AVD Diagram Using Unit Scaling and Plot Browser ............................................................ 68
HG-1050: Mouse Over - Inspect Mode ............................................................................................... 76
Advanced Curve Manipulation .......................................................................................... 90
HG-2000: Evaluating Curve Data......................................................................................................... 91
HG-2010: Creating a Plot Macro ......................................................................................................... 95
More Plotting .......................................................................................................................... 102
HG-3000: Working with Bar Charts ................................................................................................... 103
HG-3010: Working with Complex Plots ............................................................................................ 107
HG-3020: Working with Polar Plots .................................................................................................. 112
Templates ................................................................................................................................ 117
HG-4000: Creating an Export Template ............................................................................................ 118
Customization ........................................................................................................................ 124
HG-5010: Customizing the Environment .......................................................................................... 125

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.2

Intellectual Property Rights Notice


Copyrights, Trademarks, Trade Secrets, Patents & Third Party Software Licenses

Altair HyperGraph 2D 2019 Copyright 1995-2019


The Platform for Innovation™

Altair Engineering Inc. Copyright © 1986-2019. All Rights Reserved.

Note: Pre-release versions of Altair software are provided ‘as is’, without warranty of any
kind. Usage of pre-release versions is strictly limited to non-production purposes.

Altair HyperWorks™ - The Platform for Innovation™


Altair AcuConsole™ ©2006-2019
Altair AcuSolve™ ©1997-2019
Altair ElectroFlo™ ©1992-2019
Altair ESAComp™ ©1992-2019
Altair Feko™ ©1999-2014 Altair Development S.A. (Pty) Ltd.; ©2014-2019 Altair
Engineering Inc.
Altair Flux™ ©1983-2019
Altair FluxMotor™ ©2017-2019
Altair HyperCrash™ ©2001-2019
Altair HyperGraph™ ©1995-2019
Altair HyperLife™ ©1990-2019
Altair HyperMesh™ ©1990-2019
Altair HyperStudy™ ©1999-2019
Altair HyperView™ ©1999-2019
Altair Virtual Wind Tunnel™ ©2012-2019
Altair HyperXtrude™ ©1999-2019
Altair MotionSolve™ ©2002-2019
Altair MotionView™ ©1993-2019
Altair Multiscale Designer™ ©2011-2019
Altair OptiStruct™ ©1996-2019
Altair Radioss™ ©1986-2019
Altair SimLab™ ©2004-2019
Altair SimSolid™ ©2015-2019
Altair nanoFluidX™ ©2013-2018 Fluidyna GmbH, © 2018-2019 Altair Engineering Inc.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.3

Altair ultraFluidX™ ©2010-2018 Fluidyna GmbH, © 2018-2019 Altair Engineering Inc.


Altair WinProp™ ©2000-2019;
Altair ConnectMe™ ©2014-2019;

Plus other products from the Altair solidThinking Platform.

Altair Packaged Solution Offerings (PSOs)


Altair Automated Reporting Director™ ©2008-2019
Altair GeoMechanics Director™ ©2011-2019
Altair Impact Simulation Director™ ©2010-2019
Altair Model Mesher Director™ ©2010-2019
Altair NVH Director™ ©2010-2019
Altair Squeak and Rattle Director™ ©2012-2019
Altair Virtual Gauge Director™ ©2012-2019
Altair Weight Analytics™ ©2013-2019
Altair Weld Certification Director™ ©2014-2019
Altair Multi-Disciplinary Optimization Director™ ©2012-2019

Altair solidThinking - Where Innovation Begins™


Altair Inspire™ ©2009-2019 including Altair Inspire Motion and Altair Inspire Structures
Altair Inspire™ Extrude-Metal ©1996-2019 (formerly Click2Extrude®-Metal)
Altair Inspire™ Extrude-Polymer ©1996-2019 (formerly Click2Extrude®-Polymer)
Altair Inspire™ Cast ©2011-2019 (formerly Click2Cast®)
Altair Inspire™ Form ©1998-2019 (formerly Click2Form®)
Altair Inspire™ Mold ©2009-2019 (initial release-Q2 2019)
Altair Inspire™ Studio ©1993-2019 (formerly ‘Evolve’)
Altair Compose™ ©2007-2019 (formerly solidThinking Compose®)
Altair Activate™ ©1989-2019 (formerly solidThinking Activate®)
Altair Embed™ ©1989-2019 (formerly solidThinking Embed®)
• Altair Embed SE™ ©1989-2019 (formerly solidThinking Embed® SE)
• Altair Embed/Digital Power Designer ©2012-2019
Altair SimLab™ ©2004-2019
Altair 365™ ©1994-2019

Altair PBSWorks™ - Accelerating Innovation in the Cloud™


Altair PBS Professional™ ©1994-2019

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.4

Altair Control™ ©2008-2019; (formerly PBS Control)


Altair Access™ ©2008-2019; (formerly PBS Access)
Altair Accelerator™ ©1995-2019; (formerly NetworkComputer)
Altair Accelerator Plus™©1995-2019; (formerly WorkloadXelerator)
Altair FlowTracer™ ©1995-2019; (formerly FlowTracer)
Altair Allocator™ ©1995-2019; (formerly LicenseAllocator)
Altair Monitor™ 1995-2019; (formerly LicenseMonitor)
Altair Hero™ ©1995-2019; (formerly HERO)
Altair Software Asset Optimization™ (SAO) ©2007-2019

Note:

Compute Manager™ ©2012-2017 is now part of Altair Access

Display Manager™ ©2013-2017 is now part of Altair Access

PBS Application Services™ ©2008-2017 is now part of Altair

Access PBS Analytics™ ©2008-2017 is now part of Altair Control

PBS Desktop™ ©2008-2012 is now part of Altair Access, specifically Altair Access
desktop, which also has Altair Access web and Altair Access mobile

Altair SmartWorks™ - Innovation Intelligence®


Altair SmartCore™ ©2011-2019
Altair SmartEdge™ ©2010-2019
Altair SmartSight™ ©2014-2019
Altair intellectual property rights are protected under U.S. and international laws
and treaties. Additionally, Altair software is protected under patent #6,859,792
and other patents pending. All other marks are the property of their respective
owners.

ALTAIR ENGINEERING INC. Proprietary and Confidential. Contains Trade Secret


Information.

Not for use or disclosure outside of Altair and its licensed clients. Information
contained in Altair software shall not be decompiled, disassembled, “unlocked”,
reverse translated, reverse engineered, or publicly displayed or publicly
performed in any manner. Usage of the software is only as explicitly permitted
in the end user software license agreement. Copyright notice does not imply
publication.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.5

Third party software licenses


AcuConsole contains material licensed from Intelligent Light (www.ilight.com) and

used by permission. Software Security Measures:

Altair Engineering Inc. and its subsidiaries and affiliates reserve the right to
embed software security mechanisms in the Software for the purpose of detecting
the installation and/or use of illegal copies of the Software. The Software may
collect and transmit non-proprietary data about those illegal copies. Data
collected will not include any customer data created by or used in connection with
the Software
and will not be provided to any third party, except as may be required by law or
legal process or to enforce our rights with respect to the use of any illegal copies
of the Software. By using the Software, each user consents to such detection and
collection of data, as well as its transmission and use if an illegal copy of the
Software is detected. No steps may be taken to avoid or detect the purpose of
any such security mechanisms.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.6

Technical Support
Altair provides comprehensive software support via web FAQs, tutorials, training classes,
telephone and e-mail.

Altair Support on the World Wide Web


The Altair web site is a valuable online companion to Altair software. Visit
www.altairhyperworks.com for tips and tricks, training course schedules,
training/tutorial videos, and other useful information.

Altair Training Classes


Altair training courses provide a hands-on introduction to our products, focusing
on overall functionality. Courses are conducted at our main and regional offices or
at your facility. If you are interested in training at your facility, please contact
your account manager for more details. If you do not know who your account
manager is, please send an e-mail to training@altair.com and your account
manager will contact you.

Telephone and E-mail


When contacting Altair support, please specify the product and version number you
are using along with a detailed description of the problem. Many times, it is very
beneficial for the support engineer to know what type of workstation, operating
system, RAM, and graphics board you have, so please have that information ready.
If you send an e-mail, please specify the workstation type, operating system, RAM,
and graphics board information in the e-mail.

To contact an Altair support representative, reference the following table or the


information available on the HyperWorks website:
www.altairhyperworks.com/ClientCenterHWSupportProduct.aspx.

Location Telephone E-mail

Australia 64.9.413.7981 anzsupport@altair.com

Brazil 55.11.3884.0414 br_support@altair.com

Canada 416.447.6463 support@altairengineering.ca

China 86.400.619.6186 support@altair.com.cn

France 33.1.4133.0992 francesupport@altair.com

Germany 49.7031.6208.22 hwsupport@altair.de

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.7

India 91.80.6629.4500 support@india.altair.com

1.800.425.0234 (toll free)

Israel israelsupport@altair.com

Italy 39.800.905.595 support@altairengineering.it

Japan 81.3.6225.5830 support@altairjp.co.jp

Malaysia 55.56.58.68.08 aseansupport@altair.com

Mexico 27 21 8311500 mx-support@altair.com

South Africa 82.70.4050.9200 support@altair.co.za

South Korea 34 910 810 080 support@altair.co.kr

Spain 46.46.460.2828 support-spain@altair.com

Sweden 01926.468.600 support@altair.se

United Kingdom 01926.468.600 support@uk.altair.com

United States 248.614.2425 hwsupport@altair.com

For questions or comments about this help system, send an email to connect@altair.com.

In addition, the following countries have resellers for Altair Engineering:


Colombia, Czech Republic, Ecuador, Israel, Russia, Netherlands, Turkey, Poland,
Singapore, Vietnam, Indonesia

Official offices with resellers: Canada, China, France, Germany, India,


Malaysia, Italy, Japan, Korea, Spain, Taiwan, United Kingdom, USA

See www.altair.com for complete contact information.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.8

Accessing the Model Files

Required model files are available online.


1. Go to Altair Connect or Altair Client Center.

2. Enter your user ID and password.

Follow the instructions at the website to obtain login credentials.

3. Select the required file package and download it onto your system.

Note: The files may require unzipping before proceeding with the tutorials. When
extracting zipped files, preserve any directory structure included in the file package.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.9

Plotting Basics

HG-1000: Plotting XY Data


HG-1010: Changing Curve Display Attributes
HG-1011: Perform Math on Curves Using the Plot Browser
HG-1020: Modifying Plots
HG-1021: Modifying Plots with the Plot Browser
HG-1030: Referencing and Filtering Curves
HG-1040: AVD Diagram Using Unit Scaling and Plot Browser
HG-1050: Mouse Over - Inspect Mode

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.10

HG-1000: Plotting XY Data

In this tutorial you will learn how to:


• Plot curves from files.
• Plot multiples curves in one window.
• Plot multiple curves in multiple windows.
• Use the Advanced Plot Options dialog to change the curve and plot attributes

Tools
The Build Plots panel can be accessed one of the following ways:

• Click the Build Plots icon,


OR
• From the menu bar, select Curves > Build Plots.
This panel allows you to construct multiple curves and plots from a single data file. Curves
can be overlaid in a single window or each curve can be assigned to a new window.

The Advanced Options feature on the Build Plots panel allows you to apply many options
at once to the session during plotting. Curves created in this manner are added to the
session in a new layer.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.11

From the Build Plots panel, click Adv. Options to display the Advance Plot Options
dialog.

The Multiple File Plotting dialog allows you to select multiple files with intersecting data
(for example, multiple runs of a particular test) and plot the data from all files
simultaneously in the current HyperGraph session.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.12

To access the Multiple File Plotting dialog, click the Multiple File Plotting button, , on
the Build Plots panel.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.13

Exercise: Creating XY Curves from Data Files

Step 1: Open the demo.dat file.


1. From File menu, select New > Session to clear all contents in the HyperGraph session.

2. Verify XY Plot is selected from the plot type menu, .

3. Click the Build Plots icon, .

4. Click the Open File button, , and select the demo.dat file, located in the plotting
folder.

Step 2: Build multiple curves on a single plot.


1. For X type: select Time.
2. From the Y type: column, select Force.
The data available in the file is listed under the Y Request column.

3. Under Y Request:, click the expansion button, , to easily view the Y Request list.
4. Under Y Request:, press and hold the CTRL key and select REQ/3 Curve 3, REQ/5
Curve 5, REQ/7 Curve 7, and REQ/9 Curve9.
5. Click OK to close the expanded list dialog.
6. Under Y Component:, select X.
7. Click Apply to create the curves on page 1.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.14

The plot’s X axis is labeled Time (the X type), while the y axis is labeled Force (the Y
type). The plot’s title is X (the Y Component name). The curve’s names are the Y
Request names.

Step 3: Build multiple curves on multiple plots.


While in the Build Plots panel, do the following:
1. Verify X type: Time is selected.
2. Under Y type:, leave Force selected.
3. Under Y Request:, leave REQ/3, REQ/5, REQ/7, and REQ/9 selected.
4. Under Y Component:, press the CTRL key and select Y and Z to add them to the
already selected X.
-Or-
Press the SHIFT key and select Z. This selects Z and everything between X and Z.
-Or-
Left click on X and drag the mouse down to Z.
5. From the Layout: drop-down menu, select One plot per Request.
This option creates one plot for each selected Y request. Each plot contains as many
curves as there are selected Y components. The plot’s title is the Y Request name. The
curve’s label is the Y Component name.

6. Click the Page Layout button, , and select the four-window layout from the panel
area.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.15

7. Click Apply to create the plots and curves on page 2.

Step 4: Use Advanced Options to change the curve and plot display
attributes.
While in the Build Plots panel, do the following:
1. Keep the curves you created in Step 3.
2. Click Adv. Options.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.16

The Advanced Plot Options dialog is displayed.

3. To change the page title font, click Page Options on the left side of the dialog.

4. Click in the Font field on the right side of the dialog. Next, click the Font icon, , to
display the Font dialog. Change the font size to 16.
5. Under Plot Options, select Header.
6. Click in the Header field on the right side of the dialog to activate the drop-down menu.
Deselect Y-Component.
This will remove the Y component from the header.
7. Select Horizontal Axis from the left side of the dialog. Click in the Font field on the
right side of the dialog. Next, click the Font icon, , to display the Font dialog.
8. From the Font dialog, change the font size to 12.
9. Repeat steps 7 and 8 the Vertical Axis.
10. Select Legend from the left side of the dialog.
11. From the Font dialog, change the legend font size to 10.
12. Select Curve Options from the left side of the dialog.
13. Click in the Label field on the right side of the dialog to activate the drop-down menu.
Deselect Y Request.
This removes the Y request from the label.
14. Activate Show Prefix.
15. Click the Label Prefix field. Once the cursor is displayed, enter Test 17.
16. Click OK to exit the Advanced Options dialog.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.17

17. From the Build Plots panel, click Apply.

You can also perform filtering on the curve. For this, retain the curve and plot
modifications you just performed.
18. From the Build Plots panel, select Adv. Options.
19. Click Curve Options on the left side of the dialog.
20. Activate Math Expression.
21. Leave Expression for x as is.
22. Enter the following filter in the Expression for y field: saefilt95(u,v,60,5,3).
23. Click OK.
24. From the Build Plots panel, click Apply.
25. From Define Curves panel, , you will see the filter you applied display in the y vector
field:

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.18

Step 5: Use Multiple File Plotting to plot multiples curves in one plot.
1. From File menu, select New > Session to clear all contents in the HyperGraph session.

2. Verify XY Plot is selected from the plot type menu, .

3. Click the Build Plots icon .

4. Next to Data File, click the Multiple File Selection icon, .


The Multiple File Plotting dialog is displayed.

5. Next to Select directory, click the Open File button, , and select the
MultipleFiles folder, located in the plotting folder.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.19

6. You can expand the folders in the File Browser List to display the files contained in
each folder.

You can select files from the File Browser List and click the arrow, , to move them to
the Selected File Set. For this tutorial, we will filter them.
7. In the File-Filter field, enter *T01 and press ENTER. The following files are displayed:

8. While holding the CTRL button, select the first eight files listed under File Browser List
and click the right-facing arrow, , to move them to the Selected File Set.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.20

9. Under Curve Name, leave Prefix activated and select Directory Level 2 from the
drop-down menu.

10. Under Curve Attributes (Color/Style), leave By File selected.


11. Click Select to exit the dialog.
12. From the Build Plots panel, make the following selections:
o For Y Type:, select Global Variables.
o For Y Request:, select Internal Energy and Kinetic Energy.
o For Y Component:, select MAG.
13. From the Layout: drop-down menu, select One plot per Request.

14. Click the Page Layout button, , and select the two-window layout from the panel
area.
15. Click Apply.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.21

16. You can also view the curve Label Prefix and Label information in the Plot Browser.
These fields were edited using the Advanced Options dialog in Step 4.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.22

HG-1010: Changing Curve Display Attributes

In this tutorial you will learn how to:


• Use the Headers/Footers panel
• Change curve attributes
• Use the Notes panel
• Use the Options panel and style sheets

Tools
The Headers/Footers panel can be accessed in one of the following ways:

• Click the Headers/Footers panel icon in the toolbar


Or
• From the menu bar select Annotations > Headers/Footers
The Headers/Footers panel allows you to add headers and footers to your plots, specify
font style and color, position the titles, and turn them on and off.

The Curve Attributes panel can be accessed in one of the following ways:

• Click the Curve Attributes panel icon in the toolbar


Or
• From the menu bar select Curves > Curve Attributes
This panel allows you to change curve attributes such as line style, color, and weight as well
as symbol style and color.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.23

The Options panel can be accessed in one of the following ways:

• Click on the Options panel icon,


Or
• From the menu bar select Preferences > Options
This panel allows you to change the color of a XY plot window’s background, frame, grid
lines, and zero line.

The Notes panel can be accessed one of the following ways:

• Click on the Notes panel button,


Or
• From the menu bar select Annotations > Notes
This panel allows you to annotate plots. Notes are text boxes placed in plot windows for
labeling points, describing trends, and relating additional curve information. You can create
logic and expression-based notes using Templex.

The Apply Style dialog can be accessed in the following ways:

• Right-click in the plot window and select HG ApplyStyle…

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.24

The Apply Style dialog allows you to quickly apply a plot window’s attributes across all plot
windows on the current page, or on all pages in the plot.

Exercise: Editing Curve Display Attributes

Step 1: Open Session File demo_3.mvw.


1. From the File menu, click Open > Session.
2. From the plotting folder, select the demo_3.mvw file and click Open.

Step 2: Change the header for window 1 to REQ/3 force.


1. Verify that window 1 on Page 2 is active.

2. Click on the Headers/Footers panel icon, .


3. From the Header tab, replace the name REQ/3 curve 3 with REQ/3 force and press
ENTER to apply the change.

4. Change the header font size by clicking the font button, .


5. Change the color of the header from the color palette.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.25

Step 3: Change the line style for the curves in window 1.

1. Click the Curve Attributes icon .


2. From the Curves list, select X, Y, and Z.
3. From the Line Attributes tab, change the thickness of the curves.

Step 4: Change the frame color for window 1 to yellow.

1. Click on the Options panel icon, .


2. From the Color tab, select the option Frame.
3. Select yellow from the color palette.

Step 5: Apply the window and curve display attributes of window 1


to the other plot windows on page 2.
1. In window 1, right-click and select HG ApplyStyle… from the pop-up menu to open the
Apply Style dialog.

2. Select Current page.


3. Activate only the attribute options Plot, Header, and Curves. Deactivate all other
options.
4. Click OK to apply the active attributes to the other plot windows on page 2.

Step 6: Create the note "Max force is {Y} at time {X}" and attach it
to a curve in window 1, on page 2.
1. Activate window 1.

2. Enter the Notes panel, .


3. Click Add to create a new note named Note1.
4. From the Text tab, replace Note1 with Max force is.
5. Under the Text window box, click {Y} to add the Templex string {y} to the note.
6. Append to the note at time and click {X}.
The complete note is "Max force is {y} at time {x}".
7. Click Apply to update the note.
8. From the Attach to tab, select the option Curve to add the note to a curve.
Note: The note automatically attaches to a data point on curve 1 (the X curve). In the
Notes panel, the Curve and Point to which the note is attached is called out. The note’s
{X} and {Y} Templex statements are updated to reflect the data point’s X and Y
values.
9. Click points on any of the curves in window 1 to update the location/curve to which the
note is attached.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.26

Note: The {X} and {Y} values are updated automatically.


10. Under Find point, click the Maximum button, , to attach the note to the curve’s
maximum Y value.

11. With Note1 highlighted in the Notes list, turn off this note by deactivating the Note
box.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.27

Step 7: Create and attach a second note with Templex to a curve.


While in the Notes panel, do the following:
1. Activate window 3.
2. Add a note.
3. On the Text tab, replace Note2 with "curve Y absolute area is
{absarea(p2w3c2.x,p2w3c2.Y)}".
The text in curly braces is a Templex statement.
4. Click Apply to update the note.
5. On the Attach to tab, select the option Curve.
6. Click the Next Curve button until the note is attached to curve 2 (curve Y).

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.28

HG-1011: Perform Math on Curves Using the Plot


Browser

In this tutorial you will learn how to use the Plot Browser to perform the following tasks:
• Perform math on a single curve in the Define Curves panel without creating duplicate
curves
• Apply this math to all other curves in the session via the Plot Browser

Tools
The HyperGraph 2D Plot Browser resides on a tab in the Tab Area sidebar and allows you
to view the HyperGraph 2D plot structure.

The Plot Browser can be turned on or off using the View > Browsers > HyperGraph 2D
> Plot menu options. A check mark indicates that the HyperGraph 2D Plot Browser is
activated for display in the Tab Area.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.29

You can use the Plot Browser tools to search, display and edit entities and their properties
within the current session.
From the Define Curves panel, you can edit existing curves and create new ones. To edit
a curve, it must first be selected either from the curve list or picked from the window.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.30

The X,Y, U, and V vectors are displayed at the top of the Define Curves panel. The data
sources for these vectors are displayed in the text fields. Click the radio button for a vector
or click in the corresponding text box to select that vector for editing. In addition to the
traditional X and Y vectors, you can perform math on curves prior to plotting your data with
the support of u and v vectors. As a result, only one curve is generated in the session,
whereas in the older versions of HyperGraph, this could not be done without an initial curve.
To use math as a data source, from the Define Curves panel, select Source > Math.

Exercise: Perform Math on a Single Curve

Step 1: Open Session File demo_browser.mvw.


1. From the File menu click Open > Session.
2. From the plotting folder, select the demo_browser.mvw file and click Open.

Step 2: Use the Define Curves panel to apply an SAE filter to a curve.
1. From the toolbar, select the Define Curves icon, .
2. Activate the x= radio button.
3. Under Source, select Math.
4. In the x= field, enter u. This applies the u vector to the x vector.
5. Click Apply.
6. Activate the y= radio button.
7. Under Source, select Math.
8. In the y= field, enter v. This applies the v vector attributes to the y vector.
9. Click Apply.
You can now apply math to the y vector.
10. For the y vector, remove the v vector you entered in step 8.
11. With your cursor in the y= field, click Functions....

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.31

12. From the Functions dialog, select saefilt95 and click OK.

13. The saefilt95 function takes six arguments: vector1, vector2, scalar1, scalar2,
scalar3, scalar4.
14. Enter the following text in the function: saefilt95(u,v,60,20,3) and click Apply.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.32

15. The result is a corrupt curve. This is because the function expects the time to be in
seconds, and our curve is in milliseconds.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.33

16. To correct this, you must apply the time vector by 0.001. Enter the following in the y=
field: saefilt95(u*0.001,v,60,20,3).
The result is a properly filtered curve:

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.34

Step 3: Apply the math performed in Step 2 to all other curves in the
session via the Plot Browser.
In this step, you will apply the filter defined in Step 2 to all curves in the session using the
Plot Browser.
1. From the Define Curves panel, highlight the y vector filter you added in step 1 and
press CTRL+C to copy it.
2. From the Plot Browser, select the Curves icon from the top of the browser. This filters
the session information so that only the curve information is displayed in the Plot
Browser.
3. Expand the folders for page 1 (p1: Angular Acceleration) and window 1 (w1:XY Plot)
by clicking the plus button next to each folder.
4. As shown below, right-click on the y vector and select Select All.

All y vectors in the session are selected.


5. Go to the Properties Table at the bottom of the Plot Browser.
6. From the Source drop-down menu, select Math.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.35

7. Notice that all the curves in the graphics area disappear, except for the curve we have
already filtered on the Define Curves panel.

8. Click in the Expression field and paste the filter you copied from the Define Curves
panel and press ENTER.
All curves in the session now contain the same filter and math.

9. It is not required, but you can also apply math to the x vector. Like the steps above,
right-click on the x vector from the Plot Browser and select Select All to select all x
vectors in the session.
10. From the Source drop-down menu, select Math.
11. In the Expression field, enter u.
Now all vectors in the session have the same math.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.36

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.37

HG-1020: Modifying Plots

In this tutorial you will learn how to:


• Work with the Axes panel
• Use the Coordinate Info panel and TextView
• Modify curves
• Create secondary axis and assign curves to them

Tools
The Axes panel can be accessed one of the following ways:

• Click the Axes icon,


Or
• From the menu bar select Annotations > Axes
This panel allows you to add multiple axes to plots. Also, axis attributes such as labels,
color, and scaling can be modified.

To access Convert Units tool, right-click on the plot axis and select Convert Units.
The Convert Units tool allows you to convert the current unit of measure of a horizontal or
vertical axis to another unit of measure. All curves associated with the axis are scaled
accordingly and the axis label is updated to reflect the new unit of measure.

The Coordinate Info panel can be accessed one of the following ways:

• Click the Coordinate Info icon,


Or
• From the menu bar select Curves > Coordinate Info

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.38

This panel allows you to retrieve individual point data on any curve in the active window.
When a point is selected, its data is displayed in the panel.

To access TextView, use the Select Application menu and click TextView, .
The text editor window allows you to view, edit, and save text files, conduct text searches,
change text attributes, and evaluate Templex. With Templex, you can obtain curve data
from the plot window and display the results in text format in the text window
The Modify Curves panel can be accessed in one of the following ways:

• Click the Modify Curves icon,


Or
• From the menu bar select Curves > Modify Curves.
The Modify Curves panel enables you to modify curve data pertaining to a plot. Curves can
be deleted, trimmed, bridged, or hidden within a specified range and orientation.

The Scales Offset and Axis Assignments panel can be accessed in one of the following
ways:

• Click the Scales Offset and Axis Assignments icon,


Or
• From the menu bar select Curves > Scales Offsets and Axis Assignments.
Curve scaling, offsets, and axis assignments can be applied to multiple curves using this
panel.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.39

Exercise: Modify and Interrogate XY Curves

Step 1: Open Session File demo_3.mvw


1. From the File menu click Open > Session.
2. From the plotting folder, select the demo_3.mvw file and click Open.

Step 2: Using the Convert Axis Units tool to scale the Y axis.
1. On page 2, activate window 1.
2. Right-click on the window’s vertical axis and select Convert Units from the pop-up
menu.
The current selection in the Convert Axis Units dialog defaults to Time. This is because
the unit converter did not recognize the Y axis unit.
3. Select Force from the dialog.
− Select From: N from the drop-down menu.
− Select To: kN from the drop-down menu.
4. Click OK to apply the change and close the dialog.
The Y axis’ label is changed from Force to Force (kN). Also, the Y axis numbers and
the curves’ Y data are scaled by 0.001.
5. Open the unit converter again for the same Y axis. Force is now selected as the tool
recognizes the axis’ unit of measure.
6. Click Cancel to close the Convert Axis Units dialog.

Step 3: Change the Y axis label for window 1 to Force


(kiloNewtons)

1. Click the Axes panel icon, .


The Primary axis is highlighted or active in the Axes list.
2. Above the Axes list, select Vertical from the drop-down menu.
3. From the Text tab, change Force (kN) to Force (kiloNewtons) and press ENTER to
apply the change.

Step 4: Creating a Datum Line


1. Activate window 2 on page 2.

2. Click the Datum Lines panel button, .


3. Click Add.
4. Verify that the choice under the selection for Datum is Horizontal.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.40

5. Select the Positon tab.


6. Verify that Axis is set to Primary.
7. For Position, enter the expression sin(90) +100-cos(0) and press ENTER.
8. Click the Line Attributes tab and select a different color for the line.

Step 5: Trim the curves.


1. Activate window 3 on page 2.

2. Click the Modify Curves icon, .

3. To the right of the Curves field, there is a curves button, . Press this button.
The Select Curves dialog is displayed.
4. Under p2:Force-2 select w3: XY plot and click OK.
All curves in window 3 are selected and p2w3c1, p2w3c2, p2w3c3 are displayed in
the Curves text field.
5. Verify the option for Direction is set to Horizontal.
6. Under Range, specify 0.2 for From and press ENTER.
7. Specify 0.95 for To and press ENTER.
8. Under Action, click Trim to remove the data outside of the specified range for the
selected curves.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.41

Step 6: Create a secondary Y axis in a plot window.

1. Click the Add Page icon, .

2. Go to the Build Plots panel, .


3. Open the demo.dat file, located in the plotting folder.
4. Select the option Layout: Use current plot.
5. Create a curve for X type: Time, Y type: Force, Y Request: REQ/3 Curve3, and Y
Component: X.
6. Create a second curve in the same plot window for X type: Time, Y type:
Displacement, Y Request: REQ/33 Curve33, and Y Component: X.

7. Go to the Axes panel, .


8. From the drop-down menu above the Axis list select Vertical.
9. Click Add to create a secondary vertical axis on the plot window’s right side.
An axis with the name Y1 is created and its name is highlighted (active) in the Axis list.
10. In the Axis text field above the Axis list, rename the Y1 axis to disp and press ENTER.
11. On the Text tab, rename the Y1 axis label to Comp x disp and press ENTER.

12. Go to the Scales, Offsets, and Axis Assignments panel, .


13. Verify the curve REQ/33 Curve 33-X is highlighted.
14. Under Axis assignments, click on the Y: drop down, select disp and click Apply.
The secondary vertical axis is assigned to the curve REQ/33 Curve33-x.

15. Click Fit, , to fit the curve to the plot window.

Step 7: In a text editor window using Templex, obtain information


for existing xy curves.

1. Click on the Page Layout button, , and select a two-window layout, .


2. Make the second window active.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.42

3. From the Select Application menu, select TextView, .

4. Type the following text in the text editor window:


Maximum Force is {max(p3w1c1.Y)} Newton
Maximum Displacement is {max(p3w1c2.Y)} meter

5. From the toolbar, click the Edit Text button, .


The Templex statements are evaluated and displayed.
The text editor window is now in non-edit mode.

6. Click the Edit Text button again to go back to edit mode.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.43

HG-1021: Modifying Plots with the Plot Browser

In this tutorial you will learn how to use the Plot Browser to perform the following tasks:
• Modify the following plot attributes
o Header font size
o Legend position and font size
o Axis fonts
• Modify the following curve attributes
o Curve name and prefix
o Line style
o Color
• Add notes attached to curves
o Modify notes in the Notes panel
o Apply these changes to all notes using the Plot Browser

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.44

Tools
The HyperGraph 2D Plot Browser resides on a tab in the Tab Area sidebar and allows you
to view the HyperGraph 2D plot structure.

The Plot Browser can be turned on or off using the View > Browsers > HyperGraph 2D
> Plot menu options. A check mark indicates that the HyperGraph 2D Plot Browser is
activated for display in the Tab Area.
You can use the Plot Browser tools to search, display and edit entities and their properties
within the current session.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.45

Exercise: Modify the Plot and Curve Attributes

Step 1: Open Session File demo_browser.mvw.


1. From the File menu click Open > Session.
2. From the plotting folder, select the demo_browser.mvw file and click Open.

Step 2: Modify the header font size.


1. From the Plot Browser tab, click the Headers/Footers icon, , from the top of the
browser.

These icons allow you to filter the data that is displayed in the Plot browser. For
example, by clicking the Headers/Footers icon, only the header and footer information
for each curve in your session is displayed in the browser.
2. Expand the folders for page 1 (p1: Angular Acceleration), window 1 (w1:XY Plot)
and Header by clicking the plus button next to each folder.
3. Right-click on Header and select Select All.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.46

This action selects all the headers for each curve listed in the plot browser. By doing
this, you can modify a header attribute only once, but it will be applied to all headers.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.47

4. From the Properties Table at the bottom of the Plot Browser, select the font setting
field next to Primary Font Settings.

The Font Selector dialog is displayed.


5. Change the Font Size to 20 and click OK.
The font size change is applied to all headers.

Step 3: Modify the legend font size and change the legend position.

1. From the Plot Browser tab, click the Legends icon, , from the top of the browser.

These icons allow you to filter the data that is displayed in the Plot Browser. For
example, by clicking the Legends icon, only the legend information for each curve in
your session is displayed in the browser.
2. Expand the folders for page 1 (p1: Angular Acceleration) and window 1 (w1:XY Plot)
by clicking the plus button next to each folder.
3. Right-click on Legends and select Select All.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.48

This action selects all legends for each curve listed in the plot browser. By doing this,
you can modify a legend attribute only once, but it will be applied to all curve legends.

4. From the Properties Table at the bottom of the Plot Browser, select the Font Settings
field.

The Font Selector dialog is displayed.


5. Change the Font Size to 12 and click OK.
The font size change is applied to all legends.
6. Next, we will change the legend placement in the graphics window.
7. From the Legend Placement drop-down menu, select Inside-Right-Bottom corner.
The legend is moved to that position.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.49

Step 4: Modify the axis font size.

1. From the Plot Browser tab, click the Axes icon, , from the top of the browser.

These icons allow you to filter the data that is displayed in the Plot Browser. For
example, by clicking the Axes icon, only the axes information for each curve in your
session is displayed in the browser.
2. Expand the folders for page 1 (p1: Angular Acceleration) and window 1 (w1:XY Plot)
by clicking the plus button next to each folder.
3. Right-click on the icon for the horizontal primary axis and select Select All.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.50

This action selects all horizontal axes for each curve listed in the plot browser. By doing
this, you can modify a horizontal axis attribute only once, but it will be applied to all
horizontal axes.

4. From the Properties Table at the bottom of the Plot Browser, select the setting next to
the Font Settings field.
The Font Selector dialog is displayed.
5. Change the Font Size to 12 and click OK.
The font size change is applied to all horizontal axes.
6. Repeat steps 1-5 for the primary vertical axis.
The font size change is applied to all vertical axes.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.51

Step 5: Modify the curve name.


1. From the filter icons at the top of the Plot Browser, select the Curves icon, .
2. Expand the folders for page 1 (p1: Angular Acceleration) and window 1 (w1:XY Plot)
by clicking the plus button next to each folder.
3. Right-click on the curve name c1:50th% Hybrid 3 - LOWER TORSO -Res ang and
select Select All.
All curve names in the Plot Browser are selected.
The curve names contain the request and component information.

Next, remove the Y Request from the curve name.


4. From the Properties Table, click the Label drop-down menu and deselect the Y
Request option.
The curve names shown in the graphics area now only contain the Y Component name.

5. Activate Show Label Prefix.


6. In the Label Prefix field, enter Test 17.
The prefix Test 17 is added to the curve name label for all plots.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.52

Step 6: Modify the curve line style and color.


In this step, you will change the curve line style for all curves that contain the components
XYZ.
1. Keep the Curves icon selected at the top of the Plot Browser.

2. Click the Add Filter icon, , to add a filter to the Filter Area.
3. From the Filter Name drop-down menu, select Display Name.

4. In the Value column, enter Res.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.53

HyperGraph searches for all the curve names that contain a resultant and display only
those in the Plot Browser.

5. Right-click on the first curve listed in the Plot Browser and select Select All.
6. Delete the filter you just added by clicking the Delete Filter icon, .

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.54

The Plot Browser displays all the other curve names that contain something other than a
resultant.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.55

7. Click the Select Reverse icon, , to deselect the curves with resultant in the name
and SELECT the curves with component in the name.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.56

8. From the Properties Table, select the Line Style drop-down menu and select the
dashed line style.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.57

The line style is changed to a dashed line style for all curves with component in the
curve name. The curve name that contains the resultant remains a solid line.

9. To change the line color of only the resultant curve, click the Select Reverse icon

again, , to deselect the component curves from the Plot Browser and select the
resultant curve.
10. From the Properties Table, select the Line Color color square and select the color
black from the color palette.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.58

Only the resultant curve changes to black.

Step 7: Add and modify notes.


1. Keep the Curves icon selected at the top of the Plot Browser.

2. Click the Add Filter icon, , to add a filter to the Filter Area.
3. From the Filter Name drop-down menu, select Display Name.
5. In the Value column, enter Res.
The Plot Browser displays only the curve names with resultant in the name.
5. Right-click on the first curve name listed in the Plot Browser and select Select All to
select all the resultant curves in the Plot Browser.
6. Again, right-click on the first curve listed in the Plot Browser and select Single Curve
Math > Max Note.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.59

This adds a note to the maximum value of each curve in the session.

Next, you will use the Notes panel to modify the note.

7. From the toolbar, click the Notes icon, .


8. In the Text tab, change Max:{Y} to this: Max of {label} = {Y} and click Apply.
The note now displays the label information.

9. You can further edit the note display by added quotes around {label}, like this: Max of
"{label}" = {Y}. Click Apply.

10. Edit the note one more time by adding the time to it, like this:

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.60

The "ms" displays the time in milliseconds.

Next, you will apply the note text to all the curves in the session using the Plot Browser.
11. From the Notes panel, highlight the note text and press CTRL+C to copy the text.
12. Click the Notes icon on the Plot Browser.
13. Right-click on Note 1 and select Select All to select all notes in the session.
14. From the Properties Table, click in the Text field.
The Note Text dialog is displayed.

16. Press CTRL+V to insert the text you copied from the Notes panel and click OK.
All max notes now have the same text string applied to them.

17. Click the Font Settings font icon and change the note font size to 12.
All notes in the session are displayed with the same note attributes.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.61

HG-1030: Referencing and Filtering Curves

In this tutorial you will learn how to reference and filter curves.

Tools
The Define Curves panel can be accessed in one of the following ways:

• Click on the Define Curves icon,


Or
• From the menu bar select Curves > Define Curves.
This panel allows you to edit existing curves and create new ones. The Define Curves
panel also provides access to the program's curve calculator.

Referencing Curve Vectors in HyperGraph


X and y vector expressions can reference any curve vector in the session. A curve vector
reference defines the x or y vector (values) by page, window, and curve number. An
example of a curve vector reference is p2w3c4.x, where:

p2 is page 2

w3 is window 3

c4 is curve 4

x is the vector

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.62

There are two common methods to specify curve vector references:

Pick a curve in a plot For the x = SHIFT and pick the curve to get the curve x vector reference
window input field.

SHIFT + CTRL and pick the curve to get the curve y vector
reference

for y = input SHIFT and pick the curve to get the curve y vector reference
field.

SHIFT + CTRL and pick the curve to get the curve x vector
reference

Select a curve vector reference from the Curves… dialog, which is accessed from the Define Curves
panel.

Exercise: Filtering a curve from the Define Curves


panel

Step 1: Open Session File saefilter.mvw


1. From the File menu, click Open > Session.
2. From the plotting folder, select the saefilter.mvw file and click Open.

Step 2: Filter a curve using the SAE J211/1 filter.

1. Click on the Define Curves panel button, .


2. Click Add and add a new curve.
3. Change the name of the new curve from Curve 1 to SAE J211/1 FILTER in the text box
over the curve list.
4. Check the radio button for Math under Source:.
5. Verify that the x vector is active.
6. Hold the SHIFT key and click on the curve in the plot window.
The x = curve reference is p1w1c1.x.
7. Click the y = field, and click Filter… from the panel menu to display the Filter dialog.
8. Select the filter class SAE J211/1 from the Filter Class drop-down menu.
9. Select Filter Class: 60, Padding: Mirror padding, and Direction: Fwd-Back.
10. Click OK to complete the selection and close the Filter dialog.
11. Hold down the SHIFT + CTRL keys, then select the existing curve.
12. The x vector curve reference is entered in the saefilt95 function.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.63

13. Hold down the SHIFT key and select the curve again.
Note: the curve's y vector is referenced in the saefilt95 function. The y = field should
read: saefilt95(p1w1c1.x,p1w1c1.y,60,1,3).
14. Click Apply to create the filtered curve.

Exercise: Filtering a curve using the Vehicle Safety


Tools and Plot Macros panel

Step 1: Load the ANGACC file.


1. From the Options panel, verify that Enable Unit Scaling is selected.

2. From the toolbar, click Add Page, .


3. From the Built Plots panel, load the ANGACC file, located in the ..\plotting\madymo
folder.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.64

4. Click the expand button, , to display the Y Requests dialog. Click All to select all
the requests listed.

5. Click All to select all the requests listed. Click OK to close the dialog.
6. Under Y Component, click All to select all components in the list.
7. From the Layout drop-down menu, select One Plot Per Request.
8. Click the window layout icon and choose the two-window layout.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.65

9. Click Apply.
The following plots are displayed:

10. Click the Next Page icon, , to view the other curves on pages 4 and 5 that were
created in step 8.

Step 2: Filter a curve using the SAE J211/1 filter through the Vehicle
Safety Tools menu.
1. Select File > Load > Preference File.
2. From the Preferences dialog, select Vehicle Safety Tools and click Load.
The Vehicle Safety Tools menus are displayed in the menu bar.
3. From the Filter menu, select SAE General > SAE (J211, Mar 1995) > Mirror
Padding > Fwd-Back.
The Plot Macros panel is displayed.

4. For Filter class, change the value to 180.


Note: Time scaling is done automatically since Enable Units is activated from the Options
panel.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.66

5. To select all the curves at once, double-click Curve to display the Select Curves dialog.

6. To select the curves on pages 3-5, select p3: Angular Accelearation, hold down the
SHIFT key, and select Z-comp ang. acc. under p5: Angular Acceleration.
All of the master references are inserted into the Curve field.

7. Under Layout, select Hide Input Curves.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.67

8. Click Apply.
All curves are filtered.

9. Click to view the remaining curves on pages 4 and 5.


10. The automatic unit scaling allows you to change the time from milliseconds to seconds,
for example, without changing the curves.
11. Right-click from the X axis and from the Convert Units menu, select s. The curves
remain the same as when Time was set to milliseconds.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.68

HG-1040: AVD Diagram Using Unit Scaling and Plot


Browser

In this tutorial you will learn how


• Create an Acceleration Velocity Displacement plot in one window
• Use the unit scaling feature for a plot.
• Use the Plot Browser to change the appearance of a plot, such as modifying the axes
names, unit type and curve line color.

Tools
The Build Plots panel can be accessed one of the following ways:

• Click the Build Plots icon,


OR
• From the menu bar select Curves > Build Plots.
This panel allows you to construct multiple curves and plots from a single data file. Curves
can be overlaid in a single window or each curve can be assigned to a new window.

The Plot Browser resides on a tab in the Tab Area sidebar and allows you to view the
HyperGraph 2D plot structure. The Plot Browser tools allow you to search, display and edit
entities and their properties within the current session. The plot structure is viewed as a
flat, listed tree structure within the browser. However, if the plot has a hierarchy, then the
Plot Browser accommodates this hierarchical structure.
From the Plot Browser, you can select entities one at a time or several simultaneously using
common selection techniques. You can also use the browser's context-sensitive menus to
select entities. Using the Plot Browser, you can perform many of the operations available
in the HyperGraph 2D panels, thus allowing you to modify your plot and curve properties in
one location.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.69

Step 1: Clear any units association and enable unit scaling.


1. From the Tools menu, select Reset Units Association.
The Reset Units Association dialog is displayed.

2. If activated, click Reset Units to clear any unit associations. If Reset Units is grayed
out, you don't need to do anything.
3. Click Close to close the dialog.

4. From the toolbar, click the Options icon, .


The Options panel is displayed.

5. From the Options dialog, verify that Enable Unit Scaling and Show Units Dialog are
activated.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.70

Step 2: Open the nodout file.


1. From File menu, select New > Session to clear all contents in the HyperGraph session.

2. Verify XY Plot is selected from the plot type menu, .

3. Click the Build Plots icon, .

4. Click the Open File icon, , and select the nodout file, located in the plotting folder.

Step 3: Plot the curves and set the curve units.

1. Return to the Build Plots panel, .


2. For the X Type: select Time.
3. From the Y Type: column, select Node Data.
The data available in the file is listed under the Y Request column.
4. From the Y Request: column, press and hold the CTRL key and select Nodal Point
2500001 and Nodal Point 2500002.
5. From the Y Component: column, select X Displacement, X Velocity and X
Acceleration
6. From the Layout drop-down menu, select Use Current Plot.
7. Click Apply to create the curves on page 1.
The Units Profile dialog is displayed.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.71

8. From the Units Profile dialog, select the C radio button and click OK.
This sets the Length, Time and Mass units for the file to millimeter, milliseconds, and
kilograms, respectively.

9. Click OK to close the Select Units Profile dialog.


The curves are plotted and the units for the vertical and horizontal axis are changed to
millimeters and milliseconds, respectively.
10. Click Apply.
The displacement, velocity and acceleration are plotted. Notice that two additional axes
have been added to the right of the window to accommodate the velocity and
acceleration data (use your plot with your default setting.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.72

Step 4: Modify the plot's appearance and rename an axis.


In this step, you will use the Plot Browser to change the appearance of the plot.

1. From the Plot Browser, click the Axes icon, .

2. Expand the folders for page 1 (p1: Node Data), and window 1 (w1:XY Plot) by clicking
the plus button next to each folder.
3. The following axes are listed under w1:XY Plot: X1, Y1, Y2, and Y3.
4. Select the X1 axis.
5. From the Properties Table, located in the bottom portion of the Plot Browser, click the
color palette next to Color and select black.

6. Select the Y1 axis


7. From the Properties Table, click the color palette next to Color and select red.
8. Change the color for the Y2 axis to blue and change the color for Y3 to pink.
Next, you will rename the axes using the Plot Browser.
9. From the Plot Browser, select the X1 axis.
10. From the Properties Table, click the Name field and enter the name Displacement.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.73

11. Repeat steps 9 and 10 for the Y1, Y2, and Y3 axes. Rename them Node Data,
Velocity and Acceleration, respectively.
The new vertical axes names for X1, Y1, Y2 and Y3 are shown below:

Step 5: Modify the curve line color.


1. From the Plot Browser, click the Curve filter icon, .
2. Expand the folders for page 1 (p1: Node Data) and window 1 (w1:XY Plot) by clicking
the plus button next to each folder.
3. Select the two Displacement curves from the list for nodal points 2500001 and
2500002
4. From the Properties Table, next to Line Color, click the color palette and select black.
This changes the color of those two curves to black.
5. From the same expanded w1:XY Plot folder, select the X Velocity curves.

6. From the Properties Table, change their line color to red.


7. Select the X Acceleration curves and change their line color to blue.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.74

8. From the Plot window, right-click on the horizontal axis to display the following context
menu:

9. Select Convert Units and change the unit type from milliseconds to seconds (s).
10. From the Plot window, right-click in the vertical axis and select Convert Units. Change
the distance from millimeters to meters.
11. Repeat step 8, but for the right-side Velocity axis. Change the speed from
millimeters/milliseconds to mph.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.75

12. You can also change the unit type for a curve by right-clicking on the curve and selecting
Enable/Change Curve Unit.
The Enable/Change Curve Unit dialog is displayed.

13. From the YVector, select the right-most drop-down menu and change the unit from
millimeter/millisecond to kph.
14. Click OK.
The final plot window is shown below:

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.76

HG-1050: Mouse Over - Inspect Mode

In this tutorial you will learn how to use these features:


• Inspect mode, which increases the screen area of the plot.
• Pre-highlight plot attributes (curves, legends, axes, and headers/footers) in gold when
you move the mouse pointer over them.
• Display data point markers on a pre-highlighted curve.
• Highlight curves when selected from the Plot Browser, even when the curve is not in
the active window. You can select one curve only from the Plot Browser or multiple
curves; either way they are highlighted in gold in the plot(s).
• Use Inspect mode with multiple axes.

Tools
The Build Plots panel can be accessed one of the following ways:

• Click the Build Plots icon,


OR
• From the menu bar, select Curves > Build Plots.
This panel allows you to construct multiple curves and plots from a single data file. Curves
can be overlaid in a single window or each curve can be assigned to a new window.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.77

Exercise: Explore the mouseover features.

Step 1: Open the nodout file.


1. From File menu, select New > Session to clear all contents in the HyperGraph session.

2. Verify XY Plot is selected from the plot type menu, .

3. Click the Build Plots icon, .

4. Click the Open File button, , and select the nodout file, located in the
../plotting/dyna/ folder.

Step 2: Plot the curves.


1. From the Build Plots panel, select Nodal Points 2500001-2500004 listed under Y
Request.
2. From the Y Component column, select X, Y, Z and Resultant Displacement.
3. Under Layout, select One Plot Per Request. Select the four window layout.
4. From the toolbar, select the Options panel. Verify that Show Units Dialog is enabled.
5. Return to the Build Plots panel and click Apply.
The Units Profile dialog is displayed.
6. Select option C and click OK.
The following plots are displayed in the graphics area.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.78

Step 3: Use Inspect Mode to enlarge the plot and display data point
values
1. In the top-left plot, double-click in the plot area to enlarge the plot.
Double-clicking on an empty space in the plot (not on an entity) increases the screen
area of the plot by hiding the panels and any other windows on the page. This is
referred to as the Inspect Mode. In this case, since the plot was part of a multi-window
layout, the other windows are also hidden so that the entire plot area is available for the
plot that you selected.
Double-click in the white space of the plot again to reduce its size and go back to the
four-window layout. However, for this step, leave the plot in its enlarged state.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.79

2. When you move the mouse over a curve before clicking on it, it is highlighted in yellow,
similar to the non-inspect mode.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.80

3. Click on the purple curve.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.81

The curve becomes active. It displays its original color and the other curves become
transparent.
4. Drag the mouse pointer along the curve to display the values of each point along the
curve.

HyperGraph only displays the value of the data points on a curve when the overlap is
less than 50%. If it is more than that, only one value at a time is displayed.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.82

5. Move the mouse pointer over the other transparent curves. Notice they are highlighted
in full color.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.83

6. Click on the blue curve to make it active. The other three curves are now transparent.

7. If you hover over the axes, legend, or headers/footers in the active window, they are
also highlighted in yellow.
8. From the Plot Browser, you can select curves for multiple plots even if they aren't in the
active plot (the active plot is surrounded by a blue border). The selected curves are
highlighted in yellow.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.84

In the image below, the curves selected from the Plot Browser (in blue) are highlighted
in yellow in each of the four plots on the right. The active plot is displayed on the top-
left and is surrounded by the blue rectangle.

9. Double-click in the white space of the plot again to return to normal (non-inspect) mode.

Step 4: Legend Handling


1. Click the Add Page icon, .
2. From the Build Plots panel, select Nodal Points 2500001-2500004 listed under Y
Request.
3. From the Y Component column, select X, Y, Z and Resultant Displacement.
4. Under Layout, select Use Current Plot.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.85

5. Click Apply.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.86

6. Double-click in the plot's white space to switch to Inspect mode.


7. Click on any curve in the plot. Notice that when the curve is selected and active, the
legend only displays the selected curve.

8. Return to normal mode.


9. Go to the Define Curves panel.
10. From the plot window, click on any curve.
The curve you selected is also automatically selected in the Curve list in the Define
Curves panel.
When you click on a highlighted curve, that curve is displayed at the top in the legend,
even if the legend contains several curve names. The active curve always moves to the
top of the legend.
Similarly, if you go to the Coordinate Info panel, when you select a curve from the plot
window, it is also selected in the panel's point list.
11. To restore the original legend order, click inside any empty space.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.87

Step 5: Inspect mode and multiple axes.

1. Click the Add Page icon, .


2. From the Build Plots panel, select Nodal Points 2500001 listed under Y Request.
3. From the Y Component column, select the following:
X, Y, Z and Resultant Displacement
X, Y, Z and Resultant Velocity
X, Y, Z and Resultant Acceleration
4. Under Layout, select Use Current Plot.
5. Click Apply.
6. Notice there are three axes:

7. Double-click in the white space to go into inspect mode.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.88

8. Click on any axis. Notice that when you click on an axis, you can only highlight the
curves that belong to that axis.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.89

9. If you click the curve first, the axis automatically highlights. In the image below, the
curve selected belongs to the Acceleration axis.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.90

Advanced Curve Manipulation

HG-2000: Evaluating Curve Data


HG-2010: Creating a Plot Macro

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.91

HG-2000: Evaluating Curve Data

In this tutorial you will learn how to:


• Reference curves
• Create curves using math expressions
• Create curves by using pre-defined functions
• Use the freeze option

Tools
The Define Curves panel can be accessed in one of the following ways:

• Click the Define Curves icon,


Or
• From the menu bar select Curves > Define Curves.
This panel allows you to edit existing curves and create new ones. The Define Curves
panel also provides access to the program's curve calculator.

Referencing Curve Vectors in HyperGraph


X and Y vector expressions can reference any curve vector in the session. A curve vector
reference defines the x or y vector (values) by page, window, and curve number. An
example of a curve vector reference is p2w3c4.x, where:

p2 is page 2

w3 is window 3

c4 is curve 4

x is the vector

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.92

There are two common methods to specify curve vector references:

Pick a curve in a plot For the x = SHIFT and pick the curve to get the curve x vector reference
window input field

SHIFT + CTRL and pick the curve to get the curve y vector
reference

for y = input SHIFT and pick the curve to get the curve y vector reference
field

SHIFT + CTRL and pick the curve to get the curve x vector
reference

Select a curve vector reference from the Curves… dialog, which is accessed from the Define Curves
panel.

Freeze Option
The Freeze option is available when a vector’s source is Math. This option allows you to
break the association of the dependent curve(s) from their parent curve, which allows
modifications to the parent curve without updating the dependent curve(s).

Curve Dependencies browser


To access the browser, right-click a curve and select View Dependencies. The selected
curve displays from the context menu.

Exercise: Creating XY Curves by Referencing


Existing Curve Vectors

Step 1: Open Session File democ2.mvw.


1. From the File menu, click Open > Session.
2. Select the democ2.mvw file, located in the plotting folder, and click Open.

Step 2: Practice referencing curve vectors by selecting curves from


the plot window.
1. Make window 3 (lower left window) on page 2 active by clicking on it.

2. Expand window 3 by clicking the Expand Window button, .

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.93

3. Go to the Define Curves panel, .


The Curve list displays the names of the four curves in window 3.
4. Click Add under the curve list.
5. Verify the x = radio button is selected.
6. Select Math under Source of the curve to be created.
This defines the x vector of the new curve to be a math function. In this case, it will
simply be set equal to the x vector of an existing curve.
7. Hold the SHIFT key and pick the dark red curve (Req/5 Curve 5).
The x = curve reference is p2w3c2.x. This defines the page 2, window 3, curve 2, x
vector.
8. Clear the entry in the x = field.
9. With the x = field still active, hold the SHIFT + CTRL keys and pick the same curve.
The x = curve reference is p2w3c2.y. This defines the page 2, window 3, curve 2, y
vector.
10. From the curve list, select Curve1 and click Cut.

11. Return to the page’s original layout by clicking .

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.94

Step 3: Create a new curve with a math expression for its y vector.
1. Click Add to create a new curve named Curve2.
2. Verify the x = radio button is selected.
3. Select Math for the Source:.
4. Click Curves… to open its dialog.
− Select p2: Plot 2.
− Select w3: Plot.
− Select c2: Req/5 Curve 5.
5. Click Select to complete the selection
The result is the same as when the curve was picked from the graphics area; the x curve
reference is p2w3c2.x.
6. Click the y = radio button.
7. Hold the SHIFT key and pick any curve in window 3.
Notice in the y = field is the reference for the y vector of the picked curve.
8. Append the character + to the string in the y = field.
9. Hold the SHIFT key and select any other curve in window 3.
Notice the y = field now has two y vectors separated by the + sign.
10. Click Apply to create the new curve.
The new curve appears in window 3 and is the sum of the two y vectors.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.95

HG-2010: Creating a Plot Macro

In this tutorial you will learn how to:


• Create a plot macro
• Append and use the Vehicle Safety Tools

Tools
The Plot Macro panel can be accessed in one of the following ways:

• Click the Plot Macros icon,


Or
• From the menu bar select Curves > Plot Macros
This panel allows you to create macros that produce curves and notes for plots. Plot macros
can be used to capture and replay frequently used curve operations such as adding two
curves together and filtering curves.

Defining a plot macro consists of two steps:


1. Define the parameters (variables of type curve or scalar) needed to create the curve.
2. Define the curve using the parameters.
Plot macros created from the Plot Macros panel are saved to the session file.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.96

To load Vehicle Safety Tools:


1. From the menu bar select File > Load > Preference File.
2. Select the Vehicle Safety Tools preference file and then click Load.

The vehicle safety tools (VST) are a collection of over 200 macros, Templex functions, and
external functions used by vehicle safety engineers. On appending the VST file, seven new
menus that contain the macros and functions are displayed on the menu bar: Math, Filter,
Units, Injury, Misc, Transforms and Safety Tools.

Selecting a tool (macro) from one of these menus takes you to the Plot Macros panel.

Context Sensitive Menu


When the VST are loaded, you can access its macros by right-clicking on a curve and
selecting a macro from the pop-up menu. The pop-up menu can be customized.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.97

Exercise: Create a Plot Macro for the SAE J211


Filter Function

Step 1: Define the macro’s first parameter.


1. Click on the Plot Macros panel icon, .
2. Click Add to create a new macro and open the Edit Plot Macro dialog.
3. On the Parameters tab, click Add to create the first parameter.
A parameter named Paramenter1 is displayed in the Parameters list and is
highlighted.
4. In the Parameter: field, replace the name Parameter1 with raw data curve and then
press ENTER.
5. In the Varname: field, replace the name p_1 with curve and press ENTER.
The variable name references the parameter in the macro's definition.
6. Set the parameter’s Type: to Curve.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.98

Step 2: Define the macro’s second parameter.


1. Click Add to create the second parameter.
2. In the Parameter: field, replace the name Parameter2 with SAE J211/1 filter
class.
3. In the Varname: field, replace the name p_2 with class.
4. Set the parameter’s Type: to Scalar.

Step 3: Define the macro’s third parameter.


1. Add a third parameter.
2. Change the parameter’s name to padding.
3. Change the parameter’s variable name to padding.
4. Verify Type: is set to Scalar.

Step 4: Define the macro’s fourth parameter.


1. Add a fourth parameter.
2. Change the parameter’s name to direction.
3. Change the variable’s name to direction.
4. Verify Type: is set to Scalar.

Step 5: Define the macro’s curve label.


The curve label should be curve.label+" SAE J211/1 "+class.
1. From the Curve tab, click the Label field.
2. From the Parameters list, double-click raw data curve.
curve.label is displayed in the Label field.
3. In the Label field, add +" SAE J211/1 "+.
curve.label+" SAE J211/1 "+ is displayed in the Label field. The + symbol connects
the string of variables and text.
4. From the Parameters list, double-click SAE J211/1 filter class.
curve.label+" SAE J211/1 "+class is displayed in the Label field.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.99

Step 6: Define the curve’s x vector.


The curve’s x vector should be curve.x.
1. Click the X: field.
2. From the Parameters list, double-click raw data curve.
curve.x is displayed in the X: field.

Step 7: Define the curve’s y vector.


The curve’s y vector should be saefilt95(curve.x,curve.y,class,padding,direction).
1. Click in the Y: field.
2. From the Functions: list, double-click saefilt95.
saefilt95(,,,,) is displayed in the Y field.
3. From the Parameters list, double-click raw data curve.
saefilt95(curve.y,,,,) is displayed in the Y field.
4. In the Y field, change curve.y to curve.x.
5. Position the cursor after the first comma.
6. From the Parameters list, double-click raw data curve.
saefilt95(curve.x,curve.y,,,) is displayed in the Y field.
7. Position the cursor after the second comma.
8. From the Parameters list, double-click SAE J211/1 filter class.
saefilt95(curve.x,curve.y,class,,) is displayed in the Y field.
9. Position the cursor after the third comma.
10. From the Parameters list, double-click padding.
saefilt95(curve.x,curve.y,class,padding,) is displayed in the Y field.
11. Position the cursor after the fourth comma.
12. From the Parameters list, double-click direction.
saefilt95(curve.x,curve.y,class,padding,direction) is displayed in the Y field.
13. Close the Edit Plot Macro dialog.
14. In the Macro: field, change the name macro1 to SAE J211/1 filter and press ENTER.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.100

15. Save the session file as SAEJ211_macro.mvw.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.101

Step 8: Apply the SAE J211/1 filter macro.


1. From the menu bar, select File > Open > Session and select the file saefilter.mvw,
located in the plotting folder.
Even though a new session file is opened, the SAE J211/1 filter macro remains in the
session until HyperGraph is closed.
2. Enter the Plot Macros panel.
3. From the Macro list, select SAE J211/1 filter.
4. In the Parameters section of the Plot Macros panel, click the raw data curve field.
5. Hold the SHIFT key and select the curve in the plot window.
p1w1c1 is displayed in the raw data curve field.
6. Enter 60 in the SAE J211/1 filter class field.
7. Enter 1 in the padding field.
8. Enter 3 in the direction field.
9. Verify the option Layout: Place new curves in original plots is active.
10. Deactivate the option Hide input curves.
11. Click Apply to create the filtered curve.
This plot macro can be reused for any number of input curves to quickly repeat the
curve filtering process.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.102

More Plotting

HG-3000: Working with Bar Charts


HG-3010: Working with Complex Plots
HG-3020: Working with Polar Plots

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.103

HG-3000: Working with Bar Charts

In this tutorial, you will learn how to create bar charts by entering values, importing a data
file, or specifying a mathematical expression.

Tools
When the plot type is set to Bar Charts ( ), the Define Curves panel allows you to add
and edit bar charts in the active plot window. It can be accessed one of the following ways.

• Click on the Define Curves panel button, , on the toolbar


Or
• From the menu bar select Curves > Define Curves

Bar charts are comprised of data and categories. Data can be entered as values, read from
an external file, or defined as a mathematical expression.

Exercise: Create Bar Charts

Step 1: Create a bar chart by entering values in the Define Curves


panel.
Enter the values 563.35, 567.22, and 423.51.
1. From the menu bar select File > New > Session to clear the contents of the current
session.

2. From the plot type menu, select Bar Chart, .

3. Enter the Define Curves panel, .


4. Click Add to create a new bar chart named Curve 1.
Curve 1 is highlighted in the series list to indicate it is the active series.
5. In the Series field above the bar chart list, rename Curve 1 to Nodal Point 1 and
press ENTER.
6. Under Source, select Values.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.104

7. In the panel’s center, under the column Nodal Point 1, type these three values:

Index 1: 563.35

Index 2: 567.22

Index 3: 423.51

8. Click Apply to create the bar chart.

Step 2: Create a bar chart by importing values from the data file
nodal_values.dat.
1. Add a second bar chart to the current plot window.
2. Rename Curve 2 to Nodal Point 2.
3. Under Source, select File.
4. Click the file browser next to File: and open the nodal_values.dat file, located in the
plotting folder.
5. Leave Type: set to Unknown.
6. Leave Request: set to Block1.
7. Leave Component: set to Column1.
8. Click Apply to create the bar chart.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.105

Step 3: Create a bar chart using a math expression.


1. From menu bar, select File > Import > Session and open the session file
bar_chart.mvw, located in the plotting folder.
A second page containing an XY Plot window with three XY data curves is added to the
session and is currently displayed.
2. Go back to the session’s page 1, which contains the bar chart.
3. Add a third bar chart to the current plot window.
4. Rename Curve 3 to Nodal Point 3.
5. Under Source, select Math.
6. In the Expression: field, type the following math expression:
{max(p2w1c1.y),max(p2w1c2.y),max(p2w1c3.y)}
7. Click Apply to create the bar chart.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.106

Step 4: Modify category labels.


1. In the Categories column, click One, rename it x disp, and click Apply to update the
bar chart’s label.
2. Rename category Two to y disp.
3. Rename category Three to z disp.
4. Click Apply to update the bar chart’s labels.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.107

HG-3010: Working with Complex Plots

In this tutorial you will learn how to:


• Create complex plots from a data file
• Add and edit complex data curves by using mathematical functions

Tools
The Build Plots panel can be accessed in one of the following ways:

• Click the Build Plots icon, , from the toolbar


Or
• From the menu bar select Curves > Build Plots
The Build Plots panel constructs multiple curves and plots from a single data file. Curves
can be overlaid in a single window or each curve can be assigned to a new window.
Individual curves are edited using the Define Curves panel.

The Define Curves panel can be accessed in one of the following ways:

• Click the Define Curves panel button, , from the toolbar


Or
• From the menu bar select Curves > Define Curves
Existing curves can be edited individually, and new curves can be added to the current plot
using the Define Curves panel. The Define Curves panel also provides access to the
program's curve calculator.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.108

Exercise: Plot Complex Data and Apply Math


Functions

Step 1: Build a complex data curve from a data file.


1. From the menu bar select File > New > Session to clear the contents of the session.

2. From the plot type menu, select Complex Plot, .

3. Enter the Build Plots panel .

4. Use the file browser button to open the control_arm_sol111.pch file, located in the
plotting folder.
5. Leave the X type: set to Frequency [hz].
6. In the Y type: column, select Subcase 1 Displacements.
7. In the Y Request: column, select Point id 2086.
8. In the Y Component: column, select X-Rot.
9. Click Apply to create the complex curves.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.109

Step 2: Apply the Inverse Fast Fourier Transform (ifft) math function
to the complex data curve.
1. Change the current window layout of page 1 to a two-window layout, .
2. Activate the window on the right side.
New plot windows are set to the XY plot type by default.
3. Set the plot type for the window on the right side to XY Plot.

4. Enter the Define Curves panel, .


5. Add a new XY plot curve named Curve 1.
6. Rename Curve 1 to ifft_curve.
7. Under Source, select Math.
8. In the x: field, enter p1w1c1.x.
9. In the y: field, enter ifft(p1w1c1.ym,p1w1c1.yp).
10. Click Apply to create the XY data curve.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.110

Step 3: Create a complex data curve of frequency versus


displacement for Subcase two, node 2086, x-rotation.
1. Activate window 1 (the left window).

2. Enter the Build Plots panel, .


3. In the Y type: column, select Subcase 2 Displacements.
4. In the Y Request: column, select Point id 2086.
5. In the Y Component: column, select X-Rot.
6. Click Apply to create the complex curves.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.111

Step 4: Subtract the Subcase two curve from the Subcase one
curve.
1. Change the current window layout for page 1 to a three-window layout, .
2. Make the new, blank plot window active.
3. From the plot type menu, select Complex Plot.
4. Enter the Define Curves panel.
5. Click Add P/M to create a new complex curve.
6. Rename Curve 1 to sub_disp.
7. Under Source, select Math.
8. In the x: field, enter p1w1c1.x.
9. In the yp: field, enter p1w1c2.yp - p1w1c1.yp.
10. In the ym: field, enter p1w1c2.ym - p1w1c1.ym.
11. Click Apply to create the complex curve.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.112

HG-3020: Working with Polar Plots

In this tutorial, you will learn how to:


• Create polar plots from a data file.
• Add polar plots by using mathematical functions.

Tools
The Build Plots panel can be accessed in one of the following ways:

• Click the Build Plots button, , from the toolbar


Or
• From the menu bar select Curves > Build Plots.
The Build Plots panel constructs multiple curves and plots from a single data file. Curves
can be overlaid in a single window or each curve can be assigned to a new window.
Individual curves are edited using the Define Curves panel.

The Define Curves panel can be accessed in one of the following ways:

• Click the Define Curves button, , from the toolbar


Or
• From the menu bar select Curves > Define Curves
Existing curves can be edited individually, and new curves can be added to the current plot
using the Define Curves panel. The Define Curves panel also provides access to the
program's curve calculator.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.113

Exercise: Plot Polar Data and Add Plots

Step 1: Build a polar data plot from a data file.


1. From the menu bar select File > New > Session to clear the contents of the session.

2. From the plot type menu, select Polar Plot, .

3. Enter the Build Plots panel, .


4. Use the file browser button to open the modal_participation.f06 file, located in the
plotting folder.
5. Leave the Subcase: field set to Subcase 11.
6. Leave the Data Type: field set to Frequency.
7. From the Type: column, select Modal Participation.
8. From the Request: column, select FLUID Node 5417.
9. From the Component: column, select Mode 1, Mode 3 and Mode 5.
10. Click Apply to create the polar plots.
The vectors are plotted at a frequency of 100.0Hz.

11. Access the Frequency dialog by clicking the listed frequency value in the bottom left
region of the plot area.
12. Select the 128.0Hz frequency and click OK.
The vectors are plotted at 128Hz frequency.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.114

Step 2: Add polar data.

1. Use the Page Layout button, , to change the window layout of page 1 to a two-
window layout.
2. Activate the window on the right side.
3. Change the plot type for the new window to Polar Plot.
4. Enter the Define Curves panel.
5. Add a new polar plot curve named Curve 1 by selecting Add R/I.
6. Rename Curve 1 to Summation by typing the new name in the Curve: field and pressing
the ENTER key.
7. Under Source, select Math.
8. In the Frequency= field, enter p1w1c1.f.
A frequency field is specified to allow HyperGraph to compute the summation vector for
every frequency. In this case, the summation vector can be animated or updated when
a certain frequency is chosen.
9. Select the Real = radio button and then select Math as the Source.
10. In the Real = field, enter p1w1c1.yr + p1w1c2.yr + p1w1c3.yr.
11. In the Imaginary = field, enter p1w1c1.yi + p1w1c2.yi + p1w1c3.yi.
12. Set the Type: field to Vector Plot.
13. Click Apply to create the polar plot.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.115

14. Access the Frequency dialog by clicking the listed frequency value in the bottom left
region of the right-hand side of window 2.
15. Choose the 128.0Hz frequency and click OK.
The summation vector is now plotted at 128Hz frequency.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.116

16. Change the Type: field to Phase vs Mag. Notice how a Phase vs Magnitude curve for
all frequencies is shown as a line connecting the tips of the vectors at different
frequencies.

17. Click the start animation button, .


Notice how the summation of vectors is updated in the animation for each frequency
value in the list.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.117

Templates

HG-4000: Creating an Export Template

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.118

HG-4000: Creating an Export Template

In this tutorial, you will learn about:


• Export template language
• How to register the template
• How to export plot data to a file

Tools
Export Template: is a file that contains instructions for exporting curve data into files. The
instructions contained in an Export Template file are in an uncompiled type of programming
language called Export. An Export Template tells the program in which format the data
should be written into the file.

Templex and Export Template Language Statements


The language of Export Templates follows a mixture of Templex commands plus some
additional special statements. For the export of curves only a few statements are needed:

Templex Commands
indexofmin(i) Index of the minimum of a vector (not the minimum itself)
numpts(x) Dimension of the vector X
table() Export of vectors organized in columns
for – endloop Loop
if – else – endif Logics

Special Export Commands


cr() New line
curvex(i) X vector of curve i
curvey(i) Y vector of curve i
curvelabel(i) Export of the legend of curve i
list Export of vectors in rows
margins(0,30) Length of a line
numcurves() Number of curves in a window
; End of a command (except loops and logics)

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.119

Registering an export template:


The format selection list in the Export Curves... panel contains, by default, ten formats.
Via the preferences file, registered templates are added to this list. Registration is done
using the preferences file or via the Tools menu.
1. Go to <installation directory>\hw\prefinc.
2. Open preference_plot.mvw and add the following command that registers an export
template with a session.
*BeginDefaults()
*BeginPlotDefaults()
*AddExportFormat(par1,/homes/.../_madymo_export.tpl,par2)
*EndPlotDefaults()
*EndDefaults()
Above is a small sample of a preference_plot.mvw file that registers a new template
(madymo_export.tpl) with a session.
• This file allows the user to customize sessions by specifying defaults or defining
external files that should be able to interact with the user’s session.
Note: The content of the parameter par1 is the name that shows up in the selection list.
The parameter par2 specifies the extension of the files that is used for exporting the
data: export.par2.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.120

Exercise: Export Template Example for MADYMO


Step 1: Create a Template that makes a file format for a function in
MADYMO
1. Add the commands below to a text file named madymo_export.tpl.
The statement on the right is an explanation of the command.
{
Row_1="!vehicle acceleration"; Set variable for the comment in line1

nc = numcurves(); Set number of curves


lc = nc - 1

for (i = 0; i < nc; i++) Loop for the number of curves


x = curvex(i); Set the x-vector of curve i
y = curvey(i); Set the y-vector of curve i
t = numpts(x); Set the number of points

if (!numpts(x)) If curve is switched off don’t export


else
Row_1; cr(); Output for Line 1, label
t, %5i; cr(); Output for Line 2, number of points

table(x, y, "%10.6f %11.6f", 0, t - 1); Output Line 3 to t-1 with the table
command
endif

if (i != lc) After every exported curve set an empty


line

cr();
endif

endloop
}

Step 2: Register the Export Template.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.121

1. From Tools menu, select Readers, Writers, and Functions….


2. Go to Export Templates tab.
3. Browse the template created for Madymo.
4. Give the Template a name.
5. Click Register… and OK.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.122

Step 3: Export plot data:


1. From the File menu, select Export > Curves.
2. Enter a file name for the destination file.
-Or -
Select an existing file using the file browser.

3. For Format, select the file you just registered.


4. Specify a range of pages.
5. Click Apply.
Plot data from the specified pages are exported to the file.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.123

RESULT:
The below data file is created after exporting curves in this Madymo format:
!vehicle acceleration
151
0.000000 13.591910
1.000000 12.144580
2.000000 10.850770
3.000000 10.180930
4.000000 9.921851
5.000000 9.995111
6.000000 10.342690
7.000000 11.209030
...
...
147.000000 132.563400
148.000000 130.487300
149.000000 129.073800
150.000000 127.332800

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.124

Customization

HG-5010: Customizing the Environment

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.125

HG-5010: Customizing the Environment

In this tutorial, you will learn how to customize the program using the preference file.

Tools
The Preference File:
A preference file is a script file that is read each time the program is started. It specifies
default user settings such as the order in which colors are assigned, the default printer,
default page layout, the auto save interval, and so on. A standard preference file can be
created in the program installation directory which is executed every time a license is
activated. An additional preference file can be created in your working directory that
contains personal settings that either overwrite the standard preference file or are added to
the existing settings in the standard preference file.
The HyperWorks installation contains two preference files located under $ALTAIR_HOME/hw:
• All HyperWorks desktop products, except HyperStudy: preferences.mvw
• HyperStudy only: preferences_hst.mvw
Seven include preference files are contained in the installation. These include preference
files must be included in the main preference file, as they cannot be used as independent
preference files. They are located under $ALTAIR_HOME/hw/prefinc.
Organization of the Preference File
The following describes the standard structure of the preferences file, containing five
principal blocks.

*BeginDefaults()
*EndDefefaults()

*BeginDefinitions()
*EndDefinitions()

*BeginStatsTemplates()
*EndStatsTemplates()

*BeginPlotMacros()
*EndPlotMacros()

*BeginTemplexFunctions()
*EndTemplexFunctions()
The *BeginDefaults() block is unique to a preference file while the *BeginDefintions(),
*BeginStatsTemplates(), *BeginPlotMacros(), and *BeginTemplexFunctions() blocks
are the same as those found in script files.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.126

The following are general concepts for each of these sections:

*Id statement
The syntax for the *Id statement is: *Id("Release") where the release gives the program
name and version.
For example: *Id("HyperGraph v8.0")

The *BeginDefaults - *EndDefaults block


The *BeginDefaults() block is comprised of general defaults and seven subordinate
statement blocks. The general defaults are declared first, and then as many sub-blocks as
required. Each sub-block has the same structure as the main block. This means there is a
*Begin statement, followed by the necessary statements, and closing the block with an
*End statement.

General defaults
General defaults include the autosave interval, bubble help status, and default printer
settings. The block is delimited by these statements:
*BeginDefaults()
*EndDefaults()

Model defaults
Model defaults are used to customize the model tool bar and to add MDL defaults for
submitting mechanical system models to a solver. The block is delimited by these
statements:
*BeginModelDefaults()
*EndModelDefaults()

Graphic defaults
Graphic preferences such as model orientation and the part attributes are specified in the
graphics default block. The block is delimited by these statements:
*BeginGraphicDefaults()
*EndGraphicDefaults()

Plot defaults
Plotting preferences for curves including colors, fonts, and note defaults are specified in the
plotting defaults block. The block is delimited by these statements:
*BeginPlotDefaults()
*EndPlotDefaults()

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.127

TextEditor defaults
TextEditor preferences including text and background color and font settings are specified in
the text editor defaults block. The block is delimited by these statements:
*BeginTextEditorDefaults()
*EndTextEditorDefaults()

Page header defaults


Page headers are specified in the page header block. The block is delimited by these
statements:
*BeginHeader()
*EndHeader()

Page footer defaults


Page footers are specified in the page footer block. The block is delimited by these
statements:
*BeginFooter()
*EndFooter()

To help you avoid compile problems, when you begin each block, start with the *Begin and
*End block statements, then enter the remaining statements between the block delimiters.

Exercise: Changing the default setting through the


preference file.

Step 1: Set the auto save default.


1. Select TextView window mode.
2. From the menu bar, select File > Open > Document and open the
autosave_bubble_help.mvw file, located in the preferences folder.
3. After the *BeginDefaults() line, add the following preference statement
*SetAutoSaveInterval(2)
This sets the autosave interval to two minutes. If this statement does not appear in the
preferences.mvw file, the program sets the autosave interval to 10 minutes.
4. Save the new preference file to your home directory as new_autosave_bubble_help.mvw
by selecting File > Save As > Document from the menu bar.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.128

Step 2: Observe the updated AutoSave default.


1. Start the program.

2. Set the preference file by selecting File > Load > Preference File.
This opens a window which lists all the registered preference files.

3. Click Register and then browse for the file new_autosave_bubble_help.mvw.


4. Select new_autosave_bubble_help.mvw from the list of Registered Preferences and
then click Load to load the preference file. Click the red X in the upper right corner to
close the window
5. Wait for approximately two minutes and then list the contents of your working directory.
A new file autosave.mvw will be present and contain a back-up of the current session.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.129

Step 3: Set the curve defaults.

1. Open TextView from the client selector, .


2. From the menu bar, select File > Open > Document and open the
curve_defaults.mvw file, located in the preferences folder.
3. After the *BeginPlotDefaults() line, add the *ResetCurveDefaults() statement to
ignore all previous *SetCurveDefaults() statements.
4. After the *ResetCurveDefaults() line, add the following preference statements to set
the curve defaults:
*SetCurveDefaults(1, 7, 0, 0, 0)
*SetCurveDefaults(3, 16, 1, 0, 0)
*SetCurveDefaults(5, 24, 2, 0, 0)
*SetCurveDefaults(2, 32, 3, 0, 0)
*SetCurveDefaults(4, 40, 0, 0, 0)
*SetCurveDefaults(5, 48, 1, 0, 0)
A plotting preference block can contain several *SetCurveDefaults() statements. The
program assigns curve attributes sequentially.
5. Save the new preference file to your home directory as new_curve_defaults.mvw by
selecting File > Save As > Document from the menu bar.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.130

Step 4: To observe the updated curve default settings:

1. Click Add Page, , to add a new page to the current session.


2. Select HyperGraph 2D from the Select Application menu.

3. Change the Page Window Layout to two windows per page, .


4. Click Build Plots on the plotting toolbar.
5. Open a plotting file:
− Click the file browser.
− Select the file ANGACC, located in the plotting folder.
− Click Open.
6. Select the data components and channels to plot:
− Select Angular Acceleration from the Y Type list.
− Select 50th% Hybrid3 – LOWER TORSO from the Y Component list.
− Select the All button from the Y Channel list.
7. Click Apply.
8. Set the file new_curve_defaults.mvw as the preference file by selecting File > Load >
Preference File.
9. Select Register and then browse for the file new_curve_defaults.mvw.
This automatically loads new_curve_defaults.mvw file as the preference file.
10. Select new_curve_defaults.mvw from the list and click Load. Then click the red X in
the upper right corner to close the window.
11. If prompted to “Update all plots current default colors”, select No.
12. Click on the second plot window on this page.
13. Click Build Plots from the plotting toolbar.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.131

14. Click Apply.


The color and line styles follow the defaults defined in the new_curve_defaults.mvw file
instead of the program system defaults.

Step 5: To set the default plot colors:


1. Add a new page and select the TextView window mode.
2. From the menu bar, select File > Open > Session and open the plot_colors.mvw file,
located in the preferences folder.
3. After the *BeginPlotDefaults() line, add the following preference statements to set
the default plot colors:
*SetBackgroundColor(9)
*SetGridlineColor(6)
*SetZerolineColor(2)
*SetFrameColor(7)
*SetAxisColor(4)
*SetHeaderColor(0)
*SetFooterColor(3)
4. Save the new preference file as new_plot_colors.mvw in your working directory. You
cannot save files back to the default directory.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.132

Step 6: To observe the updated default plot colors:


1. Click Add Page on the toolbar to add a new page to the current session.
2. Select HyperGraph 2D from the Select Application menu.
3. Create header and footer text.
4. Register and Load the preference file new_plot_colors.mvw. If prompted to "Update
all plots current default colors", click No.
5. Add a new page, which will activate the new settings.
6. Create header and footer text.
Note: The colors of the various areas of the plot window reflect the defaults defined in
the file new_plot_color.mvw rather than the program system defaults.

Step 7: To set the default fonts for the plot area:


1. Add a new page and select the TextView window mode.
2. From the file browser on the toolbar, open the file font_defaults.mvw, located in the
preferences folder.
3. After the *BeginPlotDefaults() line, add the following preference statements:
*SetAxisLabelFont("Times New Roman", 1, 0, 8)
*SetAxisTicFont("Times New Roman", 0, 1, 18)
The first placeholder sets the font name.
The second placeholder sets the font weight. 0 = normal (default), 1 = bold.
The third placeholder sets the slant, or font style. 0 = normal (default), 1 = italic.
The fourth placeholder sets the font size, 8, 10, 12, 14, 18, or 24 points.
Note: If the suggested font is not available on your system, use the name of a font
available on your system.
4. After the *SetAxisTicFont() line, add the following preference statements to set the
font defaults for the header and footer text:
*SetLine1HeaderFont("Verdana",0,0,8)
*SetLine2HeaderFont("Verdana",1,0,10)
*SetLine3HeaderFont("Verdana",0,1,12)
*SetLine1FooterFont("Tahoma",0,0,8)
*SetLine2FooterFont("Tahoma",0,1,10)
*SetLine3FooterFont("Tahoma",1,0,12)
Note: If the suggested font is not available on your system, use the name of a font
available on your system.
5. Save the new preference file as new_font_defaults.mvw.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.133

Step 8: To observe the updated default plot fonts:


1. Click Add Page on the toolbar to add a new page to the current session.
2. Select HyperGraph 2D from the Select Application menu.
3. Create a three line header and footer on the plot.
4. Register and Load the file new_font_defaults.mvw. If prompted to update to the
current defaults, select No.
5. Change Page Layout to two windows per page.
6. Click on the second plot window on the current page.
7. Create a three-line header and footer on the plot.
The fonts in the plot window reflect the defaults defined in the new_font_defaults.mvw
file, including each line of the header and footer area, rather than the program system
defaults.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.134

Step 9: Set the note defaults.


1. Add a new page and select the TextView window mode.
2. From the file browser on toolbar, select the file notes_legends.mvw, located in the
preferences folder.
3. After the *BeginPlotDefaults() line, add the following preference statement to set the
default font type, style and size for notes:
*SetNoteFont("Tahoma", 1, 1, 10)
4. After the *SetNoteFont() line, add the following preference statements to set the
default for note attachment, text alignment, and color:
*SetNoteAttachment(View)
*SetNoteAlignment(Left)
*SetNoteColor(5)
5. Save the new preferences file as new_notes_legends.mvw.

Step 10: To set the legend defaults:


1. Select the file new_notes_legends.mvw from the file browser in TextView window
mode.
2. After the *SetNoteColor() line, add the following preference statements to set the
defaults for legend font and legend placement:
*SetLegendFont("Tahoma",1,1,24)
*SetLegendPlacement(TopRight)
3. Save the new preference file as new_notes_legends.mvw.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.135

Step 11: To observe the updated default plot fonts:


1. Click Add Page on the toolbar to add a new page to the current session.
2. Select HyperGraph 2D from the Select Application menu.
3. Change page layout to two windows per page.
4. Add a curve to the current plot.
5. Add a note to the current plot.
6. Register and Load the file new_notes_legends.mvw. If prompted to update to current
defaults, select No.
7. Click on the second plot window on the current page.
8. Add a curve to the current plot.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.136

9. Add a note to the current plot.


The note and legend displayed on the plot reflect the defaults defined in the
new_notes_legends.mvw file. To view the note attachment update, translate the curves
using the view control arrows located in the lower left of the program window.

Step 12: Update note and legend defaults.


1. Add a page and select TextView from the Select Application menu.
2. From the file browser on the toolbar, open file headers_footers.mvw, located in the
preferences folder.
3. After the *BeginDefaults() line, add the following preference statements to define the
*BeginHeader() block:
*BeginHeader()
*EndHeader()
4. After the *BeginHeader() line, add the following preference statements to define portion
of the available header area:
*BeginRegion(400, 0, 600, 300)
*EndRegion()
5. Region descriptions use a coordinate system. The arguments in the region statement
represent: the minimum X coordinate, the minimum Y coordinate, the maximum X
coordinate and the maximum Y coordinate.
If the region you were describing was the entire header area your *BeginRegion
statement would be: *BeginRegion(0,0,1000,1000).
6. After the *BeginRegion() line, add the following preference statements to set the text
font, alignment and border for the region (update the path below to reflect where your
installation is located):
*Font("Times",0,1,12)
*Alignment(Center)
*BorderWidth(1,1,1,1)
7. After the *BorderWidth() line, add the following preference statement to define the text
in the header region:
*Text("Project Title")
8. Save the new preference file as new_headers_footers.mvw.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.137

Step 13: Add a page footer.


1. Your file should be new_headers_footers.mvw. If not, open the file
new_headers_footers.mvw from TextView window mode.
2. After the *EndHeader() line, add the following preference statements to define the
*BeginFooter() block:
*BeginFooter()
*EndFooter()
3. After the *BeginFooter() line, add the following preference statements to define and
set up one region in the footer:
*BeginRegion(700, 0, 1000, 1000)
*Font("Times",0,1,12)
*Alignment(Center)
*BorderWidth(1,1,1,1)
*EndRegion()
The footer region’s coordinate system is similar to the header region: minimum X
coordinate is 0 at the left and maximum X coordinate is 1000 at the right. The minimum
Y coordinate is 0 at the base of the footer and its maximum coordinate is 1000.
4. After the *BorderWidth() line, add the following preference statement to place text in
the region:
*Text("Your Name")
*Text("{time()} on {date()}")
*Text("Page: {pagenum}/{numpages}")
5. After the *EndRegion() line, add the following preference statements to define and set
up a second region within the page footer:
*BeginRegion(700, 0, 1000, 1000)
*BorderWidth(1,1,1,1)
*EndRegion()
6. After the *BorderWidth() line, add the following preference statement to put an image
in the region:
*Image("<install_directory>/tutorials/mv_hv_hg/preferences/Altair_logo.gif"
)
Images, such as company logos, can be added to any region within the header or footer
of a plot. The image type must be either GIF (format 87), JPG or BMP. Images are
fitted vertically and centered horizontally.
7. Save the new preference file as new_headers_footers.mvw.

Proprietary Information of Altair Engineering


Altair HyperGraph 2D 2019 Tutorials p.138

Step 14: To observe the new page header and footer:


1. Register and Load the preference file new_headers_footers.mvw.
2. If a printer is installed, you can select Print and then click OK. These headers and
footers will be seen when the session or page is printed.

Step 15: To set the text editor defaults:


1. Add a page and select TextView from the Select Application menu.
2. From file browser on the toolbar, select the file text_editor.mvw, located in the
preferences folder.
3. After the *BeginTextEditorDefaults() line, add the following preference statement to
set the default font type, style, and size for the text editor:
*Font("Times", 0, 1, 12)
4. After the *Font() line, add the following preference statement to set the default text
color for the text editor window:
*TextColor(6)
5. After the *TextColor() line, add the following preference statement to set the default
background color for the text editor window:
*BackGroundColor(23)
6. Save the new preference file as new_text_editor.mvw.

Step 16: To observe the updated default plot fonts:


1. Register and Load the file new_text_editor.mvw.
2. Click the Add Page icon on the toolbar to add a new page to the current session.
The updated default for the background color is displayed
3. Click in the text window and enter text to view changes to text defaults.

Proprietary Information of Altair Engineering

Vous aimerez peut-être aussi