Code covered by the BSD License  

Highlights from
Bond graph add-on block library BG V.2.1

image thumbnail
from Bond graph add-on block library BG V.2.1 by Gert-Helge Geitner
Block library enables the graphical programming of Bond Graphs using standard Simulink and editor.

Fallversuch_S36_P
function Fallversuch_S36_P
%function Fallversuch_S36_P
%x0 -   Anfangshhe              / initial height              // [m]
%c  -   Federsteifigkeit der Hydraulikflssigkeit
%                      / spring coefficient: hydraulic fluid   // [N/m]
%dFall -geschwindigkeitsproportionale Dmpfung beim Fallen und 
%       bei Rcksprung / damping coefficient: fall and rebound // [Ns/m]       
%d  -   geschwindigkeitsproportionale Dmpfung in 
%       Kontaktphase   / damping coefficient: contact phase    // [Ns/m]
%m  -   Masse des Gewichts       / mass of the weight          // [kg]
%g  -   Erdbeschleunigung        / gravity coefficient         // [m/s^2]

assignin('base','x0',1);      % [m]
assignin('base','c',52800);   % [N/m]
assignin('base','dFall',0.4); % [Ns/m]
assignin('base','d',22.2);    % [Ns/m]
assignin('base','m',0.285);   % [Kg]
assignin('base','g',9.81);    % [m/s^2]

%problem: do not limit variable x to a value of zero ("0"), but to a small
%negative value one

txt1='Parameter fr Bondgraph Beispiel Fallversuch / Bohrhammer (Scherf 3.6) geladen!';
txt2='Parameter loaded - bond graph example fall experiment / hammer drill (Scherf 3.6)';
disp([txt1 sprintf('\n') txt2]);

Contact us at files@mathworks.com