Fichier:Table log 001 100 cinq decimales.svg

De testwiki
Aller à la navigation Aller à la recherche
    Fichier d’origine (Fichier SVG, nominalement de 526 × 744 pixels, taille : 26 kio)

    Ce fichier provient de Wikimedia Commons et peut être utilisé par d'autres projets. Sa description sur sa page de description est affichée ci-dessous.

    Description

    Description
    Français : Table des logarithmes népériens de 0.01 à 100 avec cinq décimales. Format A5 (ISO 216, 148.5 × 210 mm). Créé avec Scilab.
    English: Table of the natural logarithm from 0.01 to 100 with six significant digits. Decimal mark: comma. A5 format (ISO 216, 148.5 × 210 mm, 5.8 × 8.3 in). Created with Scilab.
    Date
    Source Travail personnel
    Auteur ou autrice Cdang
    Autres versions
    SVG information
    InfoField
     Le code de ce fichier SVG est valide.
     Cette image vectorielle SVG a été créée avec Scilab par cdang
      Ce diagramme SVG utilise du texte encapsulé qui peut être traduit facilement à l'aide d'un éditeur de texte.

    Source code

    Logotype de Scilab – Logiciel de calcul numérique libre et open source
    Logotype de Scilab – Logiciel de calcul numérique libre et open source
    This media was created with Scilab (Logiciel de calcul numérique libre et open source)
    Here is a listing of the source used to create this file.

    Deutsch ∙ македонски ∙ English ∙ +/−

    // valeurs
    
    chemin = "C:\Dossier_de_travail\";
    nomDeFichier = "Table_log_001_100_cinq_decimales.svg";
    
    Npetits=0.01:0.01:1;
    Ngrands=1:100;
    nbcol=5;
    nbligne = 100/nbcol;
    
    // decimales = 2; // précision
    decimales = 5; // précision
    fd = 10^decimales; // facteur décimal
    ifd = 1/fd; // inverse facteur décimal
    
    logNpetits = strsubst(string(ifd*round(fd*log(Npetits))), ".", ",");
    logNpetits = strsubst(logNpetits, "-", "–"); // tiret demi-cadratin
    logNgrands = strsubst(string(ifd*round(fd*log(Ngrands))), ".", ",");
    
    Npetits = strsubst(string(Npetits), ".", ",");
    
    point = 25.4/72; // point pica en millimètres
    corps = 8*point; // taille de caractères en mm
    espace = 1; // 1 mm de gouttière et d'interligne
    marge = 10; // 10 mm = 1 cm de marge
    
    // Structure du fichier SVG
    
    entete =["<?xml version=""1.0"" encoding=""UTF-8"" standalone=""no""?>"
    " "
    "<!DOCTYPE svg PUBLIC ""-//W3C//DTD SVG 1.1//EN"" "
      " ""http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"" "
    ">"
    " "
    "<svg"
    "  width=""148.5mm"" height=""210mm"" version=""1.1"" "
    "  xmlns=""http://www.w3.org/2000/svg"" "
    "  xmlns:xlink=""http://www.w3.org/1999/xlink"" "
    "  viewBox=""0 0 148.5 210"" "
    "  font-family=""Arial"" font-size="""+string(corps)+""""
    ">"
    " "
    "  <title> Table de logarithmes népériens </title>"
    "  <desc> Table de logarithmes népériens entre 0,01 et 100"
    "    avec cinq décimales </desc>"
    " "
    ];
    
    finDeFichier = [" "
    "</svg>"];
    
    // ********************************
    // * Contruire le premier tableau *
    // ********************************
    
    marge1 = marge + corps + espace
    
    xdebut1 = marge + 2*espace; // à 10.1 cm du bord gauche
    ydebut1 = marge1 + 3*espace + corps;
    // largeurCol = 6*corps + 2*espace;
    largeurCol = 8.5*corps + 2*espace;
    hauteurLigne = corps + espace;
    
    x11 = xdebut1 + largeurCol*[0:(nbcol-1)] ;
    y1 = ydebut1 + hauteurLigne*[1:nbligne] ;
    
    entetetableau1 = []
    for i = 1:nbcol
        entetetableau1(i) =  "<text x="""+string(x11(i))+""" y="""+...
            string(marge1 + espace + corps)+""" font-weight=""bold"" > "+...
            "N </text>"+...
            "<text x="""+string(x11(i)+2.5*corps + espace)+""" y="""+...
            string(marge1 + espace + corps)+""" font-weight=""bold"" > "+...
            "ln(N) </text>"
    end
    
    tableau11 = []; // initialisation
    
    indice = 1;
    for i = 1:nbcol
        for j = 1:nbligne
            saut=floor(0.1*(j-1));
            if 10*round(indice/10) == indice then
                tableau11(indice) = "<text x="""+string(x11(i))+""" y="""+...
                string(y1(j) + saut*corps)+""" font-weight=""bold"" > "
            else
                tableau11(indice) = "<text x="""+string(x11(i))+""" y="""+...
                string(y1(j) + saut*corps)+""" > "
            end
            tableau11(indice) = tableau11(indice)+...
               string(Npetits(indice)) + " </text>";
            indice = indice + 1
        end
    end
    
    x12 = x11 + 2.5*corps + espace;
    
    tableau12=[];
    indice = 1;
    for i = 1:nbcol
        for j = 1:nbligne
            saut=floor(0.1*(j-1));
            foo = logNpetits(indice)
            if length(foo) > 6 then
                foo = strsplit(foo, 6);
                chaine = foo(1)+" "+foo(2);
            else
                chaine=foo;
            end
            tableau12(indice) = "<text x="""+string(x12(i))+""" y="""+...
            string(y1(j) + saut*corps)+""" > "+...
            chaine + " </text>";
            indice = indice + 1
        end
    end
    
    cadreTableau1 = "<rect fill=""none"" stroke=""black"" stroke-width=""0.4"" "+...
       "x="""+string(marge)+""" y="""+string(marge1)+...
       """ width="""+string(largeurCol*(nbcol))+...
       """ height="""+string(hauteurLigne*(nbligne+1) + 2*espace + 2*corps)+""" />";
    
    y11 = marge1;
    y12 = marge1 + 2*espace + 2*corps + hauteurLigne*(nbligne+1);
    filetsTableau1 = [];
    for i = 1:nbcol
        filetsTableau1(i)="<line stroke=""black"" stroke-width=""0.2"" "+...
        "x1="""+string(marge - 4.5*espace + (i - 0.5)*largeurCol)+...
        """ y1="""+string(y11)+...
        """ x2="""+string(marge - 4.5*espace + (i - 0.5)*largeurCol)+...
        """ y2="""+string(y12)+""" />"
    end
    
    for i = 1:(nbcol-1)
        filetsTableau1(i+nbcol)="<line stroke=""black"" stroke-width=""0.2"" "+...
        "x1="""+string(marge + i*largeurCol - 1.25*espace)+...
        """ y1="""+string(y11)+...
        """ x2="""+string(marge + i*largeurCol - 1.25*espace)+...
        """ y2="""+string(y12)+""" /> "+...
        "<line stroke=""black"" stroke-width=""0.2"" "+...
        "x1="""+string(marge + i*largeurCol - 0.75*espace)+...
        """ y1="""+string(y11)+...
        """ x2="""+string(marge + i*largeurCol - 0.75*espace)+...
        """ y2="""+string(y12)+""" />";
    end
    filetsTableau1($+1)="<line stroke=""black"" stroke-width=""0.4"" "+...
        "x1="""+string(marge)+...
        """ y1="""+string(marge1 + 2*espace + corps)+...
        """ x2="""+string(marge + largeurCol*(nbcol))+...
        """ y2="""+string(marge1 + 2*espace + corps)+""" /> "
    
    // *******************************
    // * Contruire le second tableau *
    // *******************************
    
    marge2 = y12 + 3*corps + espace;
    ydebut2 = marge2 + 3*espace + corps;
    y2 = ydebut2 + hauteurLigne*[1:nbligne] ;
    
    entetetableau2 = []
    for i = 1:nbcol
        entetetableau2(i) =  "<text x="""+string(x11(i))+""" y="""+...
            string(marge2 + espace + corps)+""" font-weight=""bold"" > "+...
            "N </text> "+...
            "<text x="""+string(x11(i)+2.5*corps + espace)+""" y="""+...
            string(marge2 + espace + corps)+""" font-weight=""bold"" > "+...
            "ln(N) </text>"
    end
    
    tableau21 = []; // initialisation
    
    indice = 1;
    for i = 1:nbcol
        for j = 1:nbligne
            saut=floor(0.1*(j-1));
            if 10*round(indice/10) == indice then
                tableau21(indice) = "<text x="""+string(x11(i))+""" y="""+...
                string(y2(j) + saut*corps)+""" font-weight=""bold"" > "
            else
                tableau21(indice) = "<text x="""+string(x11(i))+""" y="""+...
                string(y2(j) + saut*corps)+""" > "
            end
            tableau21(indice) = tableau21(indice)+...
               string(Ngrands(indice)) + " </text>";
            indice = indice + 1
        end
    end
    
    tableau22=[];
    indice = 1;
    for i = 1:nbcol
        for j = 1:nbligne
            foo = logNgrands(indice)
            if length(foo) > 5 then
                foo = strsplit(foo, 5);
                chaine = foo(1)+" "+foo(2);
            else
                chaine=foo;
            end
            saut=floor(0.1*(j-1));
            tableau22(indice) = "<text x="""+string(x12(i))+""" y="""+...
            string(y2(j) + saut*corps)+""" > "+...
            chaine + " </text>";
            indice = indice + 1
        end
    end
    
    cadreTableau2 = "<rect fill=""none"" stroke=""black"" stroke-width=""0.4"" "+...
       "x="""+string(marge)+""" y="""+string(marge2)+...
       """ width="""+string(largeurCol*(nbcol))+...
       """ height="""+string(hauteurLigne*(nbligne+1) + 2*espace + 2*corps)+""" />";
    
    y21 = marge2;
    y22 = marge2 + 2*espace + 2*corps + hauteurLigne*(nbligne+1);
    filetsTableau2 = [];
    for i = 1:nbcol
        filetsTableau2(i)="<line stroke=""black"" stroke-width=""0.2"" "+...
        "x1="""+string(marge - 4.5*espace + (i - 0.5)*largeurCol)+...
        """ y1="""+string(y21)+...
        """ x2="""+string(marge - 4.5*espace + (i - 0.5)*largeurCol)+...
        """ y2="""+string(y22)+""" />"
    end
    
    for i = 1:(nbcol-1)
        filetsTableau2(i+nbcol)="<line stroke=""black"" stroke-width=""0.2"" "+...
        "x1="""+string(marge + i*largeurCol - 1.25*espace)+...
        """ y1="""+string(y21)+...
        """ x2="""+string(marge + i*largeurCol - 1.25*espace)+...
        """ y2="""+string(y22)+""" /> "+...
        "<line stroke=""black"" stroke-width=""0.2"" "+...
        "x1="""+string(marge + i*largeurCol - 0.75*espace)+...
        """ y1="""+string(y21)+...
        """ x2="""+string(marge + i*largeurCol - 0.75*espace)+...
        """ y2="""+string(y22)+""" />";
    end
    filetsTableau2($+1)="<line stroke=""black"" stroke-width=""0.4"" "+...
        "x1="""+string(marge)+...
        """ y1="""+string(marge2 + 2*espace + corps)+...
        """ x2="""+string(marge + largeurCol*(nbcol))+...
        """ y2="""+string(marge2 + 2*espace + corps)+""" /> "
    
    // fichier SVG
    
    matriceFichier = [entete
    " "
    "<text x="""+string(marge)+""" y="""+string(marge+corps)+...
      """ font-weight=""bold"">Table des logarithmes népériens entre 0,01 et 1</text>"
    " "
    "<!-- *******************"
    "     * Premier tableau *"
    "     ******************* -->"
    " "
    entetetableau1
    " "
    "<!-- N -->"
    tableau11
    " "
    "<!-- ln(N) -->"
    tableau12
    " "
    "<!-- cadre -->"
    cadreTableau1
    filetsTableau1
    "<text x="""+string(marge)+""" y="""+string(marge2-espace)+...
      """ font-weight=""bold"">Table des logarithmes népériens entre 1 et 100</text>"
    " "
    " "
    "<!-- ********************"
    "     * Deuxieme tableau *"
    "     ******************** -->"
    " "
    entetetableau2
    " "
    "<!-- N -->"
    tableau21
    " "
    "<!-- ln(N) -->"
    tableau22
    " "
    "<!-- cadre -->"
    cadreTableau2
    filetsTableau2
    " "
    finDeFichier];
    
    chdir(chemin);
    write(nomDeFichier, matriceFichier);
    

    Conditions d’utilisation

    Moi, en tant que détenteur des droits d’auteur sur cette œuvre, je la publie sous la licence suivante :
    Creative Commons CC-Zero Ce fichier est dans le domaine public selon les termes de la licence Creative Commons CC0 1.0 Universel.
    La personne qui a associé une œuvre avec cet acte l’a placée dans le domaine public en renonçant mondialement à tous ses droits sur cette œuvre en vertu des lois relatives au droit d’auteur, ainsi qu’à tous les droits juridiques connexes et voisins qu’elle possédait sur l’œuvre, sans autre limite que celles imposées par la loi. Vous pouvez copier, modifier, distribuer et utiliser cette œuvre, y compris à des fins commerciales, sans qu’il soit nécessaire d’en demander la permission.

    Légendes

    Ajoutez en une ligne la description de ce que représente ce fichier

    Éléments décrits dans ce fichier

    dépeint

    Historique du fichier

    Cliquer sur une date et heure pour voir le fichier tel qu'il était à ce moment-là.

    Date et heureVignetteDimensionsUtilisateurCommentaire
    actuel7 novembre 2017 à 11:47Vignette pour la version du 7 novembre 2017 à 11:47526 × 744 (26 kio)wikimediacommons>CdangUser created page with UploadWizard

    Aucune page n’utilise ce fichier.