The whole journey was just one thousand kilometres.
This was my first hitchhiking trip in Kazakhstan in winter.
Previously, I had hitchhiked in winter in Uzbekistan, Kyrgyzstan and Tajikistan, but those countries are warmer.
I had also hitchhiked in the Tomsk region of Russia, where it was minus 30 °C, but that region rarely has strong winds, so it is not difficult to travel, provided that you have suitable clothes.
Kazakhstan is notorious for Burans, icy roads, and scary temperatures, so I felt a little uneasy before my journey.
But in the morning when I started, it was only about minus 17 °C.
The weather was pleasant and calm during the whole day. There was almost no ice on the road.
Two thirds of the distance was covered after the sunset.
It was easy. I would say, too easy for this time of the year in this part of the planet.
It looks like God decided to provide so much care for me this time, that I didn’t have a chance to experience any terrible adventures.
Maybe next time?
The heart is the graph of the function
y = (√cos(x) cos(200x)+√x0.7) (4x^{2})^{0.001}
***
***
***
This is our video:
Today’s TV news reports about us:
Khabar TV channel in Russian: link
Khabar TV channel in Kazakh: link
Newspaper articles about us:
Our antenna:
This is the gate of a small computer shop in Almaty, Kazakhstan.
Matlab  Scilab  Function 

acot(A) 
atan((1) ./A) 
Inverse cotangent 
acoth(A) 
atanh((1) ./A) 
Inverse hyperbolic cotangent 
acsc(A) 
asin((1) ./A) 
Inverse cosecant 
acsch(A) 
asinh((1) ./A) 
Inverse hyperbolic cosecant 
all 
and 
Test to determine if all elements are nonzero 
angle(A) 
atan(imag(A),real(A)) 
Phase angle 
any 
or 
Test to determine if any nonzeros elements 
asec(A) 
acos((1) ./A) 
Inverse secant 
asech(A) 
acosh((1) ./A) 
Inverse hyperbolic secant 
atan2(y,x) 
atan(y,x) 
Fourquadrant inverse tangent 
[T,Ab]=balance(A) 
[Ab,T]=balanc(A) 
Diagonal scaling to improve eigenvalue accuracy 
blkdiag 
sysdiag 
Construct block diagonal matrix from input arguments 
cot 
cotg 
Cotangent 
cputime 
timer() 
Elapsed CPU time 
csc(A) 
(1) ./sin(A) 
Cosecant 
csch(A) 
(1) ./sinh(A) 
Hyperbolic cosecant 
date 
date() 
Current date string 
dos 
unix_g 
Execute a UNIX command and return result 
eig 
spec ; bdiag 
Find eigenvalues and eigenvectors 
eval 
evstr ; execstr 
Execute a string containing an instruction 
fclose 
mclose 
Close one or more open files 
feof 
meof 
Test for endoffile 
ferror 
mclearerr ; merror 
Query about errors in file input or output 
fft(A[,...]) 
fft(A,1[,...]) 
Discrete Fourier transform 
fgetl 
mgetl 
Read line(s) from file, discard newline character 
fgets 
fgetstr 
Read line from file, keep newline character 
fliplr(A) 
A(:,$:1:1) 
Flip matrix in left/right direction 
flipud(A) 
A($:1:1,:) 
Flip matrix in up/down direction 
fopen 
mopen 
Open a file or obtain information about open files 
frewind(fid) 
mseek("0",fid) 
Move the file position indicator to the beginning of an open file 
fseek 
mseek 
Set file position indicator 
ftell 
mtell 
Get file position indicator 
hankel 
hank 
Hankel matrix 
ifft(A[,...]) 
fft(A,1[,...]) 
Inverse discrete Fourier transform 
iscell(A) 
typeof(A)=="ce" 
Determine if input is a cell array 
ischar(A) 
type(A)==10 
Determine if item is a character array 
ishandle(A) 
type(A)==9 
Determines if values are valid graphics object handles 
isinteger(A) 
type(A)==8 
Detect whether an array has integer data type 
isscalar(A) 
sum(length(A))==1 

isstr(A) 
type(A)==10 
Determine if item is a character array 
isstruct(A) 
typeof(A)=="st" 
Determine if input is a structure array 
isunix 
getos() "Windows" 
Determine if Unix version 
ispc 
(getos() == 'Windows') 
Determine if PC (Windows) version 
kron(A,B) 
A .*. B 
Kronecker tensor product 
lookfor 
apropos 
Search for specified keyword in all help entries 
lower(str) 
convstr(str,"l") 
Convert string to lower case 
mod 
pmodulo 
Modulus after division 
nargin 
argn(2) 
Number of function input arguments 
nargout 
argn(1) 
Number of function output arguments 
null 
kernel 
Null space of a matrix 
num2str 
string 
Number to string conversion 
ones(size(A)) 
ones(A) 
Create an array of all ones 
otherwise 
else 
Default part of switch/select statement 
pause 
xpause 
Halt execution temporarily 
prod(A,1) 
prod(A,"r") 
Product of array elements 
rand(A) 
rand(A[,"uniform"]) 
Uniformly distributed random numbers and arrays 
randn(A) 
rand(A,"normal") 
Normally distributed random numbers and arrays 
realmax 
number_properties("huge") 
Largest positive floatingpoint number 
realmin 
number_properties("tiny") 
Smallest positive floatingpoint number 
rem(X,Y) 
Xfix(X./Y).*Y 
Remainder after division 
reshape 
matrix 
Reshape array 
strcmp(str1,str2) 
str1==str2 
Compare strings 
strfind 
strindex 
Find one string within another 
strrep 
strsubst 
String search and replace 
switch 
select 
Switch among several cases based on expression 
tic 
tic() 
Starts a stopwatch timer 
toc 
toc() 
Read the stopwatch timer 
unix 
unix_g 
Execute a UNIX command and return result 
upper(str) 
convstr(str,"u") 
Convert string to upper case 
end (index) 
$ 
Last index 
eps 
%eps 
Floatingpoint relative accuracy 
i ; j 
%i 
Imaginary unit 
pi 
%pi 
Ratio of a circle’s circumference to its diameter 
Here’s the video (in Russian but radio amateurs will understand what is going on):
The antenna is a closed loop of copper wire, a little bit longer than 80 meters.
The exact length was adjusted so that the internal tuner of our Icom IC7600 was able to tune it for the 40 and 80 meter bands.
The antenna is stretched between our balcony on the ninth floor and the roofs of two neighboring buildings.
Because the wire is thin, the bandwidth is not large, and the antenna is not tuned for the whole 80 m band.
However, its length is adjustable. We soldered several terminals, half a meter apart, so we can change the length which shifts the resonant frequency within the band. This is what we do on the balcony in the video during our antenna party where we also made a fruit salad and cookies with marshmallow and chocolate by melting them under the sun.
Making antennas is fun. Seeing them work is even more fun!
Best wishes from our radio club!
73 de UN9GWA
We will use these data as a training set for logistic regression.
b0 = 10;
t = b0 * rand(100,2);
t = [t 0.5+0.5*sign(t(:,2)+t(:,1)b0)];
b = 1;
flip = find(abs(t(:,2)+t(:,1)b0)<b);
t(flip,$)=grand(length(t(flip,$)),1,"uin",0,1);
t0 = t(find(t(:,$)==0),:);
t1 = t(find(t(:,$)==1),:);
clf(0);scf(0);
plot(t0(:,1),t0(:,2),'bo')
plot(t1(:,1),t1(:,2),'rx')
The data from different classes overlap slightly. The degree of overlapping is controlled by the parameter b
in the code.
We want to build a classification model that estimates the probability that a new, incoming data belong to the class 1.
First, we separate the data into features and results:
x = t(:, 1:$1); y = t(:, $);
[m, n] = size(x);
Then, we add the intercept column to the feature matrix
// Add intercept term to x
x = [ones(m, 1) x];
The logistic regression hypothesis is defined as:
h(θ, x) = 1 / (1 + exp(−θ^{T}x) )
It’s value is the probability that the data with the features x belong to the class 1.
The cost function in logistic regression is
J = [−y^{T} log(h) − (1−y)^{T} log(1−h)]/m
where log
is the “elementwise” logarithm, not a matrix logarithm.
If we use the gradient descent algorithm, then the update rule for the θ is
θ → θ − α ∇J = θ − α x^{T} (h − y) / m
The code is as follows
// Initialize fitting parameters
theta = zeros(n + 1, 1);
// Learning rate and number of iterations
a = 0.01;
n_iter = 10000;
for iter = 1:n_iter do
z = x * theta;
h = ones(z) ./ (1+exp(z));
theta = theta  a * x' *(hy) / m;
J(iter) = (y' * log(h)  (1y)' * log(1h))/m;
end
Now, the classification can be visualized:
// Display the result
disp(theta)
u = linspace(min(x(:,2)),max(x(:,2)));
clf(1);scf(1);
plot(t0(:,1),t0(:,2),'bo')
plot(t1(:,1),t1(:,2),'rx')
plot(u,(theta(1)+theta(2)*u)/theta(3),'g')
Looks good.
The graph of the cost at each iteration is:
// Plot the convergence graph
clf(2);scf(2);
plot(1:n_iter, J');
xtitle('Convergence','Iterations','Cost')
It can even be dangerous if you are a robot.
Recently, hitchBOT, a Canadian hitchhiking robot was vandalized beyond repair in Philadelphia.
Earlier, the robot performed successful travels in Canada and Germany.
In Canada, the robot covered more than 10,000 kilometres within 21 days, having a lot of fun and adventures on his way, including attending a wedding and meeting some of Canada’s First Nations.
In the USA, however, within two weeks the robot managed to travel only 300 miles.
For some strange reason, Americans rarely give rides not only to human hitchhikers but also to robots.
Finally, poor hitchBOT fell victim to antirobotism. Or, maybe, antihitchhikingism? Or antirobothitchhikingism?
I really wonder why those people killed such a wonderful and harmless creature.
Some extracts from the comments about the accident on the hitchBOT’s facebook page:
Wow. All the way across Canada, toured through parts of Europe, and only managed two weeks in the US before being vandalized.
***
I, too, am a Canadian who was attacked while visiting Philadelphia – mugged by 2 huge men and a girl. hitchBOT, you were such a gentle little soul with such a big heart and we will always love you and be so very proud of you here in Canada. You have brought much happiness to the world and may God bless you for your many acts of human kindness …
***
Human beings really just make me shake my head sometimes…
***
Come to New Zealand when you are better hitchBOT. We would love to see you here.
***
So sad. I hate being pessimistic, but as soon as I heard you were going to the States I had a feeling that something like this would happen. Get well soon Hitchbot.
***
hitchBot, You were born out of Humanity, You grew and learned when you traveled, Many you met, Many you touch the hearts of, You were not created to intimidate but to learn, Learn about the world that created you, so many hearts you touched, so many hearts you touched, a New journey you began, In the Land of the Free and the Home of the Brave, Never believing a Country who thought like that would do you harm, Travels took you through areas where our Country was founded, fought and died for, Travels took you through some good, some bad places, Never were you a threat, then, One fateful day a Kind Person dropped you off where Our Countries founding Fathers signed our Countries Declaration to be a Free Nation, so much Blood spilled to be Free, to be Free from the Rule of Kings, A place once in the Middle of a Civil War, Brother against Brother, blood spilled for what, Now, it’s sort of Ironic that this location, the Birth of our Nation, The City known as The City of Brotherly Love, Became the place of your Demise, Your Death was not in vein, No no, For we “Humans” in this Nation who believe we are mostly a peaceful people, have seen the TRUTH, You showed US we have a long way to go, A long way to go before we do not assault the defenseless, the innocent, the ones who REALLY need our help to get around, You showed US how much we feel for the helpless, Your Death is proof of what we can do for OUR own Species if we choose to, Your SOUL was our HOPE and ability to CARE, Your SOUL was the KINDNESS in Humanity, although only a machine Your SOUL was that of GOOD People, the Death of Your SOUL was the EVIL that Lurks in ALL of Humanity, Your Death reminded US that although we ALL as Humans have this thing inside of US – Not All of US, just a few choose to let it out…………..
… etc — thousands of comments
function ... endfunction
deff
Examples:
function y=my_square(x)
y=x^2
endfunction
deff('y=my_square(x)','y=x^2')
Functions can be without arguments as well as without return values:
function f()
disp('Hi')
endfunction
deff('g()','disp(''Hello'')')
The function ... endfunction
construction is convenient if your function definition contains many lines of code.
On the other hand, because the arguments of deff
are strings, it is possible to make wild manipulations redefining functions on the fly.
if n < 5 then
function_name = 'f';
op = '+';
else
function_name = 'g';
op = '';
end
deff('z='+function_name+'(x,y)','z=x'+op+'y')
A function can call another function or even itself (this is called recursion).
The following recursive function calculates a factorial:
function y=f(n)
if n<=1 then
y = 1
else
y = n * f(n1)
end
endfunction
The parameters of a function can be assigned default values:
function y=f(a, b)
[lhs,rhs] = argn(0);
disp('Number of inputs: '+string(rhs));
disp('Number of outputs: '+string(lhs));
if rhs <= 1 then
b = 10;
end
if rhs == 0 then
a = 0;
b = 10;
end
y = a+b;
endfunction
This is what happens if we call the function f
with different number of parameters:
f()
Number of inputs: 0
Number of outputs: 1
ans =
10.
f(1)
Number of inputs: 1
Number of outputs: 1
ans =
11.
f(1,2)
Number of inputs: 2
Number of outputs: 1
ans =
3.
Functions can also be used as parameters in other functions. For example,
function y=f(x,fun)
y=fun(x)
endfunction
function y=g(x)
y = exp(x)
endfunction
f(0,g)
ans =
1.
f(1,g)
ans =
2.7182818
A function can be applied to each element of a vector with feval
x = [1 2 3 4 5]
x =
1. 2. 3. 4. 5.
y=feval(x,f)
y =
1. 2. 6. 24. 120.
Some more Scilab tricks: Scilab Bag Of Tricks