As of August 2024, International Journal "Notes on Intuitionistic Fuzzy Sets" is being indexed in Scopus.
Please check our Instructions to Authors and send your manuscripts to nifs.journal@gmail.com. Next issue: September/October 2024.

Open Call for Papers: International Workshop on Intuitionistic Fuzzy Sets • 13 December 2024 • Banska Bystrica, Slovakia/ online (hybrid mode).
Deadline for submissions: 16 November 2024.

Help:Genedit/XML format: Difference between revisions

From Ifigenia, the wiki for intuitionistic fuzzy sets and generalized nets
Jump to navigation Jump to search
 
(5 intermediate revisions by the same user not shown)
Line 2: Line 2:
<pre>
<pre>
<gn>
<gn>
    <transitions>
|    <transitions>
          <transition>
|    |    <transition>                           //  1+ transitions
              <inputs>
|    |    |    <inputs>
                    <input>
|    |    |    |    <input>                     //  1+ inputs
                        <arc>
|    |    |    |    |    <arc>                   //  exactly 1 arc per input
                              <point/>
|    |    |    |    |    |    <point/>          //  2+ points
                              ...
|    |    |    |    |    |    <point/>
                              <point/>
|    |    |    |    |    |    ...
                        </arc>
|    |    |    |    |    </arc>
                    </input>
|    |    |    |    </input>
                    <input>
|    |    |    |    ...
                    ....
|    |    |    </inputs>
                    </input>
|    |    |    <outputs>
                    .....
|    |    |    |    <output>                    //  1+ outputs
                    <input>
|    |    |    |    |    <arc>                  //  exactly 1 arc per output
                    ....
|    |    |    |    |    |    <point/>          //  2+ points
                    </input>
|    |    |    |    |    |    <point/>
              </inputs>
|    |    |    |    |    |    ...
 
|    |    |    |    |    </arc>
 
|    |    |    |    </output>
|    |    |    |    ...
|    |    |    </outputs>
|    |    |    <predicates>
|    |    |    |    <predicate>                 //  number of predicates <= number of inputs * number of outputs
|    |    |    |    |    value
|    |    |    |    </predicate>
|    |    |    |    ...
|    |    |    </predicates>
|    |    </transition>
|    |    ...
|    </transitions>
|    <places>
|    |    <place/>                               //  1+ places
|    |    ...
|    </places>
|    <tokens>
|    |    <token>                                //  1+ tokens
|    |    |    <char>                            //  0+ token characteristic
|    |    |    ...
|    |    |    </char>
|    |    </token>
|    |    ...
|    </tokens>
|    </tokens>
|    <functions>                                 //  to be continued in a separate section
|    ...
|    </functions>
</gn>
</pre>
</pre>


Line 27: Line 55:


{| width="100%" class="wikitable" style="font-family:courier;"
{| width="100%" class="wikitable" style="font-family:courier;"
| width="30%" | Tag
! width="30%" | Tag
| width="30%" | Tag parameters
! width="30%" | Tag parameters
| width="40%" | Tag body
! width="40%" | Tag body


|- valign="top"
|- valign="top"

Latest revision as of 23:39, 13 April 2010

XML tags: Logical order

<gn>
|    <transitions>
|    |    <transition>                           //  1+ transitions
|    |    |    <inputs>
|    |    |    |    <input>                      //  1+ inputs
|    |    |    |    |    <arc>                   //  exactly 1 arc per input
|    |    |    |    |    |    <point/>           //  2+ points
|    |    |    |    |    |    <point/>
|    |    |    |    |    |    ...
|    |    |    |    |    </arc>
|    |    |    |    </input>
|    |    |    |    ...
|    |    |    </inputs>
|    |    |    <outputs>
|    |    |    |    <output>                     //  1+ outputs
|    |    |    |    |    <arc>                   //  exactly 1 arc per output
|    |    |    |    |    |    <point/>           //  2+ points
|    |    |    |    |    |    <point/>
|    |    |    |    |    |    ...
|    |    |    |    |    </arc>
|    |    |    |    </output>
|    |    |    |    ...
|    |    |    </outputs>
|    |    |    <predicates>
|    |    |    |    <predicate>                  //  number of predicates <= number of inputs * number of outputs
|    |    |    |    |    value
|    |    |    |    </predicate>
|    |    |    |    ...
|    |    |    </predicates>
|    |    </transition>
|    |    ...
|    </transitions>
|    <places>
|    |    <place/>                               //  1+ places
|    |    ...
|    </places>
|    <tokens>
|    |    <token>                                //  1+ tokens
|    |    |    <char>                            //  0+ token characteristic
|    |    |    ...
|    |    |    </char>
|    |    </token>
|    |    ...
|    </tokens>
|    </tokens>
|    <functions>                                 //  to be continued in a separate section
|    ...
|    </functions>
</gn>

XML tags: Alphabetical order

Tag Tag parameters Tag body
<arc> </arc> - <point/>
<char> </char>
  • name
  • type
  • history
  • number
  • array [ 1 2 3]
  • string
  • ..........
<functions> </functions> - -
<gn> </gn>
  • xmlns
  • name
  • time
  • timeStart
  • timeStep
  • root
  • <transitions> </transitions>
  • <places> </places>
  • <tokens> </tokens>
  • <functions> </functions>
<input> </input> ref <arc> </arc>
<inputs> </inputs> - <input> </input>
<output> </output> ref <arc> </arc>
<outputs> </outputs> - <output> </output>
<place/>
  • id
  • name
  • priority
  • capacity
  • char
  • merge
  • positionX
  • positionY
-
<places> </places> - <place> </place>
<point/>
  • positionX
  • positionY
-
<predicate> </predicate>
  • input
  • output
  • true
  • false
  • ...........
<predicates> </predicates> - <predicate> </predicate>
<token> </token>
  • id
  • name
  • priority
  • host
  • entering
  • leaving
<char> </char>
<tokens> </tokens> - <token> </token>
<transition> </transition>
  • id
  • name
  • priority
  • startTime
  • lifeTime
  • positionX
  • positionY
  • sizeY
  • <inputs> </inputs>
  • <outputs> </outputs>
  • <predicates> </predicates>
<transitions> </transitions> - <transition> </transition>

Example: Defines Chars

<?xml version="1.0" ?>
<gn xmlns="http://www.clbme.bas.bg/GN" name="example-define-chars" time="256" timeStart="0" timeStep="1" root="true">
  <transitions>
    <transition id="T" name="T" priority="0" startTime="0" lifeTime="-1" positionX="130" positionY="100" sizeY="100">
      <inputs>
        <input ref="LStart">
          <arc>
            <point positionX="80" positionY="140"/>
            <point positionX="130" positionY="140"/>
          </arc>
        </input>
      </inputs>
      <outputs>
        <output ref="LEnd">
          <arc>
            <point positionX="130" positionY="140"/>
            <point positionX="180" positionY="140"/>
          </arc>
        </output>
      </outputs>
      <predicates>
        <predicate input="LStart" output="LEnd">true</predicate>
      </predicates>
    </transition>
  </transitions>
  <places>
    <place id="LStart" name="LStart" priority="1" capacity="-1" char="CharLStart" merge="false" positionX="80" positionY="140"/>
    <place id="LEnd" name="LEnd" priority="1" capacity="-1" char="CharLEnd" merge="false" positionX="180" positionY="140"/>
  </places>
  <tokens>
    <token id="Tkn" name="Tkn" priority="0" host="LStart" entering="0" leaving="-1">
      <char name="Default" type="double" history="1">0</char>
      <char name="array" type="vector" history="1">[ 1 2 3]</char>
      <char name="testDouble" type="double" history="1">0</char>
    </token>
  </tokens>
  <functions><![CDATA[; CHAR FUNCTIONS
; ----------


(defun getParam "" (tkn param) (distribution)

	(if (= (get-named tkn (+ param "/type")) "explicit") 
	
	;--------- explicit parameter
		(get-named tkn param) 
	
	;---------- manual parameter?
	
	(if (= (get-named tkn (+ param "/type")) "manual") 
	
	(begin
	
		(print "Please enter the value of " param " :")
		(read-double)
	
	);begin manual parameter
	
	;--------- random parameter
	
		(begin
		
			(let distribution (get-named tkn (+ param "/distribution")))


			(if (= distribution "uniform")
			
				;------------ uniform distribution
				
				(random (get-named tkn (+ param "/interval-end")))
				
				;---------------------------------
				
				(if (= distribution "normal")
				
				;------------ normal distribution
				
					(random-normal (get-named tkn (+ param "/mean"))
												 (get-named tkn (+ param "/variance")))
					
				;--------------------------------
					(if (= distribution "exponential")
					
				;------------ exponential distribution	
					(random-exp (get-named tkn (+ param "/mean")))
											
					;---------------------------------
					(+ 0) 
					
					);if exp
				);if norm
			);if uniform
		
		);begin
	 );if manual
	);if explicit
); defun

(defun CharLStart  "" () ()
 
   (print "start")
   ) 

(defun CharLEnd  "" () ()
	 (def-ch tokenobj )
	 (print (xml-output tokenobj))
	 (print "Parameter 'array': " (getParam tokenobj "array")) (newline)
	 (print "Parameter 'testDouble': " (getParam tokenobj "testDouble")) (newline)
)]]></functions>
</gn>