0
$\begingroup$

I've been tasked with working out how much some incorrectly entered calibration coefficients have affected some measurements we've taken. I have the algorithm used, which I can use to work backwards and get some error ranges, but I'm a bit stuck on notation.

The algorithm reads, in part:

$x\ln^2(1000/y)$

but I'm a but flummoxed on how to translate this into, say, MATLAB syntax - especially the $\ln^2$ part.

Sorry for the stupid question, but this is out of my field a fair bit, and high school maths class was a long time ago...

  • 0
    Thanks to both Gustav and Nana for the prompt replies. I had some test values I could put in, and I got the correct result from the algorithm.2011-05-06

2 Answers 2

0

My guess is x * log(1000/y)^2.

Basic functions sometimes put powers of two before the parentheses. It's a common practice for trigonometric functions, even though I can't recall seeing it for ln.

0

I would like to add that if you need to work on a vector value of x and y you will have to put a "dot" before the ^2

x.*(log(1000/y)).^2

This reads "preform the operation of squaring on every component of x and y separately"