$humantriggeringrule .= "   Annotations: relevant_for " . make_valid_id($drug_label) . "\n";
 if (strlen($logical_description_of_genetic_attributes) != 0) {
     $humantriggeringrule .= "\tEquivalentTo: human and (" . preg_replace('/\\s+/', ' ', trim($logical_description_of_genetic_attributes)) . ")\n";
 }
 $drug_recommendations_info_source = $source_repository . "\t";
 $textualtriggeringrule .= "   Annotations: source \"" . $source_repository . "\"\n";
 $humantriggeringrule .= "   Annotations: source \"" . $source_repository . "\"\n";
 if (isset($textual_description_of_genetic_attributes) && $textual_description_of_genetic_attributes != "") {
     $textualtriggeringrule .= "   Annotations: textual_genetic_description \"" . clean_comment_string($textual_description_of_genetic_attributes) . "\"\n";
     $humantriggeringrule .= "   Annotations: textual_genetic_description \"" . clean_comment_string($textual_description_of_genetic_attributes) . "\"\n";
 }
 $drug_recommendations_info_phenotype = "\t";
 if (isset($phenotype_description) && $phenotype_description != "") {
     $drug_recommendations_info_phenotype = clean_comment_string($phenotype_description) . "\t";
     $textualtriggeringrule .= "   Annotations: phenotype_description \"" . clean_comment_string($phenotype_description) . "\"\n";
     $humantriggeringrule .= "   Annotations: phenotype_description \"" . clean_comment_string($phenotype_description) . "\"\n";
 }
 $drug_recommendations_info_importance = "\t";
 if (isset($recommendation_importance) && $recommendation_importance != "") {
     $drug_recommendations_info_importance = $recommendation_importance . "\t";
     $textualtriggeringrule .= "   Annotations: recommendation_importance \"" . $recommendation_importance . "\"\n";
     $humantriggeringrule .= "   Annotations: recommendation_importance \"" . $recommendation_importance . "\"\n";
 }
 $drug_recommendations_info_seealsolist = "";
 if (isset($recommendation_URL) && $recommendation_URL != "") {
     $list_elements = preg_split("/\n/", $recommendation_URL);
     foreach ($list_elements as $element) {
         if (!empty($drug_recommendations_info_seealsolist)) {
             $drug_recommendations_info_seealsolist .= "\t";
         }
         $drug_recommendations_info_seealsolist .= $element;
        $humantriggeringrule .= "   Annotations: date_of_addition \"" . $date_of_addition . "\"\n";
    }
    if (isset($date_last_validation) && $date_last_validation != "") {
        $textualtriggeringrule .= "   Annotations: date_last_validation \"" . $date_last_validation . "\"\n";
        $humantriggeringrule .= "   Annotations: date_last_validation \"" . $date_last_validation . "\"\n";
    }
    if (isset($author_last_validation) && $author_last_validation != "") {
        $textualtriggeringrule .= "   Annotations: author_last_validation \"" . $author_last_validation . "\"\n";
        $humantriggeringrule .= "   Annotations: author_last_validation \"" . $author_last_validation . "\"\n";
    }
    if (isset($author_addition) && $author_addition != "") {
        $textualtriggeringrule .= "   Annotations: author_addition \"" . $author_addition . "\"\n";
        $humantriggeringrule .= "   Annotations: author_addition \"" . $author_addition . "\"\n";
    }
    $textualtriggeringrule .= "\tAnnotations: textual_genetic_description \"" . clean_comment_string($phenotype_textual_description) . "\"\n\n";
    $humantriggeringrule .= "\tAnnotations: textual_genetic_description \"" . clean_comment_string($phenotype_textual_description) . "\"\n\n";
    $textual_rule .= $textualtriggeringrule . "\n\n";
    $rule_owl .= $humantriggeringrule . "\n\n";
}
$report .= "We have defined {$nrules} phenotype rules in the ontology.\n";
/**********************************
 ******* Generate disjoints *******
 **********************************/
$owl .= "\n#\n# Disjoints\n#\n\n";
$owl .= "# polymorphism disjoints\n";
$owl .= generateDisjointClassesOWL($polymorphism_disjoint_list);
$owl .= "# gene/allele disjoints\n";
$owl .= generateDisjointClassesOWL($gene_ids);
/*****************************
 ******* Write to disk *******
 *****************************/