Wiki-Quellcode von Numerische Variablen
Version 326.1 von Carina Enke am 06.03.2020
Zeige letzte Bearbeiter
author | version | line-number | content |
---|---|---|---|
1 | {{sv-translation language="de"}} | ||
2 | {{layout}} | ||
3 | {{layout-section ac:type="single"}} | ||
4 | {{layout-cell}} | ||
5 | \\ | ||
6 | {{/layout-cell}} | ||
7 | {{/layout-section}} | ||
8 | |||
9 | {{layout-section ac:type="two_right_sidebar"}} | ||
10 | {{layout-cell}} | ||
11 | Sie können ganzzahlige oder gebrochene Variablen-Werte generieren. Hierfür stehen Ihnen die Variablen-Typen //**Ganze Zahl**// und //**Gleitkommazahl** //zur Verfügung. | ||
12 | |||
13 | [[image:attach:Editor - Ganzzahlvariable Typauswahl_de.png]] | ||
14 | |||
15 | Nachfolgend werden Ihnen die Möglichkeiten zur Wertsetzung von numerischen Variablen vorgestellt, sowie die Möglichkeit, die Anzeige-Genauigkeit von Gleitkommazahlen zu definieren. | ||
16 | Setzen Sie für eine numerische Variable keinen Wert, wird die Variable mit 0 initialisiert. | ||
17 | |||
18 | [[image:attach:Editor - Ganzzahlvariable Wertsetzung_de.png]] | ||
19 | |||
20 | (% class="confluence-embedded-file-wrapper image-center-wrapper confluence-embedded-manual-size" %) | ||
21 | |||
22 | {{/layout-cell}} | ||
23 | |||
24 | {{layout-cell}} | ||
25 | {{scroll-ignore}} | ||
26 | {{panel borderColor="#ddd" bgColor="#f0f0f0" borderStyle="solid" title="Inhalt"}} | ||
27 | |||
28 | |||
29 | {{toc/}} | ||
30 | {{/panel}} | ||
31 | |||
32 | {{panel borderColor="#ddd" bgColor="#f0f0f0" borderStyle="solid" title="Anwendungsbeispiele"}} | ||
33 | * [[Beispiel "Wahrscheinlichkeit">>doc:Beispiele zum Einsatz von Variablen]] | ||
34 | * [[Beispiel "Hypotenuse">>doc:Beispiele zum Einsatz von Variablen]] | ||
35 | * [[Beispiel "Transport" - Einsatz von Zufallsparametern>>doc:Beispiele zum Einsatz von Variablen]] | ||
36 | {{/panel}} | ||
37 | |||
38 | {{panel borderColor="#ddd" bgColor="#f0f0f0" borderStyle="solid" title="Verwandte Themen"}} | ||
39 | * [[Berechnungsaufgabe (Lückentext)>>doc:Berechnungsaufgabe]] | ||
40 | * [[Formelvergleich (Lückentext)>>doc:Formelvergleich]] | ||
41 | {{/panel}} | ||
42 | |||
43 | {{panel borderColor="#ddd" bgColor="#f0f0f0" borderStyle="solid" title="Weiterführende Informationen"}} | ||
44 | * [[MAXIMA Manual>>url:http://maxima.sourceforge.net/docs/manual/de/maxima.html||shape="rect"]] | ||
45 | * [[MAXIMA Good-Practice-Beispiele>>url:https://bildungsportal.sachsen.de/opal/auth/RepositoryEntry/5499682817/CourseNode/93229879750473/wiki/Index||shape="rect"]] | ||
46 | * [[MAXIMA Systeminformationen>>url:http://maxima.sourceforge.net/||rel="nofollow" shape="rect" class="external-link"]] | ||
47 | {{/panel}} | ||
48 | {{/scroll-ignore}} | ||
49 | {{/layout-cell}} | ||
50 | {{/layout-section}} | ||
51 | |||
52 | {{layout-section ac:type="single"}} | ||
53 | {{layout-cell}} | ||
54 | == Wertebereich == | ||
55 | |||
56 | Für numerische Variablen kann ein Wertebereich definiert werden. Der Variablen-Wert wird zufällig innerhalb des Wertebereiches ermittelt. Dabei werden die angegebenen Grenzen in die Auswahl einbezogen. Für Variablen vom Typ //**Ganze Zahl**// kann zusätzlich zu den Grenzen (Einstellung Minimum und Maximum) die Schrittweite (Einstellung Schritte) bestimmt werden. | ||
57 | |||
58 | **Mögliche Eingaben sind beispielsweise:** | ||
59 | |||
60 | * //Wertebereich: Minimum=2, Maximum=11, Schritte=3: //Es sind folgende Werte möglich {2, 5, 8, 11}. Bei Verwendung der Variable wird ein Wert zufällig ausgewählt bspw. 2. | ||
61 | |||
62 | [[image:attach:Editor - Bildvariable Wertsetzung Wertebereich_de.png]] | ||
63 | |||
64 | \\ | ||
65 | |||
66 | {{info}} | ||
67 | Folgende Beispiele zum Einsatz von numerischen Variablen zur Generierung von Zufallswerten zeigen typische Anwendungsszenarien: | ||
68 | |||
69 | * [[Beispiel "Wahrscheinlichkeit">>doc:Beispiele zum Einsatz von Variablen]] | ||
70 | * [[Beispiel "Transport" - Einsatz von Zufallsparametern>>doc:Beispiele zum Einsatz von Variablen]] | ||
71 | {{/info}} | ||
72 | |||
73 | == Wert (Direkte Wert-Setzung) == | ||
74 | |||
75 | Sie können allen Variablen-Typen einen Wert direkt zuweisen und die Variable mit diesem Wert initialisieren. Der Wert kann später in Abhängigkeit anderer Variablen geändert werden (vgl. Bedingungen). | ||
76 | |||
77 | **Mögliche Eingaben sind beispielsweise:** | ||
78 | |||
79 | * //Wert: 5~:// Die Variable wird auf den Wert 5 gesetzt. | ||
80 | * //Wert: -2,25: //Die Variable wird auf den Wert -2,25 gesetzt. | ||
81 | |||
82 | == Zufällige Auswahl == | ||
83 | |||
84 | Definieren Sie eine Werte-Liste, aus welcher zufällig ein Wert ausgewählt wird. Die alternativen Werte werden in der Liste durch einen Zeilenumbruch oder ein Semikolon getrennt. | ||
85 | |||
86 | **Mögliche Eingaben sind beispielsweise:** | ||
87 | |||
88 | * //Zufällige Auswahl: -5; -3; 3; 5: //Es wird zufällig einer der angegebenen Werte ausgewählt bspw. -5. | ||
89 | * //Zufällige Auswahl: 0; 12,25; 13,5~:// Es wird zufällig einer der angegebenen Werte ausgewählt bspw. 12,25. | ||
90 | |||
91 | == Berechnung (MAXIMA) == | ||
92 | |||
93 | Die ONYX Testsuite ist mit dem [[Computer-Algebra-System MAXIMA>>url:http://maxima.sourceforge.net/||shape="rect"]] gekoppelt. Sie können Variablenwerte auf Basis anderer Variablen berechnen. Geben Sie hierfür die Berechnungsvorschrift in MAXIMA-Schreibweise an. | ||
94 | Detaillierte Hinweise zur MAXIMA-Schreibweise erhalten Sie im [[MAXIMA Benutzerhandbuch (Manual)>>url:http://maxima.sourceforge.net/docs/manual/de/maxima.html||shape="rect"]]. Eine wertvolle Zusammenstellung von Beispielumsetzungen finden Sie in Form eines Wikis unter [[MAXIMA Good-Practice-Beispiele>>url:https://bildungsportal.sachsen.de/opal/auth/RepositoryEntry/5499682817/CourseNode/93229879750473/wiki/Index||shape="rect"]]. | ||
95 | |||
96 | **Mögliche Eingaben sind beispielsweise:** | ||
97 | |||
98 | * //Berechnung (MAXIMA): 5+{a}: //Es wird die Summe aus 5 und dem Variablenwert {a} berechnet. Die Variable {a} muss zuvor definiert sein. | ||
99 | * //Berechnung (MAXIMA): sqrt({a})/(5+sqrt({b}))~:// MAXIMA unterstützt mathematische Ausdrücke wie sqrt() für die Quadratwurzel. | ||
100 | * //Berechnung (MAXIMA): 2*sin({a})+log({b}): //Ebenso können trigonometrische Funktionen oder die Logarithmusfunktion genutzt werden. | ||
101 | |||
102 | [[image:attach:Editor - Bildvariable Wertsetzung Berechnung Maxima_de.png]] | ||
103 | |||
104 | \\ | ||
105 | |||
106 | {{info}} | ||
107 | Folgendes Beispiele zum Einsatz von numerischen Variablen zur Generierung von Zufallswerten zeigen typische Anwendungsszenarien: | ||
108 | |||
109 | * [[Beispiel "Hypotenuse">>doc:Beispiele zum Einsatz von Variablen]] | ||
110 | * [[Beispiel "Transport" - Einsatz von Zufallsparametern>>doc:Beispiele zum Einsatz von Variablen]] | ||
111 | {{/info}} | ||
112 | |||
113 | == Einstellung: Anzeige formatieren == | ||
114 | |||
115 | Für Variablen vom Typ Gleitkommazahl kann für die Anzeige die **Anzahl der Dezimalstellen** konfiguriert werden. Bitte beachten Sie, dass die Einstellung nur die Anzeige, nicht aber die Rechengenauigkeit und den Lösungsvergleich beeinflusst. Das bedeutet: Wird die Variable für die Berechnung weiterer Variablen genutzt, wird der vollständige, ungerundete Wert zur Berechnung verwendet. Ist die Variable als Lösung für eine Lücke (Berechnungsaufgabe) hinterlegt, wird die konfigurierte Anzahl der Dezimalstellen für die Lösungsanzeige verwendet, nicht aber für den Lösungsvergleich. | ||
116 | |||
117 | [[image:attach:Editor - Formatierung der Dezimalstellenanzeige_de.png]] | ||
118 | |||
119 | (% class="confluence-embedded-file-wrapper image-center-wrapper confluence-embedded-manual-size" %) | ||
120 | |||
121 | |||
122 | (% class="confluence-embedded-file-wrapper image-center-wrapper confluence-embedded-manual-size" %) | ||
123 | |||
124 | |||
125 | (% class="confluence-embedded-file-wrapper image-center-wrapper confluence-embedded-manual-size" %) | ||
126 | |||
127 | |||
128 | (% class="confluence-embedded-file-wrapper image-center-wrapper confluence-embedded-manual-size" %) | ||
129 | |||
130 | |||
131 | {{info}} | ||
132 | Möchten Sie erreichen, dass der Teilnehmer Berechnungsaufgaben nur mit einer bestimmten Genauigkeit lösen muss, verwenden Sie die Einstellung zur Definition eines [[Toleranzbereiches >>url:https://www.bps-system.de/help/display/ONYX/Berechnungsaufgabe#Berechnungsaufgabe-Schritt5%28optional%29:DefinitioneinesToleranzbereiches||shape="rect"]]im Bearbeitungsfenster der Lücke. | ||
133 | {{/info}} | ||
134 | {{/layout-cell}} | ||
135 | {{/layout-section}} | ||
136 | {{/layout}} | ||
137 | {{/sv-translation}} | ||
138 | |||
139 | {{sv-translation language="en"}} | ||
140 | {{layout}} | ||
141 | {{layout-section ac:type="two_right_sidebar"}} | ||
142 | {{layout-cell}} | ||
143 | For integer or fractional variable values, select the type // **Integer** //or // **Floating point** //. | ||
144 | |||
145 | [[image:attach:Editor - Ganzzahlvariable Typauswahl_de.png]] | ||
146 | |||
147 | To alter the value for the numerical variable, different options are available, which will be explained in the following sections, just as the possibility to define the display accuracy of floating-point numbers. If a numerical variable is not assigned a value, the variable will be initialised with 0. | ||
148 | |||
149 | [[image:attach:Editor - Ganzzahlvariable Wertsetzung_de.png]] | ||
150 | {{/layout-cell}} | ||
151 | |||
152 | {{layout-cell}} | ||
153 | {{scroll-ignore}} | ||
154 | {{panel borderColor="#ddd" bgColor="#f0f0f0" borderStyle="solid" title="Content"}} | ||
155 | |||
156 | |||
157 | {{toc/}} | ||
158 | {{/panel}} | ||
159 | |||
160 | {{panel title="Application examples"}} | ||
161 | * [[Example "Probability">>url:https://www.bps-system.de/help/display/ONYXintern/.Beispiele+zum+Einsatz+von+Variablen+v8.X||shape="rect"]] | ||
162 | * [[Example "Hypotenuse">>url:https://www.bps-system.de/help/display/ONYXintern/.Beispiele+zum+Einsatz+von+Variablen+v8.X||shape="rect"]] | ||
163 | * [[Example "Transport" - Use of random parameters>>url:https://www.bps-system.de/help/display/ONYXintern/.Beispiele+zum+Einsatz+von+Variablen+v8.X||shape="rect"]] | ||
164 | {{/panel}} | ||
165 | |||
166 | {{panel title="Related topics"}} | ||
167 | * [[Calculation interaction>>url:https://www.bps-system.de/help/display/ONYXintern/.Berechnungsaufgabe+v8.X||shape="rect"]] | ||
168 | * [[Formula comparison>>url:https://www.bps-system.de/help/display/ONYXintern/.Formelvergleich+v8.X||shape="rect"]] | ||
169 | {{/panel}} | ||
170 | |||
171 | {{panel borderColor="#ddd" bgColor="#f0f0f0" borderStyle="solid" title="Further information"}} | ||
172 | * [[MAXIMA manual>>url:http://maxima.sourceforge.net/docs/manual/maxima.html||shape="rect"]] | ||
173 | * [[MAXIMA good practice examples>>url:https://bildungsportal.sachsen.de/opal/auth/RepositoryEntry/5499682817/CourseNode/93229879750473/wiki/Index||shape="rect"]] | ||
174 | * [[MAXIMA system information>>url:http://maxima.sourceforge.net/||rel="nofollow" shape="rect" class="external-link"]] | ||
175 | {{/panel}} | ||
176 | {{/scroll-ignore}} | ||
177 | {{/layout-cell}} | ||
178 | {{/layout-section}} | ||
179 | |||
180 | {{layout-section ac:type="single"}} | ||
181 | {{layout-cell}} | ||
182 | == Range == | ||
183 | |||
184 | For numerical variables, a value range can be defined. The variable value will be randomly determined within the defined value range. Please note that the specified limits are included in the selection. For variables of the type //**Integer** //, the step size (setting steps) can be determined in addition to the limits (setting minimum and maximum). | ||
185 | |||
186 | **Possible entries are for example:** | ||
187 | |||
188 | * //Range//~:// Minimum=2//,// maximum=11//,// steps=3//: The following values are possible {2, 5, 8, 11}. When the variable is used, a value will be randomly selected, for example 2. | ||
189 | \\[[image:attach:Editor - Bildvariable Wertsetzung Wertebereich_de.png]] | ||
190 | |||
191 | {{info}} | ||
192 | The following examples for the use of numerical variables to generate random values show typical application scenarios: | ||
193 | |||
194 | * [[Example "Probability">>url:https://www.bps-system.de/help/display/ONYXintern/.Beispiele+zum+Einsatz+von+Variablen+v8.X||shape="rect"]] | ||
195 | * [[Example "Transport" - Use of random parameters>>url:https://www.bps-system.de/help/display/ONYXintern/.Beispiele+zum+Einsatz+von+Variablen+v8.X||shape="rect"]] | ||
196 | {{/info}} | ||
197 | |||
198 | == Value (direct value assignment) == | ||
199 | |||
200 | You can directly assign a value to all types of variables in order to initialise them. Later on, the value can be changed depending on other variables (cf. conditions). | ||
201 | |||
202 | **Possible entries are for example:** | ||
203 | |||
204 | * //Value//~:// 5//~:// //The variable is assigned the value 5. | ||
205 | * //Value//~:// -2.25//~:// //The variable is assigned the value -2.25. | ||
206 | |||
207 | == Random == | ||
208 | |||
209 | Define a value list from which a value is randomly selected. The alternative values are separated by a line break or semicolon. | ||
210 | |||
211 | **Possible entries are for example:** | ||
212 | |||
213 | * //Random selection//~:// -5//;// -3//;// 3//;// 5//~:// //One of the specified values will be randomly selected, for example 5. | ||
214 | * //Random selection//~:// 0//;// 12.25//;// 13.5//: One of the specified values will be randomly selected, for example 12.25. | ||
215 | |||
216 | == Calculation (MAXIMA) == | ||
217 | |||
218 | The ONYX Testsuite is connected with the [[computer algebra system MAXIMA>>url:http://maxima.sourceforge.net/||shape="rect"]], which allows you to calculate variable values on the basis of other variables. To do this, you need to indicate the calculation rule in MAXIMA notation. | ||
219 | |||
220 | For further information on the MAXIMA notation, please refer to the [[MAXIMA manual>>url:http://maxima.sourceforge.net/docs/manual/de/maxima.html||shape="rect"]]. A valuable compilation of examples can be found in the form of a wiki under [[MAXIMA good practice examples>>url:https://bildungsportal.sachsen.de/opal/auth/RepositoryEntry/5499682817/CourseNode/93229879750473/wiki/Index||shape="rect"]]. | ||
221 | |||
222 | **Possible entries are for example:** | ||
223 | |||
224 | * //Calculation (MAXIMA)//~:// 5+{a}//: The sum of 5 and the variable value {a} is calculated. Please note that the variable {a} must have been previously defined. | ||
225 | * //Calculation (MAXIMA)//~:// sqrt({a})/(5+sqrt({b}))//~:// //MAXIMA supports mathematical expressions such as sqrt() for square root. | ||
226 | * //Calculation (MAXIMA)//~:// 2*sin({a})+log({b})//: Further, it is possible to use trigonometric functions or the logarithm function. | ||
227 | \\[[image:attach:Editor - Bildvariable Wertsetzung Berechnung Maxima_de.png]] | ||
228 | |||
229 | |||
230 | |||
231 | {{info}} | ||
232 | The following examples for the use of numerical variables to generate random values show typical application scenarios: | ||
233 | |||
234 | * [[Example "Hypotenuse">>url:https://www.bps-system.de/help/display/ONYXintern/.Beispiele+zum+Einsatz+von+Variablen+v8.X||shape="rect"]] | ||
235 | * [[Example "Transport" - Use of random parameters>>url:https://www.bps-system.de/help/display/ONYXintern/.Beispiele+zum+Einsatz+von+Variablen+v8.X||shape="rect"]] | ||
236 | {{/info}} | ||
237 | |||
238 | == Setting: Format display == | ||
239 | |||
240 | For variables of the type floating point, the **number of decimal places **can be configured for the display. Please note that this setting only affects the display, not the computational accuracy and the solution comparison. This means: If the variable is used for the calculation of additional variables, the complete unrounded value will be used for the calculation. If the variable is stored as a solution for a gap (calculation interaction), the configured number of decimal places will be used for the solution display, but not for the solution comparison. | ||
241 | |||
242 | |||
243 | |||
244 | [[image:attach:Editor - Formatierung der Dezimalstellenanzeige_de.png]] | ||
245 | |||
246 | |||
247 | |||
248 | |||
249 | |||
250 | (% class="confluence-embedded-file-wrapper image-center-wrapper confluence-embedded-manual-size" %) | ||
251 | |||
252 | |||
253 | (% class="confluence-embedded-file-wrapper image-center-wrapper confluence-embedded-manual-size" %) | ||
254 | |||
255 | |||
256 | {{info}} | ||
257 | If you want the participant to solve calculation tasks with a certain precision, use the setting for defining a [[tolerance range>>url:https://www.bps-system.de/help/display/ONYX/Berechnungsaufgabe#Berechnungsaufgabe-Schritt5(optional):DefinitioneinesToleranzbereiches||shape="rect"]] in the edit window of the gap. | ||
258 | {{/info}} | ||
259 | {{/layout-cell}} | ||
260 | {{/layout-section}} | ||
261 | {{/layout}} | ||
262 | {{/sv-translation}} |