Dear guys on the internet!
i struggle to properly recreate a table from a word document in LaTeX. The following picture shows the goal i want to reach (Screenshot from word document):
I tried it using different packages, but i seem to fail. Here are my tries using tabular package:
\documentclass[paper=a4]{scrartcl}
\usepackage{multirow}
\begin{document}
\begin{tabular}{|*{15}{c|}}
\hline
Weapon Type & S & T.P., cm & $\alpha$, arc minute & H\textsubscript{B}, cm & \multirow{2}{*}{X\textsubscript{B}, cm} & \multicolumn{9}{|c|}{Average Trajectories Height (cm) at Different Distance D} \\[2em]
& & & & & & 50 & 100 & 150 & 200 & 250 & 300 & 350 & 400 & 500 \\
\hline
Weapon & 4 & 18 & 14 & 36 & 207 & 6 & 18 & 26 & 31 & 30 & 25 & 15 & 0 & -47 \\
%A & B & C & D\\
\hline
\end{tabular}
\end{document}
The resulting table looks like this:
Trying to get linebreaks with the tabularx package also leads to an ugly result:
\documentclass[paper=a4]{scrartcl}
\usepackage{multirow}
\usepackage{tabularx}
\usepackage{booktabs}
\begin{document}
\begin{tabularx}{\textwidth}{|*{6}{X|}c|c|c|c|c|c|c|c|c|}
\toprule
Weapon Type & S & T.P., cm & $\alpha$, arc minute & H\textsubscript{B}, cm & \multirow{2}{=}{X\textsubscript{B}, cm} & \multicolumn{9}{X|}{Average Trajectories Height (cm) at Different Distance D} \\
& & & & & & 50 & 100 & 150 & 200 & 250 & 300 & 350 & 400 & 500 \\
\midrule
Weapon & 4 & 18 & 14 & 36 & 207 & 6 & 18 & 26 & 31 & 30 & 25 & 15 & 0 & -47\\
\bottomrule
\end{tabularx}
\end{document}
How can i receive a result that is looking like the one i posted in the first image? Why does LaTeX have problems displaying it initially in that way? Can you show me an elegant solution to this problem and give me an explanation? I want to know what i did wrong.
Greetings and thank you for your support!