[Tex/LaTex] Fancy Chapter Headings Style

chaptersfncychapsectioning

I would like make a fancy chapter like the figure.

Desired Output

However, i made this code

\documentclass[12pt,a4paper]{book}


\usepackage{lmodern}
\usepackage{titlesec}
\usepackage{microtype}
\usepackage{tikz}



\titleformat{\chapter}[display]
  {\normalfont\bfseries\color{black}}
  {%\filleft%
    \begin{tikzpicture}
    \node[
      outer sep=-10pt,
      text width=2.5cm,
      minimum height=3cm,
      fill=black,
      font=\color{white}\fontsize{80}{90}\selectfont,
      align=center
      ] (num) {\thechapter};
    \node[
      rotate=0,
      anchor=south,
      font=\color{black}\Large\normalfont
      ] at ([yshift=43pt,xshift=30]num.west)  {\textls[180]{\textsc{\chaptertitlename}}};  
    \end{tikzpicture}%
 } 
  {-90pt}
  {\titlerule[2.5pt]\vskip3pt\titlerule\vskip4pt\LARGE\sffamily \raggedright }

  \begin{document}
\chapter{The Singular Sturm-Liouville Problems in Spectral Parameter}

  \end{document}  

that produces this one

Desired Output

How can I produce the chapter like the First Figure?

Best Answer

Is this what you want?

enter image description here

\documentclass[12pt,a4paper]{book}
\usepackage{lipsum} % dummy text

\usepackage{lmodern}
\usepackage[explicit]{titlesec}
\usepackage{microtype}
\usepackage{tikz}

\titleformat%
{\chapter}[hang]%
{\bfseries}{%
\begin{minipage}[t]{0.3\linewidth}  
\vspace{0pt}% do not remove
\begin{tikzpicture}
\node[
outer sep=0pt,
text width=2.5cm,
minimum height=2.5cm,
fill=black,
font=\color{white}\fontsize{80}{90}\selectfont,
align=center
] (num) {\thechapter};
\node[
outer sep=0pt,
inner sep=0pt,
anchor=south,
font=\color{black}\Large\normalfont
] at ([yshift=3pt]num.north) {\textls[180]{\textsc{\chaptertitlename}}};
\end{tikzpicture}  
\end{minipage}%
}
{0pt}%
{%
\begin{minipage}[t]{.7\linewidth}%
    \vspace{2pt} % do not remove
    \rule{\linewidth}{2.5pt}\\\vskip -1.75\baselineskip%
    \rule{\linewidth}{.7pt}\vskip 5pt
    {\LARGE\raggedright\textsf{#1}}
\end{minipage}%

}


\begin{document}
    \chapter{The Singular Sturm-Liouville Problems in Spectral Parameter}
    \lipsum[1]
\end{document}