Holarch
Розділи курсів

Навчання · Курс 3. Поведінка та архітектура · Розділ 3.1 з 6

3.1 Функції та FFBD 3:52

Задайте функціям функцію верхнього рівня, потім запишіть їхній потік текстом і отримайте FFBD.

Показано Holarch 1.27.

Усі розділи · 3.2 Діаграми Action →

Що ви дізнаєтеся

  • Вибрати функцію верхнього рівня на сторінці «Функціональний аналіз»
  • Декомпозувати функцію на підфункції зв’язком decomposed by
  • Записати функціональний потік текстом зі стрілками, AND і LOOP
  • Прочитати FFBD, яку Holarch малює з потоку, і відкрити власну FFBD підфункції

Упорядкуйте функції Bike-Share Dock під функцією верхнього рівня на сторінці «Функціональний аналіз», додайте функцію, запишіть функціональний потік одним рядком тексту зі стрілками, AND і LOOP, і дозвольте Holarch намалювати з нього функціональну потокову блок-схему (FFBD).

Файли проєкту

  • Початковий проєкт (.holarch.json; Керування проєктами → Файли проєкту ▾ → Імпортувати проєкт (.json)…)
  • Готовий проєкт (.holarch.json; Керування проєктами → Файли проєкту ▾ → Імпортувати проєкт (.json)…)

Відео відтворюється з holarch.app; див. Політику конфіденційності.

Практика

Виконайте це самостійно в Holarch на демопроєкті CubeSat EO-1.

  1. Відкрийте свій демопроєкт EO-1 або створіть його: Керування проєктами → Файли проєкту ▾ → Новий демопроєкт → CubeSat (системна інженерія з посібником).
  2. У Базі даних виберіть F9 Transmit Payload Data. У її розділі Трасування натисніть + поруч із decomposed by (позначте Показати всі зв’язки, якщо його немає в списку), виберіть Новий Action… і створіть Enable Transmitter, Send Data File, Confirm Receipt, Disable Transmitter і Report Pass Summary.
  3. Відкрийте Поведінка → Функціональний аналіз, натисніть Вибрати… поруч із Функція верхнього рівня і виберіть F9 Transmit Payload Data. Вкладка Функції перелічує її п’ять підфункцій.
  4. На вкладці Потік і FFBD натисніть Редагувати як текст…, введіть "Enable Transmitter" -> LOOP[return="next file"]("Send Data File" -> "Confirm Receipt") -> AND("Disable Transmitter" | "Report Pass Summary") і натисніть Застосувати.
  5. Натисніть Відкрити FFBD і знайдіть цикл зі стрілкою повернення та вентиль AND. Потім знову виберіть F0 Perform EO-1 Mission функцією верхнього рівня, відкрийте її FFBD і двічі клацніть F9, щоб відкрити власну FFBD функції F9.
  6. Для покрокового проходження з перевіркою запустіть посібник 4 Functional Analysis (Довідка → Посібники).

Завдання виконано, коли FFBD функції F9 показує Enable Transmitter, цикл із Send Data File і Confirm Receipt зі стрілкою повернення з підписом next file та AND із двома гілками.

Перевірте себе

  1. Навіщо сторінці «Функціональний аналіз» функція верхнього рівня?
  2. Яка різниця між AND і OR у потоці?
  3. Що станеться з функцією, яку ви не включите в текстовий потік?
  4. Ви змінюєте потік на вкладці «Потік і FFBD». Що відбувається з FFBD?
Показати відповіді
  1. Навіщо сторінці «Функціональний аналіз» функція верхнього рівня?

    Сторінка працює від однієї Action: її дочірні елементи за decomposed by — це функції, які вона перелічує, з’єднує потоком і малює. Вибір іншої функції верхнього рівня, як-от F9, показує власну декомпозицію цієї функції.

  2. Яка різниця між AND і OR у потоці?

    AND виконує всі свої гілки паралельно, і потік продовжується, коли кожна гілка завершилася. OR іде рівно однією зі своїх гілок.

  3. Що станеться з функцією, яку ви не включите в текстовий потік?

    Holarch показує її як відсутню в тексті й додає після останнього елемента потоку, тож жодна функція не губиться.

  4. Ви змінюєте потік на вкладці «Потік і FFBD». Що відбувається з FFBD?

    Вона перемальовується. FFBD, дерево функцій і таблиця функцій читають ту саму модель, тож нічого не треба оновлювати вручну.

Докладніше

Стенограма

Показати стенограму (озвучення і те, що на екрані)

Introduction

Welcome to Behavior and Architecture. This track models what the Bike-Share Dock does, what it is made of, how its parts connect, and whether the design adds up.

This first chapter is about functions, and the order they run in.

Functions and their flow

A function is something the system must do, named with a verb: rent a bike, take a payment. A functional flow block diagram, the F F B D, shows the order the functions run in, which ones run at the same time, and which ones repeat.

On screen: Card: functions and the FFBD.

A top-level function

Open Behavior, then Functional Analysis. The page works from one top-level function, and the dock has none yet. The four functions from Getting Started stand on their own.

On screen: Behavior → Functional Analysis: no top-level function.

Click Choose, then Create New. The top-level function is the whole job of the system: Operate the Bike-Share Dock, numbered F zero.

On screen: Choose… → Create New… → F.0 Operate the Bike-Share Dock.

Now put the four functions under it. Open the Database, select Operate the Bike-Share Dock, and in its Trace section, link Rent a Bike, Return a Bike, Charge Bikes and Take Payment under decomposed by.

On screen: Database → F.0 → decomposed by → F.1–F.4.

One function is missing: the dock reports its status, the free bays and the charge levels, to the back office. Create a new Action, F five, Report Dock Status.

On screen: New Entity: Action F.5 Report Dock Status.

Place it in the hierarchy from the other side: show all relations in its Trace section, and under decomposes, link it to Operate the Bike-Share Dock.

On screen: F.5 → decomposes → F.0.

Back in Functional Analysis, the Functions tab lists all five under the top-level function.

On screen: Functional Analysis → Functions.

The flow as text

Open Flow and FFBD. Until someone writes the flow, it simply lists the functions in number order, which says nothing about how they work together.

On screen: Flow & FFBD tab.

Choose Edit as Text. A flow is written like a sentence: function numbers joined by arrows, in the order they run. A rider pays, takes the bike, and later returns it: F four, arrow, F one, arrow, F two.

On screen: Edit as Text → F.4 -> F.1 -> F.2.

After a return, two things happen at the same time: the bike charges, and the dock reports its status. AND opens parallel branches, separated by a bar. Both start together, and the flow goes on when both are done.

On screen: -> AND(F.3 | F.5).

The whole cycle repeats for the next rider. LOOP repeats what is inside its brackets, and return names the arrow that goes back. Wrap the flow in a loop.

On screen: LOOP[return="next rider"]( … ).

The FFBD

The preview below draws the diagram as you type. Apply it.

On screen: Preview → Apply.

Holarch draws the F F B D from that one line: a numbered box for each function, a circle where the AND branches open and close, and the loop with the return arrow labeled next rider.

On screen: The FFBD.

The diagram, the hierarchy and the functions table all read the same model. Change the flow, and the diagram follows.

On screen: The FFBD.

Recap

Let's recap. You created a top-level function, placed the dock's functions under it, wrote their flow as text with arrows, AND and LOOP, and got the F F B D drawn from it.

Next, you take one function apart, step by step, on an action diagram.