Eine aufbereitete Darstellung der Quelle

 
     
 
 
Anforderungen  |   Konzepte  |   Entwurf  |   Entwicklung  |   Qualitätssicherung  |   Lebenszyklus  |   Steuerung
 
 
 
 

Benutzer

Quelle  openmath02.tst   Sprache: unbekannt

 
Spracherkennung für: .tst vermutete Sprache: Unknown {[0] [0] [0]} [Methode: Schwerpunktbildung, einfache Gewichte, sechs Dimensionen]

# openmath, chapter 2

# [ "doc/../gap/omput.gd", 159174 ]

gap> OMPrint( [ 11/2 ] );     
<OMOBJ xmlns="http://www.openmath.org/OpenMath" version="2.0">
 <OMA>
  <OMS cd="list1" name="list"/>
  <OMI>1</OMI>
  <OMA>
   <OMS cd="nums1" name="rational"/>
   <OMI>1</OMI>
   <OMI>2</OMI>
  </OMA>
 </OMA>
</OMOBJ>


# [ "doc/../gap/omput.gd", 176183 ]

gap> OMPrint( "This is a string" );
<OMOBJ xmlns="http://www.openmath.org/OpenMath" version="2.0">
 <OMSTR>This is a string</OMSTR>
</OMOBJ>


# [ "doc/../gap/omput.gd", 185211 ]

gap> OMPrint( 1-2*E(4) );      
<OMOBJ xmlns="http://www.openmath.org/OpenMath" version="2.0">
 <OMA>
  <OMS cd="complex1" name="complex_cartesian"/>
  <OMI>1</OMI>
  <OMI>-2</OMI>
 </OMA>
</OMOBJ>
gap> OMPrint(E(3));       
<OMOBJ xmlns="http://www.openmath.org/OpenMath" version="2.0">
 <OMA>
  <OMS cd="arith1" name="plus"/>
  <OMA>
   <OMS cd="arith1" name="times"/>
   <OMI>1</OMI>
   <OMA>
    <OMS cd="algnums" name="NthRootOfUnity"/>
    <OMI>3</OMI>
    <OMI>1</OMI>
   </OMA>
  </OMA>
 </OMA>
</OMOBJ>


# [ "doc/../gap/omput.gd", 213254 ]

gap> OMPrint( Group( (1,2) ) );
<OMOBJ xmlns="http://www.openmath.org/OpenMath" version="2.0">
 <OMA>
  <OMS cd="permgp1" name="group"/>
  <OMS cd="permutation1" name="right_compose"/>
  <OMA>
   <OMS cd="permut1" name="permutation"/>
   <OMI>2</OMI>
   <OMI>1</OMI>
  </OMA>
 </OMA>
</OMOBJ>
gap> OMPrint( Group( [ [ [ 12 ],[ 01 ] ] ] ) );
<OMOBJ xmlns="http://www.openmath.org/OpenMath" version="2.0">
 <OMA>
  <OMS cd="group1" name="group_by_generators"/>
  <OMA>
   <OMS cd="linalg2" name="matrix"/>
   <OMA>
    <OMS cd="linalg2" name="matrixrow"/>
    <OMI>1</OMI>
    <OMI>2</OMI>
   </OMA>
   <OMA>
    <OMS cd="linalg2" name="matrixrow"/>
    <OMI>0</OMI>
    <OMI>1</OMI>
   </OMA>
  </OMA>
 </OMA>
</OMOBJ>
gap> OMPrint( FreeGroup( 2 ) );                      
<OMOBJ xmlns="http://www.openmath.org/OpenMath" version="2.0">
 <OMA>
  <OMS cd="fpgroup1" name="free_groupn"/>
  <OMI>2</OMI>
 </OMA>
</OMOBJ>


# [ "doc/../gap/omput.gd", 274281 ]

gap> OMString(42);
"<OMOBJ xmlns=\"http://www.openmath.org/OpenMath\" version=\"2.0\"> <OMI>42</OMI> </OMOBJ>"
gap> OMString([1,2]:noomobj);    
"<OMA> <OMS cd=\"list1\" name=\"list\"/> <OMI>1</OMI> <OMI>2</OMI> </OMA>"


# [ "doc/../gap/omget.gd", 4154 ]

gap> txml:=Filename(DirectoriesPackageLibrary("openmath","tst"),"test3.omt");;   
gap> tbin:=Filename(DirectoriesPackageLibrary("openmath","tst"),"test3.bin");;   
gap> xstream := InputTextFile( txml );; bstream := InputTextFile( tbin );;   
gap> x:=OMGetObject(xstream); y:=OMGetObject(bstream);
912873912381273891
912873912381273891
gap> x:=OMGetObject(xstream); y:=OMGetObject(bstream);
E(4)
E(4)
gap> CloseStream(xstream);CloseStream(bstream);


# [ "doc/../gap/omget.gd", 8593 ]

gap> s:="<OMOBJ><OMS cd=\"setname1\" name=\"Z\"/></OMOBJ>";;
gap> EvalOMString(s);
Integers
gap> G:=SL(2,5);; G=EvalOMString(OMString(G));
true


# [ "doc/../gap/omput.gd", 96123 ]

gap> g := [[1,2],[1,0]];;
gap> t := "";
""
gap> s := OutputTextString(t, true);;
gap> w:=OpenMathXMLWriter( s );
<OpenMath XML writer to OutputTextString(0)>
gap> OMPutObject(w, g);
gap> CloseStream(s);
gap> Print(t);
<OMOBJ xmlns="http://www.openmath.org/OpenMath" version="2.0">
 <OMA>
  <OMS cd="linalg2" name="matrix"/>
  <OMA>
   <OMS cd="linalg2" name="matrixrow"/>
   <OMI>1</OMI>
   <OMI>2</OMI>
  </OMA>
  <OMA>
   <OMS cd="linalg2" name="matrixrow"/>
   <OMI>1</OMI>
   <OMI>0</OMI>
  </OMA>
 </OMA>
</OMOBJ>


# [ "doc/../gap/omput.gd", 451460 ]

gap> s:=OMPlainString("<OMS cd=\"nums1\" name=\"pi\"/>");
<OMS cd="nums1" name="pi"/>
gap> OMPrint(s);                                       
<OMOBJ xmlns="http://www.openmath.org/OpenMath" version="2.0">
 <OMS cd="nums1" name="pi"/>
</OMOBJ>


# [ "doc/../gap/testing.gd", 2833 ]

gap> OMTestXML([[1..10],[1/2,2+E(4)],ZmodnZObj(2,6),(1,2),true,"string"]);     
true


# [ "doc/../gap/testing.gd", 5863 ]

gap> OMTestBinary([[1..10],[1/2,2+E(4)],ZmodnZObj(2,6),(1,2),true,"string"]);     
true


[Dauer der Verarbeitung: 0.14 Sekunden, vorverarbeitet 2026-06-26]

                                                                                                                                                                                                                                                                                                                                                                                                     


Neuigkeiten

     Aktuelles
     Motto des Tages

Software

     Quellcodebibliothek
     Eigene Quellcodes
     Fremde Quellcodes
     Suchen

Aktivitäten

     Artikel über Sicherheit
     Anleitung zur Aktivierung von SSL

Muße

     Gedichte
     Musik
     Bilder

Jenseits des Üblichen ....
    

Besucherstatistik

Besucherstatistik