@prefix fhir: <http://hl7.org/fhir/> .
@prefix owl: <http://www.w3.org/2002/07/owl#> .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix sct: <http://snomed.info/id/> .
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .

# - resource -------------------------------------------------------------------

<http://hl7.org/fhir/MedicationDispense/meddisp0302> a fhir:MedicationDispense ;
  fhir:nodeRole fhir:treeRoot ;
  fhir:id [ fhir:v "meddisp0302"] ; # 
  fhir:contained ( [
     a fhir:Medication ;
     fhir:id [ fhir:v "med0360" ] ;
     fhir:code [
       fhir:coding ( [
         fhir:system [
           fhir:v "http://hl7.org/fhir/sid/ndc"^^xsd:anyURI ;
           fhir:l <http://hl7.org/fhir/sid/ndc>
         ] ;
         fhir:code [ fhir:v "0169-7501-11" ] ;
         fhir:display [ fhir:v "NOVOLOG, 1 VIAL, GLASS in 1 CARTON (0169-7501-11) > 10 mL in 1 VIAL, GLASS (package)" ]
       ] ) ;
       fhir:text [ fhir:v "Novolog 100u/ml" ]
     ] ;
     fhir:doseForm [
       fhir:coding ( [
         a sct:385219001 ;
         fhir:system [
           fhir:v "http://snomed.info/sct"^^xsd:anyURI ;
           fhir:l <http://snomed.info/sct>
         ] ;
         fhir:code [ fhir:v "385219001" ] ;
         fhir:display [ fhir:v "Solution for injection" ]
       ] )
     ] ;
     fhir:ingredient ( [
       fhir:item [
         fhir:concept [
           fhir:coding ( [
             a sct:325072002 ;
             fhir:system [
               fhir:v "http://snomed.info/sct"^^xsd:anyURI ;
               fhir:l <http://snomed.info/sct>
             ] ;
             fhir:code [ fhir:v "325072002" ] ;
             fhir:display [ fhir:v "Insulin Aspart (substance)" ]
           ] )
         ]
       ] ;
       fhir:strength [
         a fhir:Ratio ;
         fhir:numerator [
           fhir:value [ fhir:v "100"^^xsd:decimal ] ;
           fhir:system [
             fhir:v "http://unitsofmeasure.org"^^xsd:anyURI ;
             fhir:l <http://unitsofmeasure.org>
           ] ;
           fhir:code [ fhir:v "U" ]
         ] ;
         fhir:denominator [
           fhir:value [ fhir:v "1"^^xsd:decimal ] ;
           fhir:system [
             fhir:v "http://unitsofmeasure.org"^^xsd:anyURI ;
             fhir:l <http://unitsofmeasure.org>
           ] ;
           fhir:code [ fhir:v "mL" ]
         ]
       ]
     ] )
  ] ) ; # 
  fhir:status [ fhir:v "in-progress"] ; # 
  fhir:medication [
     fhir:reference [
       fhir:l <#med0360> ;
       fhir:reference [ fhir:v "#med0360" ] ;
       fhir:display [ fhir:v "NOVOLOG, 1 VIAL, GLASS in 1 CARTON (0169-7501-11) > 10 mL in 1 VIAL, GLASS (package)" ]
     ]
  ] ; # 
  fhir:subject [
     fhir:l <http://hl7.org/fhir/Patient/pat1> ;
     fhir:reference [ fhir:v "Patient/pat1" ] ;
     fhir:display [ fhir:v "Donald Duck" ]
  ] ; # 
  fhir:performer ( [
     fhir:function [
       fhir:coding ( [
         fhir:system [
           fhir:v "http://terminology.hl7.org/CodeSystem/medicationdispense-performer-function"^^xsd:anyURI ;
           fhir:l <http://terminology.hl7.org/CodeSystem/medicationdispense-performer-function>
         ] ;
         fhir:code [ fhir:v "finalchecker" ] ;
         fhir:display [ fhir:v "Final Checker" ]
       ] )
     ] ;
     fhir:actor [
       fhir:l <http://hl7.org/fhir/Practitioner/f006> ;
       fhir:reference [ fhir:v "Practitioner/f006" ]
     ]
  ] ) ; # 
  fhir:authorizingPrescription ( [
     fhir:l <http://hl7.org/fhir/MedicationRequest/medrx0321> ;
     fhir:reference [ fhir:v "MedicationRequest/medrx0321" ]
  ] ) ; # 
  fhir:type [
     fhir:coding ( [
       fhir:system [
         fhir:v "http://terminology.hl7.org/CodeSystem/v3-ActCode"^^xsd:anyURI ;
         fhir:l <http://terminology.hl7.org/CodeSystem/v3-ActCode>
       ] ;
       fhir:code [ fhir:v "RFP" ] ;
       fhir:display [ fhir:v "Refill - Part Fill" ]
     ] )
  ] ; # 
  fhir:quantity [
     fhir:value [ fhir:v "10"^^xsd:decimal ] ;
     fhir:system [
       fhir:v "http://unitsofmeasure.org"^^xsd:anyURI ;
       fhir:l <http://unitsofmeasure.org>
     ] ;
     fhir:code [ fhir:v "ml" ]
  ] ; # 
  fhir:daysSupply [
     fhir:value [ fhir:v "30"^^xsd:decimal ] ;
     fhir:unit [ fhir:v "Day" ] ;
     fhir:system [
       fhir:v "http://unitsofmeasure.org"^^xsd:anyURI ;
       fhir:l <http://unitsofmeasure.org>
     ] ;
     fhir:code [ fhir:v "d" ]
  ] ; # 
  fhir:whenPrepared [ fhir:v "2015-01-15T10:20:00Z"^^xsd:dateTime] ; # 
  fhir:whenHandedOver [ fhir:v "2015-01-15T16:20:00Z"^^xsd:dateTime] ; # 
  fhir:dosageInstruction [
     fhir:renderedInstruction [ fhir:v "Inject 10 units subcut 10 minutes before breakfast, 15 units before lunch, 20 units before dinner. Check sugar level before taking Novolog." ] ;
     fhir:step ( [
       fhir:component ( [
         fhir:text [ fhir:v "Before Breakfast" ] ;
         fhir:additionalInstruction ( [
           fhir:text [ fhir:v "Check sugar level before taking Novolog" ]
         ] ) ;
         fhir:timing [
           fhir:repeat [
             fhir:frequency [ fhir:v "1"^^xsd:positiveInteger ] ;
             fhir:period [ fhir:v "1"^^xsd:decimal ] ;
             fhir:periodUnit [ fhir:v "d" ]
           ]
         ] ;
         fhir:doseAndRate ( [
           fhir:type [
             fhir:coding ( [
               fhir:system [
                 fhir:v "http://terminology.hl7.org/CodeSystem/dose-rate-type"^^xsd:anyURI ;
                 fhir:l <http://terminology.hl7.org/CodeSystem/dose-rate-type>
               ] ;
               fhir:code [ fhir:v "ordered" ] ;
               fhir:display [ fhir:v "Ordered" ]
             ] )
           ] ;
           fhir:dose [
             a fhir:Quantity ;
             fhir:value [ fhir:v "10"^^xsd:decimal ] ;
             fhir:unit [ fhir:v "U" ] ;
             fhir:system [
               fhir:v "http://unitsofmeasure.org"^^xsd:anyURI ;
               fhir:l <http://unitsofmeasure.org>
             ] ;
             fhir:code [ fhir:v "U" ]
           ]
         ] )
       ] [
         fhir:text [ fhir:v "15 units before lunch" ] ;
         fhir:additionalInstruction ( [
           fhir:text [ fhir:v "Check sugar level before taking Novolog" ]
         ] ) ;
         fhir:timing [
           fhir:repeat [
             fhir:frequency [ fhir:v "1"^^xsd:positiveInteger ] ;
             fhir:period [ fhir:v "1"^^xsd:decimal ] ;
             fhir:periodUnit [ fhir:v "d" ]
           ]
         ] ;
         fhir:doseAndRate ( [
           fhir:type [
             fhir:coding ( [
               fhir:system [
                 fhir:v "http://terminology.hl7.org/CodeSystem/dose-rate-type"^^xsd:anyURI ;
                 fhir:l <http://terminology.hl7.org/CodeSystem/dose-rate-type>
               ] ;
               fhir:code [ fhir:v "ordered" ] ;
               fhir:display [ fhir:v "Ordered" ]
             ] )
           ] ;
           fhir:dose [
             a fhir:Quantity ;
             fhir:value [ fhir:v "15"^^xsd:decimal ] ;
             fhir:unit [ fhir:v "U" ] ;
             fhir:system [
               fhir:v "http://unitsofmeasure.org"^^xsd:anyURI ;
               fhir:l <http://unitsofmeasure.org>
             ] ;
             fhir:code [ fhir:v "U" ]
           ]
         ] )
       ] [
         fhir:text [ fhir:v "20 units before dinner" ] ;
         fhir:additionalInstruction ( [
           fhir:text [ fhir:v "Check sugar level before taking Novolog" ]
         ] ) ;
         fhir:timing [
           fhir:repeat [
             fhir:frequency [ fhir:v "1"^^xsd:positiveInteger ] ;
             fhir:period [ fhir:v "1"^^xsd:decimal ] ;
             fhir:periodUnit [ fhir:v "d" ]
           ]
         ] ;
         fhir:doseAndRate ( [
           fhir:type [
             fhir:coding ( [
               fhir:system [
                 fhir:v "http://terminology.hl7.org/CodeSystem/dose-rate-type"^^xsd:anyURI ;
                 fhir:l <http://terminology.hl7.org/CodeSystem/dose-rate-type>
               ] ;
               fhir:code [ fhir:v "ordered" ] ;
               fhir:display [ fhir:v "Ordered" ]
             ] )
           ] ;
           fhir:dose [
             a fhir:Quantity ;
             fhir:value [ fhir:v "20"^^xsd:decimal ] ;
             fhir:unit [ fhir:v "U" ] ;
             fhir:system [
               fhir:v "http://unitsofmeasure.org"^^xsd:anyURI ;
               fhir:l <http://unitsofmeasure.org>
             ] ;
             fhir:code [ fhir:v "U" ]
           ]
         ] )
       ] )
     ] )
  ] . # 

<http://hl7.org/fhir/Patient/pat1> a fhir:Patient .

<http://hl7.org/fhir/Practitioner/f006> a fhir:Practitioner .

<http://hl7.org/fhir/MedicationRequest/medrx0321> a fhir:MedicationRequest .

# -------------------------------------------------------------------------------------

