default_graphtheory_linearalg_svg2. UnderstandEasyD1 function process%QUESTION.NUMBER%(QNo) { QT1=QuestionText1%QUESTION.NUMBER% QT2=QuestionText2%QUESTION.NUMBER% ET1%QUESTION.NUMBER%=EquationText1%QUESTION.NUMBER% COR=Correct%QUESTION.NUMBER% Nwidth=getFontSize()/16*185 Nheight=getFontSize()/16*100 a1="" Nwidth=getFontSize()/16*300 Nheight=getFontSize()/16*80 a11="" Nwidth=getFontSize()/16*600 Nheight=getFontSize()/16*150 a111="" a2="" a3="" //ET%QUESTION.NUMBER%=m11+m2+m3+M1+"

" //feedback ANS= "
The vertex set of a graph is simply a set of all the vertices of the graph.

To determine the vertex set of the above graph you have to list all the vertices of the graph that are: "+Correct%QUESTION.NUMBER%+".
"; for (var i=5; iYour answer, {"+document.forms.elements[item].value+"}, was correct.
"} else {document.forms.elements[item+3].value = "Your answer, {"+document.forms.elements[item].value+"}, should have been {"+COR+"}

"+ANS+"

"} document.forms.elements[item+3].value = QuestionText1%QUESTION.NUMBER% + svg%QUESTION.NUMBER% + QuestionText3%QUESTION.NUMBER% + document.forms.elements[item+3].value; } function question%QUESTION.NUMBER%() { n = displayarray(1,5,8,0); do{ A = getrandomsymmetricmatrix(n, n, 0, 1, 1); B = getrandomsymmetricmatrix(n, n, 0, 1, 1); for (i = 1; i <= n-1; i++){ for(j = i+1; j <= n; j++){ A[i][j] = Math.round(Math.random()); B[i][j] = A[i][j]; B[j][i] = B[i][j]; } } degreelist = new Array(n); for(i = 1; i <= n; i++){ degreelist[i-1] = 0; for(j = 1; j <= n; j++){ degreelist[i-1] += (B[i][j]-0); } } listofdegrees = sorting(degreelist,0); seergedfotsil = sorting(degreelist,1); } while (seergedfotsil < 2) Nwidth1 = getFontSize()/16*(n * 45) ; Nheight = getFontSize()/16*(n * 50) ; m1="" m2="" m3="" M1%QUESTION.NUMBER%="" QuestionText1%QUESTION.NUMBER% = "Consider the following graph and input the vertex set:
" QuestionText2%QUESTION.NUMBER% = "Vertex set = {" QuestionText3%QUESTION.NUMBER% = "

Important: input the vertex set in alphabetical order without spaces, separating each vertex with a comma, e.g. A,B,C,...

"; //EquationText1%QUESTION.NUMBER%=m1+m2+m3+M1%QUESTION.NUMBER%+"
"; EquationText1%QUESTION.NUMBER% = ""; //just graph displayed ratio_along_line = 0; filled = 1; // = 1 filled arrow else open double_path_colour = "red"; double_path_skinnyness = 10; svg%QUESTION.NUMBER% = SVG_digraph(A,ratio_along_line,filled,double_path_colour,double_path_skinnyness) + "
" Correct%QUESTION.NUMBER% = ""; for (ivertex = 1; ivertex <=n; ivertex++){Correct%QUESTION.NUMBER% += alphabet(ivertex-1,1)+","} strlength = Correct%QUESTION.NUMBER%.length; Correct%QUESTION.NUMBER% = Correct%QUESTION.NUMBER%.substring(0,strlength-1); // removes last comma //numbers_string=""; //for (i_input = 0; i_input < Alist.length; i_input++){ //numbers_string +=Alist[i_input].toString();} //required_input_string_length%QUESTION.NUMBER% += numbers_string.length; document.write(QuestionText1%QUESTION.NUMBER%+EquationText1%QUESTION.NUMBER%); document.write(svg%QUESTION.NUMBER%+QuestionText2%QUESTION.NUMBER%); document.write("") document.write(" }") document.write(QuestionText3%QUESTION.NUMBER%); document.write("") } if (document.forms.name=="FEEDBACK") {} else {question%QUESTION.NUMBER%()} ]]> "Choice" INCLUDES NOCASE "was Correct"Well done!]]> "Choice" INCLUDES NOCASE "should have been"Please look at the graph carefully. If the answer is still unclear, please write the question down (or print using the print button top right) and ask your teacher/lecturer.]]> OTHERYou should have tried this question!]]> if (document.forms.name=="FEEDBACK") { Count=document.forms.elements.length document.write(document.forms.elements[Count-1].value) var titleofpopup = "Related material"; var help = wheretolook("%QUESTION.TAGS%","%QUESTION.TOPIC%"); document.write("

"+""+"
") } ]]> default_graphtheory_linearalg_svg2. UnderstandIntermediateD1 function process%QUESTION.NUMBER%(QNo) { QT1=QuestionText1%QUESTION.NUMBER% QT2=QuestionText2%QUESTION.NUMBER% ET1%QUESTION.NUMBER%=EquationText1%QUESTION.NUMBER% COR=Correct%QUESTION.NUMBER% Nwidth=getFontSize()/16*185 Nheight=getFontSize()/16*100 a1="" Nwidth=getFontSize()/16*300 Nheight=getFontSize()/16*80 a11="" Nwidth=getFontSize()/16*600 Nheight=getFontSize()/16*150 a111="" a2="" a3="" //ET%QUESTION.NUMBER%=m11+m2+m3+M1+"

" //feedback ANS= "

The vertex set of a graph is simply a set of all the vertices of the graph.

To determine the vertex set of the above graph you have to list all the vertices of the graph. Despite of the fact that presented graph is disconnected with isolated vertices all the shown vertices "+Correct%QUESTION.NUMBER%+" form the vertex set you were asked to define.
"; for (var i=5; iYour answer, {"+document.forms.elements[item].value+"}, was correct.
"} else {document.forms.elements[item+3].value = "Your answer, {"+document.forms.elements[item].value+"}, should have been {"+COR+"}

"+ANS+"

"} document.forms.elements[item+3].value = QuestionText1%QUESTION.NUMBER% + svg%QUESTION.NUMBER% + QuestionText3%QUESTION.NUMBER% + document.forms.elements[item+3].value; } function question%QUESTION.NUMBER%() { n = displayarray(1,5,8,0); A = getrandommatrix(n, n, 0, 1, 1); toss = Math.round(Math.random()); half=Math.floor(n/2); howmany = displayarray(1,1,half,0); selectone = displayarray(howmany,1,n,0); // if toss = 0 A is symmetric toss = 0; for (i = 1; i <= n; i++){ for(j = 1; j <= n; j++){ if(toss == 0){A[i][j] = A[j][i];} for(k = 0; k <= howmany-1; k++){ A[selectone[k]][j] = 0; A[i][selectone[k]] = 0; } } } Nwidth1 = getFontSize()/16*(n * 45) ; Nheight = getFontSize()/16*(n * 50) ; m1="" m2="" m3="" M1%QUESTION.NUMBER%="" QuestionText1%QUESTION.NUMBER% = "Consider the following graph and input the vertex set:
" QuestionText2%QUESTION.NUMBER% = "Vertex set = {" QuestionText3%QUESTION.NUMBER% = "

Important: input the vertex set in alphabetical order without spaces, separating each vertex with a comma, e.g. A,B,C,...

"; //EquationText1%QUESTION.NUMBER%=m1+m2+m3+M1%QUESTION.NUMBER%+"
"; EquationText1%QUESTION.NUMBER% = ""; //just graph displayed if(toss == 0){ratio_along_line = 0.0;}else{ratio_along_line = 0.2; } // places arrow on line: if 0 then no arrow is drawn. filled = 1; // = 1 filled arrow else open double_path_colour = "red"; double_path_skinnyness = 10; svg%QUESTION.NUMBER% = SVG_digraph(A,ratio_along_line,filled,double_path_colour,double_path_skinnyness) + "
" Correct%QUESTION.NUMBER% = ""; for (ivertex = 1; ivertex <=n; ivertex++){Correct%QUESTION.NUMBER% += alphabet(ivertex-1,1)+","} strlength = Correct%QUESTION.NUMBER%.length; Correct%QUESTION.NUMBER% = Correct%QUESTION.NUMBER%.substring(0,strlength-1); // removes last comma //numbers_string=""; //for (i_input = 0; i_input < Alist.length; i_input++){ //numbers_string +=Alist[i_input].toString();} //required_input_string_length%QUESTION.NUMBER% += numbers_string.length; document.write(QuestionText1%QUESTION.NUMBER%+EquationText1%QUESTION.NUMBER%); document.write(svg%QUESTION.NUMBER%+QuestionText2%QUESTION.NUMBER%); document.write("") document.write(" }") document.write(QuestionText3%QUESTION.NUMBER%); document.write("") } if (document.forms.name=="FEEDBACK") {} else {question%QUESTION.NUMBER%()} ]]> "Choice" INCLUDES NOCASE "was Correct"Well done!]]> "Choice" INCLUDES NOCASE "should have been"Please look at the graph carefully. If the answer is still unclear, please write the question down (or print using the print button top right) and ask your teacher/lecturer.]]> OTHERYou should have tried this question!]]> if (document.forms.name=="FEEDBACK") { Count=document.forms.elements.length document.write(document.forms.elements[Count-1].value) var titleofpopup = "Related material"; var help = wheretolook("%QUESTION.TAGS%","%QUESTION.TOPIC%"); document.write("

"+""+"
") } ]]>