Skip to content

Feedback for "fix13"

mkraska edited this page Nov 23, 2024 · 4 revisions

[txt, isOK]: fb_fix13(o, n, i, description)

  • txt feedback text
  • isOK correctness flag
  • o list of objects
  • n names field
  • i index of "fix13" object
  • description string with Text to identify the object for the user

[txt, isOK]: fb_fix13_name(o, n, i)

  • txt feedback text
  • isOK correctness flag
  • o list of objects
  • n names field
  • i index of "fix13" object

These functions provide Feedback for Free Body Diagrams.

Source

"fix13" is a sliding (frictionless) support with a single translational degree of freedom. It is to be replaced by a reaction force and a moment.

Checks done by fb_fix13():

  • Is the object really of type "fix13" (just for developers)?
  • Is the object deactivated?
  • Has meclib found any reactions by proximity check?
  • Are there exactly two reactions?
  • Are one reaction of type "force" and one of type "moment"?
  • Is the force perpendicular to the sliding direction?

Checks done by fb_fix13_names():

  • Do the names of the reactions match the name of the support point?
  • For force reactions
    • Is the name a single character matching the support name
  • For moment reactions:
    • Is the base name equal to M?
    • Does the index match the support name?

Example question: FBD Tutorial Parallelführung (I) at abacus.aalto.fi/develop/4.4beta

image

Typical PRT

Feedback variables:

obj: stackjson_parse(objects);
[text, isOK]: fb_fix13(obj, names, i_fix13, "Parallelführung bei B: ");
[ntext, nOK]: fb_fix13_name(obj, names, i_fix13);

PRT node 1 test for correct direction

Algebraic test for isOK = true and feedback of {@text@} for both branches.

PRT node 2 test for correct name

Algebraic test for nOK = true and feedback of {@ntext@} in the false branch (with penalty of 0.5).

Tryout Space

In order to try code snippets in jsfiddle,

  1. copy the code from the wiki page to the clipboard
  2. follow the link for the JSXGraph version you want to try
  3. Replace the code in the HTML section (contents of <p hidden id="init">) with the content of the clipboard
Clone this wiki locally