绘制曲线和曲线中间的相交直线

绘制曲线和曲线中间的相交直线

我有 3 个图形,我想用 latex 绘制它们。不幸的是,我不熟悉用 latex 绘制图形,而这些图形对于我的报告来说是必需的。如果您能帮我绘制它们,我将不胜感激。

在此处输入图片描述

在此处输入图片描述

答案1

我看不太清楚下面的图,但第一张图显示了四种地层,利用了一些很好的特征元帖子。这里我用luamplib,因此用 来编译它lualatex

在此处输入图片描述

interpath请特别注意第一个子图中nice 宏的使用。

\RequirePackage{luatex85}
\documentclass[border=5mm]{standalone}
\usepackage{luamplib}
\begin{document}
\mplibtextextlabel{enable}
\begin{mplibcode}
beginfig(1);

    % define a couple of nice curves for the surface level and the base level
    path surface, base;
    surface = (0,  0) {dir  -4} .. (100,  0) {dir -4};
    base =    (0,-42) {dir -18} .. (100,-38) {dir -28};

    % prepare each of the subfigures separately
    picture A,B,C,D;
    A = image(
    for t=0 step 1/4 until 1:
       draw interpath(t,surface,base) if t=floor t: withpen pencircle scaled 1 fi;
    endfor
    for t=1/8 step 1/8 until 7/8:
       draw point t of base -- point t of surface;
    endfor
    label("Proportional", point 1/2 of base shifted 20 down);
    );

    B = image(
    draw surface withpen pencircle scaled 1;
    for t=-12 step -12 until -42:
        draw surface shifted (0,t);
    endfor
    unfill base -- reverse base shifted 30 down -- cycle;
    draw base withpen pencircle scaled 1;
    for t=1/8 step 1/8 until 7/8:
       draw point t of base -- point t of surface;
    endfor
    label("Onlap/Baselap", point 1/2 of base shifted 20 down);
    );    

    C = image(
    draw base withpen pencircle scaled 1;
    for t=12 step 12 until 42:
        draw base shifted (0,t);
    endfor
    unfill surface -- reverse surface shifted 10 up -- cycle;
    draw surface withpen pencircle scaled 1;
    for t=1/8 step 1/8 until 7/8:
       draw point t of base -- point t of surface;
    endfor
    label("Eroded", point 1/2 of base shifted 20 down);
    );    

    D = image(
    draw surface withpen pencircle scaled 1;
    for t=6 step -12 until -42:
        draw surface rotatedabout(point 1/2 of surface, -10) 
             shifted (0,t)
             cutbefore surface
             cutafter base;
    endfor
    unfill base -- reverse base shifted 30 down -- cycle;
    draw base withpen pencircle scaled 1;
    for t=1/8 step 1/8 until 7/8:
       draw point t of base -- point t of surface;
    endfor
    label("Progradational", point 1/2 of base shifted 20 down);
    );    

    % and now lay out the four subfigures on the page
    draw A shifted (  0,  0);
    draw B shifted (130,  0);
    draw C shifted (  0,-90);
    draw D shifted (130,-90);

endfig;
\end{mplibcode}
\end{document}

答案2

作为起点,我尝试使用hobby包绘制您的第一幅图像(比例)。坐标可能不适合您。请根据您的要求进行调整。其他图形可以用类似的方式绘制。

\documentclass[margin=1cm]{standalone}
\usepackage{tikz}
\usetikzlibrary{intersections,through,hobby,calc}

\begin{document}
\begin{tikzpicture}
\path[name path=ray1] (0.5,0)--++ (90:6cm);
\path[name path=ray2] (1.5,0)--++ (90:6cm);
\path[name path=ray3] (2.5,0)--++ (90:6cm);
\path[name path=ray4] (3.5,0)--++ (90:6cm);
\path[name path=ray5] (4.5,0)--++ (90:6cm);
\path[name path=ray6] (5,0)--++ (90:6cm);

\draw [name path=curve1,line width=0.35mm] (0,4) to [ curve through ={(2,3.75)  . . (3,3.8) . . (4.5,3.9)  }] (5.5,3.9);
\draw [line width=0.2mm,orange] (0,3.5) to [ curve through ={(2,3.25)  . . (3,3.3) . . (4.5,3.4)  }] (5.5,3.4);
\draw [line width=0.2mm,orange] (0,3) to [ curve through ={(2,2.75)  . . (3,2.8) . . (4.5,2.9)  }] (5.5,3);
\draw [line width=0.2mm,orange] (0,2.5) to [ curve through ={(2,2.15)  . . (3,2.25) . . (4.5,2.4)  }] (5.5,2.5);
\draw [name path=curve2,line width=0.35mm] (0,2) to [ curve through ={(2,1.25)  . . (3,1.5) . . (4.5,1.8)  }] (5.5,2);

\fill[name intersections={of=ray1 and curve1,by={a}}]  (a) circle {} ;
\fill[name intersections={of=ray2 and curve1,by={b}}]   (b)circle {} ;
\fill[name intersections={of=ray3 and curve1,by={c}}]   (c)circle{} ;
\fill[name intersections={of=ray4 and curve1,by={d}}]   (d) circle{} ;
\fill[name intersections={of=ray5 and curve1,by={e}}]   (e) circle{} ;
\fill[name intersections={of=ray6 and curve1,by={f}}]   (f)circle {} ;

\fill[name intersections={of=ray1 and curve2,by={g}}]  (g)circle {} ;
\fill[name intersections={of=ray2 and curve2,by={h}}]   (h)circle {} ;
\fill[name intersections={of=ray3 and curve2,by={i}}]   (i)circle{} ;
\fill[name intersections={of=ray4 and curve2,by={j}}]   (j)circle {} ;
\fill[name intersections={of=ray5 and curve2,by={k}}]   (k)circle {} ;
\fill[name intersections={of=ray6 and curve2,by={l}}]   (l)circle {} ;
\foreach \x/\y in {a/g,b/h,c/i,d/j,e/k,f/l}{
\draw (\x)--(\y);}
\node at (2.75,0.75){Proportional};
\end{tikzpicture}
\end{document}

在此处输入图片描述

相关内容