Need help getting a function to function

Your code is based on jQuery and you are including it to a PHP file. So you need to call it between <script></script> tag and obviously either you must end and start PHP tags before <script> and after </script> or echo the full script.

Now come to how you are gonna execute the code. You can hook the adjustLogoHeight() function to any hook which fires on where you need to put the function-

add_action( 'wp_head', 'adjustLogoHeight' );

Or you can direct call the function where you want to put the function by calling the function like adjustLogoHeight().

Now a little update on your jQuery code-

function adjustLogoHeight() { ?>
    <script>
        (function( $ ) {
            'use strict';
            var divHeight = $('#et-top-navigation').height();
            $('.logo_container').css('height', divHeight+'px');
        })( jQuery );
    </script>
<?php };

Write your function like above. It’s more appropriate.

Must call the adjustLogoHeight function after jQuery is loaded to the DOM. Otherwise you’ll get error whether you’re calling it directly or hooking it to any hook.