lightweight structures in civil engineering international seminar of iass polish chapter organized...

17
LIGHTWEIGHT STRUCTURES in CIVIL ENGINEERING INTERNATIONAL SEMINAR of IASS POLISH CHAPTER Organized by Polish Chapter of International Association for Shell and Spatial Structures Warsaw-Częstochowa, 3 December, 2004 OVERLOADING OF OPERATORS IN FEMA SYSTEM W. PRZYBYŁO 1 and M. MAŹNIEWSKI 2 1 Professor, Częstochowa University of Technology, ul. Akademicka 3, 42-200 Częstochowa, POLAND 2 PhD. student, Częstochowa University of Technology, ul. Akademicka 3, 42-200 Częstochowa, POLAND

Upload: dana-shields

Post on 13-Dec-2015

213 views

Category:

Documents


1 download

TRANSCRIPT

Page 1: LIGHTWEIGHT STRUCTURES in CIVIL ENGINEERING INTERNATIONAL SEMINAR of IASS POLISH CHAPTER Organized by Polish Chapter of International Association for Shell

LIGHTWEIGHT STRUCTURES in CIVIL ENGINEERINGINTERNATIONAL SEMINAR of IASS POLISH CHAPTER

Organized by Polish Chapter ofInternational Association for Shell and Spatial Structures

Warsaw-Częstochowa, 3 December, 2004

OVERLOADING OF OPERATORS IN FEMA SYSTEM

W. PRZYBYŁO 1 and M. MAŹNIEWSKI 2

1Professor, Częstochowa University of Technology, ul. Akademicka 3, 42-200 Częstochowa, POLAND

2PhD. student, Częstochowa University of Technology, ul. Akademicka 3, 42-200 Częstochowa, POLAND

Page 2: LIGHTWEIGHT STRUCTURES in CIVIL ENGINEERING INTERNATIONAL SEMINAR of IASS POLISH CHAPTER Organized by Polish Chapter of International Association for Shell

FEM (Finite Elements Method)● Constructions are divided into many elements

● Elements are described with matrices

● Hypermatrix - matrix of matrices

● Problems associated with matrices:

– high requirements of disk and memory space

– high requirements of computational power

– costly and time-consuming calculations

Page 3: LIGHTWEIGHT STRUCTURES in CIVIL ENGINEERING INTERNATIONAL SEMINAR of IASS POLISH CHAPTER Organized by Polish Chapter of International Association for Shell

Characteristics of matrix operations

● Problems' solutions are constructed as a set of subtasks

● Subtasks are executed one by another

● Some subtasks are repeated many times with different data-sets

● Some subtasks are independent one of another● Subtasks can be executed simultaneously

Page 4: LIGHTWEIGHT STRUCTURES in CIVIL ENGINEERING INTERNATIONAL SEMINAR of IASS POLISH CHAPTER Organized by Polish Chapter of International Association for Shell

Parallelization of multiplying matrices

Page 5: LIGHTWEIGHT STRUCTURES in CIVIL ENGINEERING INTERNATIONAL SEMINAR of IASS POLISH CHAPTER Organized by Polish Chapter of International Association for Shell

Comparison of computer systems● Single computer – one CPU● Symetric Multiprocessor(SMP)● Parallel computer

– many processors in one box– one processor – one task

● Clusters – set of computers jointed with network– Saving money by using owned hardware– Big computational power with low cost– Easy enlarging– Reliable calculations– Fail-safe system

Page 6: LIGHTWEIGHT STRUCTURES in CIVIL ENGINEERING INTERNATIONAL SEMINAR of IASS POLISH CHAPTER Organized by Polish Chapter of International Association for Shell

Speeding-up calculations

● Simultaneous subtasks' execution

● Computer programs' parallelization

● Building clustered systems

● Requirements:

– Synchronization of data– Interprocess communication– Network communication

Page 7: LIGHTWEIGHT STRUCTURES in CIVIL ENGINEERING INTERNATIONAL SEMINAR of IASS POLISH CHAPTER Organized by Polish Chapter of International Association for Shell

Modelling algorithms into computer programs

● Algorithm – description of problem solution

● Algorithms are constructed with cooperation of specialists

● Computer program – representation of algorithm

– different syntax of programming languages

– Only programmers understand source code

– Mathematic operations replaced with programming operations

Page 8: LIGHTWEIGHT STRUCTURES in CIVIL ENGINEERING INTERNATIONAL SEMINAR of IASS POLISH CHAPTER Organized by Polish Chapter of International Association for Shell

Overloading of operators

● Arithmetic operators – works only with basic data-types(char, integer value, real value...)

● Defining own data-types – Objective Programming

● Matrix operations– Definition of object: MATRIX

● Overloading operators – allowing them work with user-defined data-types

● Problems with matrices operations– Large matrices need large disk and memory spaces– Assignment of matrices – copying one matrix to

another

Page 9: LIGHTWEIGHT STRUCTURES in CIVIL ENGINEERING INTERNATIONAL SEMINAR of IASS POLISH CHAPTER Organized by Polish Chapter of International Association for Shell

Overloading of operators cont.● Classic mode

– a:=1, b:= 2 – integer values

– c := a + b, c = 3 – integer value

● Overloading operators

– A – matrix, dimension: n x n

– B – matrix, dimension: n x n

– C : = A + B - matrix, dimension n x n

– D : = A * B – matrix, dimension n x n

Page 10: LIGHTWEIGHT STRUCTURES in CIVIL ENGINEERING INTERNATIONAL SEMINAR of IASS POLISH CHAPTER Organized by Polish Chapter of International Association for Shell

FEMA System

● Designed for matrices and hypermatrices operations

● Modular system for modular operations(parallelization enabled)

● Maximum dimension of data sets, minimum time of processing

Page 11: LIGHTWEIGHT STRUCTURES in CIVIL ENGINEERING INTERNATIONAL SEMINAR of IASS POLISH CHAPTER Organized by Polish Chapter of International Association for Shell

Proposed approach

● Overloading matrix operations● Replacing copying of matrices – with commands

from FEMA system● Dividing task into subtasks● Writing steering files for every subtask● Sending steering files to nodes of clusters● Processing calculations in professional

system(FEMA)● Aggregation of calculations' results

Page 12: LIGHTWEIGHT STRUCTURES in CIVIL ENGINEERING INTERNATIONAL SEMINAR of IASS POLISH CHAPTER Organized by Polish Chapter of International Association for Shell

Example

● Adding matrices:– in source code: C = A + B– in result : PHAH

ABC

● Multiplying matrices:– in source code: C = A * B– in result : PHMH

ABC

Page 13: LIGHTWEIGHT STRUCTURES in CIVIL ENGINEERING INTERNATIONAL SEMINAR of IASS POLISH CHAPTER Organized by Polish Chapter of International Association for Shell

Appendix: Parallel example● Steering file is read by master-program

● Worker-program is invoked

● Master-program sends steering file to worker

● Worker-program writes steering file to hard-disk

● Worker-program invokes FEMA system

● FEMA system read task-definition and input data

● FEMA system executes operations and writes results to hard-disk

Page 14: LIGHTWEIGHT STRUCTURES in CIVIL ENGINEERING INTERNATIONAL SEMINAR of IASS POLISH CHAPTER Organized by Polish Chapter of International Association for Shell
Page 15: LIGHTWEIGHT STRUCTURES in CIVIL ENGINEERING INTERNATIONAL SEMINAR of IASS POLISH CHAPTER Organized by Polish Chapter of International Association for Shell

Steering file example (fema.CIN)

● DDEX● DEX-BAT● DDEX7● 2● 3● Y● Y● N● N● END● END

Page 16: LIGHTWEIGHT STRUCTURES in CIVIL ENGINEERING INTERNATIONAL SEMINAR of IASS POLISH CHAPTER Organized by Polish Chapter of International Association for Shell

Console output● [1:t40005] Master process..262149..[ bind and ready to distribute tasks ]..● [1:t40005] Master [262149]..Checking steering-file [/tmp/fema.CIN]

structure...OK● [1:t40005] Worker-process..ID...262150: [ ready to execute tasks ]● [1:t40005] Process: [262149] ready to send steering file..● [1:t40006] Process: [262150] ready to get steering file..● [1:t40005] [262149]..We've read: ● [1:t40005] DDEX● [1:t40005] DEX-BAT● [1:t40005] DDEX7● [1:t40005] 2● [1:t40005] 3● [1:t40005] Y● [1:t40005] Y● [1:t40005] N● [1:t40005] N● [1:t40005] END● [1:t40005] END● [1:t40005] END ● [1:t40005] Process [262149]..sending steering file to worker(s)..● [1:t40006] Process: [262150] retrieved cmd:● [1:t40006] ..DDEX● [1:t40006] DEX-BAT● [1:t40006] DDEX7● [1:t40006] 2● [1:t40006] 3● [1:t40006] Y● [1:t40006] Y● [1:t40006] N● [1:t40006] N

Page 17: LIGHTWEIGHT STRUCTURES in CIVIL ENGINEERING INTERNATIONAL SEMINAR of IASS POLISH CHAPTER Organized by Polish Chapter of International Association for Shell

● [1:t40006] END● [1:t40006] END● [1:t40006] END● [1:t40005] Process: [262149] - retrieved confirmation..● [1:t40005] Process: [262149] exiting..● [1:t40005] EOF● [1:t40006] ....confirmation sent to master..● [1:t40006] Process: [262150]..Attempting to write steering file

[/home/pvm3/bin/LINUX/FEMA/task/fema.CIN]..● [1:t40006] Process: [262150] - [ OK ] file has been written● [1:t40006] Process: [262150]..Attempting to run FEMA system..● [1:t40006] Process: [262150]..checking for task-definition file..● [1:t40006] Process: [262150] - [ OK ] task-definition file is proper..● [1:t40006] Process: [262150]..running FEMA system..● [1:t40006] sh: CLS: command not found● [1:t40006] sh: PAUSE: command not found● [1:t40006] sh: CLS: command not found● [1:t40006] sh: CLS: command not found● [1:t40006] sh: CLS: command not found● [1:t40006]

[34;1m********************************************************************************

● [1:t40006] WELCOME TO FEMA DATABASE MADE BY FEMA ENGINEERING LTD● [1:t40006] YOU HAVE SELECTED /home/pvm3/bin/LINUX/f88.exe,● [1:t40006] WITH /home/pvm3/bin/LINUX/FEMA/task/fema.INP AS ARGUMENT● [1:t40006]

********************************************************************************

● [1:t40006] [0m****************************************************************************

● [1:t40006] EOF