100% found this document useful (1 vote)
330 views17 pages

SIMPACK 代码输出功能

The document discusses further developments of SIMPACK code export capabilities. It introduces C-code export, code export for co-simulation where the exported code acts as a client or server, post-processing exported model results using SBR files in the SIMPACK post-processor, code export for hardware-in-the-loop simulation on real-time targets, and a code export Excel plug-in to make complex multibody simulations accessible to non-expert users through a familiar Excel interface.

Uploaded by

loeliang
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
100% found this document useful (1 vote)
330 views17 pages

SIMPACK 代码输出功能

The document discusses further developments of SIMPACK code export capabilities. It introduces C-code export, code export for co-simulation where the exported code acts as a client or server, post-processing exported model results using SBR files in the SIMPACK post-processor, code export for hardware-in-the-loop simulation on real-time targets, and a code export Excel plug-in to make complex multibody simulations accessible to non-expert users through a familiar Excel interface.

Uploaded by

loeliang
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 17

Further Developments of SIMPACK Code Export

Further Developments and Applications of


SIMPACK Code Export

Frank Kohlschmied, Intec GmbH

INTEC GmbH, SIMPACK User Meeting 2007, Frank Kohlschmied


Further Developments of SIMPACK Code Export

Introduction

New Developments in SIMPACK Code Export

C-Code Export

Code Export-Executable usable as partner in Co-Simulation

PostProcess results by SBR-File and SIMPACK PostProcessor

Code Export for HIL-Simulation

Code Export Excel Plug-In

INTEC GmbH, SIMPACK User Meeting 2007, Frank Kohlschmied


Further Developments of SIMPACK Code Export

C-Code Export

Export C-Code alternatively to F90-Code

● required source code language can


be selected by Configuration GUI

● uses converter ForC

● no Fortran compiler required any more

● enables access to arbitrary platforms,


e.g. HIL targets

● available with SIMPACK 8900

INTEC GmbH, SIMPACK User Meeting 2007, Frank Kohlschmied


Further Developments of SIMPACK Code Export

Co-Simulation with exported code

Create Code Export executables using TCP/IP communication

● select, if exported code should act


as Co-Simulation master or slave

● created executable can be used as


client or server

● enables Co-Simulation:

Model1 Model 2
SIMPACK exported Code
exported Code exported Code

● Benefits:

+ Co-Simulation can be used to split model on 2 CPUs


+ use exported models as ‘black box’ functionality in SIMPACK

INTEC GmbH, SIMPACK User Meeting 2007, Frank Kohlschmied


Further Developments of SIMPACK Code Export

Code Export postprocessing by SBR-file

Plot and animate exported model in SIMPACK PostProcessor

select required results in SIMPACK


Measurement GUI

activate generation of SBR-file


in
Code Export Confiruration GUI

exported code creates SBR-


File
which can be post-processed
in
SIMPACK PostProcessor for
plot and animation.

INTEC GmbH, SIMPACK User Meeting 2007, Frank Kohlschmied


Further Developments of SIMPACK Code Export

Code Export for HIL-Simulation

INTEC GmbH, SIMPACK User Meeting 2007, Frank Kohlschmied


Further Developments of SIMPACK Code Export

Code Export for HIL-Simulation

What is Hardware-in-the-Loop-(HIL)-
Simulation ?

A real existing 'hardware' component (e.g. electronic control unit,


suspension, steering wheel) is connected to a virtual simulation
envoronment.

Simulation is carried out on a Real Time Target with


specified real-time operating system

Automatic generation and compilation of


code
for HIL Targets.

● ETAS Real Time PC


● xPC Target (The Mathworks)

● dSpace ds1005

● dSpace ds1006

● VxWorks (Wind River)

INTEC GmbH, SIMPACK User Meeting 2007, Frank Kohlschmied


Further Developments of SIMPACK Code Export

Code Export for HIL-Simulation

Requirements for SIMPACK Code to run on HIL


targets
i i+1
simulation needs to be running in “real-time” Integration
xi+1 = xi + h*xp
● consecutive result output at discrete time steps
rhs-call meas-call
● function evaluation, integration and measurements xp=f(x,u,t) y=g(x,u,t) !
within a certain time range for every time step
>= 0

non-iterative solver with fixed step size ti real time


ti + h
(conventional solution: explicit solver, e.g. Explicit Euler)

Im
x
x ● model eigenvalues must be within stability range of solver

1
Re for explicit solvers stability range depends on stepsize
h

usage of Explicit Euler enforces limitations in


frequency range and modelling details
(e.g. virtual elements, look-up tables, etc)
stability region
of Explicit Euler
INTEC solution

INTEC GmbH, SIMPACK User Meeting 2007, Frank Kohlschmied


Further Developments of SIMPACK Code Export

Code Export for HIL-Simulation

SIMPACK Real Time


Solver Im
x

● linear-implicit Euler with constant step size x

● provides a-(absolute)-stability of solution

xn+1 = xn + hf ( xn+1 ,tn )

enables part-based modelling

● avoid model redundancy


● avoid data redundancy

● improve result quality

one model for offline and online (HIL) simulation !

INTEC GmbH, SIMPACK User Meeting 2007, Frank Kohlschmied


Further Developments of SIMPACK Code Export

Code Export Excel Plug-In

INTEC GmbH, SIMPACK User Meeting 2007, Frank Kohlschmied


Further Developments of SIMPACK Code Export

Code Export Excel Plug-In

Motivation

Initial Situation:

● on the one side SIMPACK as a complex MBS modelling and simulation tool
providing high-end solutions for expert users

● on the other side increasing demand for high-value MBS-simulation by users


- with no modelling experience
- with reduced requirements in flexibility and functionality
- accustomed to their familiar working environment
Solution
combine SIMPACK Code Export with wide spreaded application tool:

Excel Plug-In

make complex MBS simulation available to non-MBS experts

INTEC GmbH, SIMPACK User Meeting 2007, Frank Kohlschmied


Further Developments of SIMPACK Code Export

Code Export Excel Plug-In

Application Szenario

SIMPACK Expert User:

● creates MBS model

● exports model with Excel template GUI

Standard User, operates in Excel:


● parametrises model

● executes simulation

● postprocesses result

INTEC GmbH, SIMPACK User Meeting 2007, Frank Kohlschmied


Further Developments of SIMPACK Code Export

Code Export Excel Plug-In

Features - Simulation

● start Simulation of exported


models using SIMPACK
Time-Domain DAE Solver

● set simulation end-time


● set output stepsize

● get info about simulation


state

● add coments

INTEC GmbH, SIMPACK User Meeting 2007, Frank Kohlschmied


Further Developments of SIMPACK Code Export

Code Export Excel Plug-In

Features -
Parametrisation
Exported model can be parametrised

● edit selected substitution variables (subvars)

● exchange database elements, e.g.

- Input Functions
- Function Arrays
- Track

● dialog enables access to database elements

INTEC GmbH, SIMPACK User Meeting 2007, Frank Kohlschmied


Further Developments of SIMPACK Code Export

Code Export Excel Plug-In

Features -
PostProcessing
●use Excel internal functionality to
plot
simulation results (y-output vector)

● animation can be provided by


animation viewer

INTEC GmbH, SIMPACK User Meeting 2007, Frank Kohlschmied


Further Developments of SIMPACK Code Export

Code Export Excel Plug-In

Benefits

● provides easy-to-use GUI to simulate, parametrise and post process exported models

● customized GUI can be expanded by Excel standard functionality

● high availability by wide spreading of Excel installations

● is independent from full SIMPACK installation

● provides easy access to high-value SIMPACK models to non-MBS experts

INTEC GmbH, SIMPACK User Meeting 2007, Frank Kohlschmied


Further Developments of SIMPACK Code Export

Customer Applications

Code Export praesentations at SIMPACK User Meeting 2007

● Development of an Experimental and Test Environment for Vehicle Real-Time Simulatio

Gerd Bitsch, Frauenhofer-Institut


Afternoon Session, 1st day

● SIMPACK Realtime Models for HiL Testing at DC Trucks

Klaus Wüst, Daimler Nutzfahrzeuge


Automotive Session, 2nd day

● Real-Time SIMPACK Lookup Table Model for a Multi-Processor HIL-Testrig

Uwe Heitz, ZF Friedrichshafen AG


Automotive Session, 2nd day

● ... also visit our Code Export stand

INTEC GmbH, SIMPACK User Meeting 2007, Frank Kohlschmied

You might also like