4

How do I type Z or z with a stroke through it (Ƶ or ƶ) in normal text? I have a solution that sort of works. The code is as follows

\newcommand{\zbar}{\raisebox{0.2ex}{--}\kern-0.6em Z}

It works well in the text mode, however when I put this symbol in a superscript, the stroke is raised a little too much. The following image shows the ulgy' looking\zbar' as superscript. enter image description here

Is there a way that the height of the stroke could adjust itself depending on the environment.

Thanks in advance for your help.

5
  • 1
    \usepackage{amssymb}\mathcal{Z}
    – Marijn
    Commented Jan 25, 2017 at 21:26
  • 3
    Can you tell what use of the glyph you intend to make?
    – egreg
    Commented Jan 25, 2017 at 22:24
  • \mathcal{Z} works but the character is italicized. I was hoping for an upright character with a stroke through it. I need to use this character as a parameter in a model. Commented Jan 25, 2017 at 23:41
  • You said you wanted the glyph in normal text, now it turns out you want it in math mode.
    – egreg
    Commented Jan 26, 2017 at 20:48
  • Sorry, I just realized that while I was typing the equation. Thanks for your answer though! Commented Jan 27, 2017 at 17:37

2 Answers 2

4

It seems you want to use the symbol in math mode rather than normal text.

\documentclass{article}
\usepackage{newpxtext,newpxmath}
\usepackage{amsmath}

\newcommand{\Zstroke}{%
  \text{\ooalign{\hidewidth\raisebox{0.2ex}{--}\hidewidth\cr$Z$\cr}}%
}
\newcommand{\zstroke}{%
  \text{\ooalign{\hidewidth -\kern-.3em-\hidewidth\cr$z$\cr}}%
}

\begin{document}

\begin{equation*}
P(M_{i})=
  \frac{\Zstroke^{\Zstroke+1}}{\Gamma(\Zstroke+1)}
  \frac{M_{i}^{\Zstroke-1}}{M_{n}^{\Zstroke}}
  \exp\Bigl(-\frac{\Zstroke M_{i}}{M_{n}}\Bigr)
\end{equation*}
\begin{equation*}
P(M_{i})=
  \frac{\zstroke^{\zstroke+1}}{\Gamma(\zstroke+1)}
  \frac{M_{i}^{\zstroke-1}}{M_{n}^{\zstroke}}
  \exp\Bigl(-\frac{\zstroke M_{i}}{M_{n}}\Bigr)
\end{equation*}

\end{document}

enter image description here

4

One way would be to create your own symbol my merging a line and a z.

Code:

\documentclass[12pt,a4paper]{standalone}
\newcommand*{\xdash}[1][3em]{\rule[0.5ex]{#1}{0.55pt}}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{amssymb}
\usepackage{graphicx}
\newcommand{\sZ}{\ensuremath{\scalebox{.86}{Z}
\kern-.41em\raisebox{.07em}{$\xdash[.3em]$}}}
\newcommand{\sz}{\ensuremath{\scalebox{.86}{z}
\kern-.3em\raisebox{-.045em}{$\xdash[.2em]$}}}
\begin{document}
~\sZ~\sz~
\end{document}

Yields:

enter image description here

1
  • on similar lines, I found another solution: Commented Jan 26, 2017 at 19:00

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .