summaryrefslogtreecommitdiffstats
path: root/fiz
diff options
context:
space:
mode:
authorAnton Luka Šijanec <anton@sijanec.eu>2023-04-06 22:22:40 +0200
committerAnton Luka Šijanec <anton@sijanec.eu>2023-04-06 22:22:40 +0200
commitc5fd0c67e79d56c5f09ff8587101917a0c45120c (patch)
tree438484adefdebb158baf3bb8756a27dffedc7d4a /fiz
parentmat zadnji test, upam (diff)
parentz: zotksd, fizvaje10, infsemin (diff)
downloadsola-gimb-4-c5fd0c67e79d56c5f09ff8587101917a0c45120c.tar
sola-gimb-4-c5fd0c67e79d56c5f09ff8587101917a0c45120c.tar.gz
sola-gimb-4-c5fd0c67e79d56c5f09ff8587101917a0c45120c.tar.bz2
sola-gimb-4-c5fd0c67e79d56c5f09ff8587101917a0c45120c.tar.lz
sola-gimb-4-c5fd0c67e79d56c5f09ff8587101917a0c45120c.tar.xz
sola-gimb-4-c5fd0c67e79d56c5f09ff8587101917a0c45120c.tar.zst
sola-gimb-4-c5fd0c67e79d56c5f09ff8587101917a0c45120c.zip
Diffstat (limited to 'fiz')
-rw-r--r--fiz/vaje/10/.gitignore1
-rw-r--r--fiz/vaje/10/dokument.lyx1251
-rwxr-xr-xfiz/vaje/10/tab.py22
3 files changed, 1271 insertions, 3 deletions
diff --git a/fiz/vaje/10/.gitignore b/fiz/vaje/10/.gitignore
index 8c9c1c2..da2a8f9 100644
--- a/fiz/vaje/10/.gitignore
+++ b/fiz/vaje/10/.gitignore
@@ -1,3 +1,4 @@
*.csv
p.tsv
podatki.lyx
+graf.tex
diff --git a/fiz/vaje/10/dokument.lyx b/fiz/vaje/10/dokument.lyx
new file mode 100644
index 0000000..bf0df5c
--- /dev/null
+++ b/fiz/vaje/10/dokument.lyx
@@ -0,0 +1,1251 @@
+#LyX 2.3 created this file. For more info see http://www.lyx.org/
+\lyxformat 544
+\begin_document
+\begin_header
+\save_transient_properties true
+\origin unavailable
+\textclass article
+\begin_preamble
+\usepackage{siunitx}
+\usepackage{pgfplots}
+\usepackage{listings}
+\usepackage{multicol}
+\sisetup{output-decimal-marker = {,}, quotient-mode=fraction, output-exponent-marker=\ensuremath{\mathrm{3}}}
+\end_preamble
+\use_default_options true
+\maintain_unincluded_children false
+\language slovene
+\language_package default
+\inputencoding auto
+\fontencoding global
+\font_roman "default" "default"
+\font_sans "default" "default"
+\font_typewriter "default" "default"
+\font_math "auto" "auto"
+\font_default_family default
+\use_non_tex_fonts false
+\font_sc false
+\font_osf false
+\font_sf_scale 100 100
+\font_tt_scale 100 100
+\use_microtype false
+\use_dash_ligatures true
+\graphics default
+\default_output_format default
+\output_sync 0
+\bibtex_command default
+\index_command default
+\paperfontsize default
+\spacing single
+\use_hyperref false
+\papersize default
+\use_geometry true
+\use_package amsmath 1
+\use_package amssymb 1
+\use_package cancel 1
+\use_package esint 1
+\use_package mathdots 1
+\use_package mathtools 1
+\use_package mhchem 1
+\use_package stackrel 1
+\use_package stmaryrd 1
+\use_package undertilde 1
+\cite_engine basic
+\cite_engine_type default
+\biblio_style plain
+\use_bibtopic false
+\use_indices false
+\paperorientation portrait
+\suppress_date false
+\justification false
+\use_refstyle 1
+\use_minted 0
+\index Index
+\shortcut idx
+\color #008000
+\end_index
+\leftmargin 1cm
+\topmargin 2cm
+\rightmargin 1cm
+\bottommargin 2cm
+\headheight 1cm
+\headsep 1cm
+\footskip 1cm
+\secnumdepth 3
+\tocdepth 3
+\paragraph_separation indent
+\paragraph_indentation default
+\is_math_indent 0
+\math_numbering_side default
+\quotes_style german
+\dynamic_quotes 0
+\papercolumns 1
+\papersides 1
+\paperpagestyle default
+\tracking_changes false
+\output_changes false
+\html_math_output 0
+\html_css_as_file 0
+\html_be_strict false
+\end_header
+
+\begin_body
+
+\begin_layout Title
+Vsiljeno nihanje in resonanca
+\end_layout
+
+\begin_layout Author
+
+\noun on
+Anton Luka Šijanec
+\end_layout
+
+\begin_layout Date
+29.
+ marec 2023
+\end_layout
+
+\begin_layout Abstract
+Grafi in rezultati desete in zadnje vaje pri predmetu
+\noun on
+F41
+\noun default
+ na Gimnaziji Bežigrad v 4.
+ letniku.
+\end_layout
+
+\begin_layout Section*
+Podatki in grafi
+\end_layout
+
+\begin_layout Standard
+Teoretični model
+\begin_inset Formula $s_{0}\left(\nu\right)$
+\end_inset
+
+ harmoničnega nihala s tremi parametri je
+\begin_inset Formula
+\[
+s_{0}=\frac{A}{\sqrt{\left(B^{2}-\omega^{2}\right)^{2}+C^{2}\omega^{2}}}\text{{,}}
+\]
+
+\end_inset
+
+
+\end_layout
+
+\begin_layout Standard
+kjer je
+\begin_inset Formula $\omega=2\pi v$
+\end_inset
+
+ oziroma, če jo izračunamo iz podatkov matematičnega nihala,
+\begin_inset Formula $\omega=\sqrt{\frac{g}{l}}$
+\end_inset
+
+.
+\end_layout
+
+\begin_layout Standard
+\begin_inset Float table
+placement H
+wide false
+sideways false
+status open
+
+\begin_layout Plain Layout
+
+\lang english
+\begin_inset Tabular
+<lyxtabular version="3" rows="17" columns="4">
+<features tabularvalignment="middle">
+<column alignment="left" valignment="top" width="0pt">
+<column alignment="left" valignment="top" width="0pt">
+<column alignment="left" valignment="top" width="0pt">
+<column alignment="left" valignment="top" width="0pt">
+<row>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+\begin_inset Formula $l\left[\si{\meter}\right]$
+\end_inset
+
+
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+\begin_inset Formula $x_{0}\left[\si{\meter}\right]$
+\end_inset
+
+
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+\begin_inset Formula $\omega$
+\end_inset
+
+
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+\begin_inset Formula $\nu$
+\end_inset
+
+
+\end_layout
+
+\end_inset
+</cell>
+</row>
+<row>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,4
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,012654
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+4,952272
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,788179
+\end_layout
+
+\end_inset
+</cell>
+</row>
+<row>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,5
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,009038
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+4,429447
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,704968
+\end_layout
+
+\end_inset
+</cell>
+</row>
+<row>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,45
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,009038
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+4,669047
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,743102
+\end_layout
+
+\end_inset
+</cell>
+</row>
+<row>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,3
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,025308
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+5,718391
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,91011
+\end_layout
+
+\end_inset
+</cell>
+</row>
+<row>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,35
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,019885
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+5,294202
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,842598
+\end_layout
+
+\end_inset
+</cell>
+</row>
+<row>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,25
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,047
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+6,264184
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,996976
+\end_layout
+
+\end_inset
+</cell>
+</row>
+<row>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,24
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,054231
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+6,393356
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+1,017534
+\end_layout
+
+\end_inset
+</cell>
+</row>
+<row>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,23
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,054231
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+6,530863
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+1,039419
+\end_layout
+
+\end_inset
+</cell>
+</row>
+<row>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,22
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,054231
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+6,677642
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+1,06278
+\end_layout
+
+\end_inset
+</cell>
+</row>
+<row>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,21
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,056038
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+6,834785
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+1,08779
+\end_layout
+
+\end_inset
+</cell>
+</row>
+<row>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,2
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,047
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+7,003571
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+1,114653
+\end_layout
+
+\end_inset
+</cell>
+</row>
+<row>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,19
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,043385
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+7,185512
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+1,14361
+\end_layout
+
+\end_inset
+</cell>
+</row>
+<row>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,18
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,043385
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+7,382412
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+1,174947
+\end_layout
+
+\end_inset
+</cell>
+</row>
+<row>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,17
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,036154
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+7,596439
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+1,209011
+\end_layout
+
+\end_inset
+</cell>
+</row>
+<row>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,16
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,032538
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+7,83023
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+1,24622
+\end_layout
+
+\end_inset
+</cell>
+</row>
+<row>
+<cell alignment="left" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,15
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+0,036154
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+8,087027
+\end_layout
+
+\end_inset
+</cell>
+<cell alignment="left" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
+\begin_inset Text
+
+\begin_layout Plain Layout
+
+\lang english
+1,28709
+\end_layout
+
+\end_inset
+</cell>
+</row>
+</lyxtabular>
+
+\end_inset
+
+
+\end_layout
+
+\begin_layout Plain Layout
+\align center
+\begin_inset Caption Standard
+
+\begin_layout Plain Layout
+Izmerjeni in izračunani podatki.
+ Podatek o amplitudi je natančen na milimeter.
+\end_layout
+
+\end_inset
+
+
+\end_layout
+
+\end_inset
+
+
+\begin_inset Note Note
+status open
+
+\begin_layout Plain Layout
+\begin_inset Float figure
+placement H
+wide false
+sideways false
+status open
+
+\begin_layout Plain Layout
+\align center
+\begin_inset ERT
+status open
+
+\begin_layout Plain Layout
+
+
+\backslash
+begin{tikzpicture}
+\end_layout
+
+\begin_layout Plain Layout
+
+
+\backslash
+begin{axis}[width=0.75
+\backslash
+textwidth, scale only axis, ylabel=$s_0$, domain=0:12, ytick pos=left, samples=2
+56, xlabel=$
+\backslash
+omega$, xtick pos=bottom, xmin=0, xmax=12, ymin=0, ymax=.06,
+\end_layout
+
+\begin_layout Plain Layout
+
+%grid=both
+\end_layout
+
+\begin_layout Plain Layout
+
+, major grid style={dashed,blue}]
+\end_layout
+
+\begin_layout Plain Layout
+
+
+\backslash
+addplot[only marks] table [x=omega, y=x, col sep=comma] {podatki.csv};
+\end_layout
+
+\begin_layout Plain Layout
+
+
+\backslash
+addlegendentry{meritve}
+\end_layout
+
+\begin_layout Plain Layout
+
+
+\backslash
+addplot[blue] (x, {0.47583543/sqrt(-6.87050654^2-x^2)^2+1.2365817^2*x^2});
+\end_layout
+
+\begin_layout Plain Layout
+
+
+\backslash
+addlegendentry{$A=0.47583543$, $B=-6.87050654$, $C=1.2365817$}
+\end_layout
+
+\begin_layout Plain Layout
+
+\end_layout
+
+\begin_layout Plain Layout
+
+%
+\backslash
+addplot[mark=square*, blue, only marks] table [x=u, y=i, col sep=comma]
+ {2.csv};
+\end_layout
+
+\begin_layout Plain Layout
+
+%
+\backslash
+addlegendentry{zaporedno}
+\end_layout
+
+\begin_layout Plain Layout
+
+%
+\backslash
+addplot[blue] (x, {x*1.1889});
+\end_layout
+
+\begin_layout Plain Layout
+
+%
+\backslash
+addlegendentry{}
+\end_layout
+
+\begin_layout Plain Layout
+
+%
+\backslash
+addplot[mark=diamond*, green, only marks] table [x=u, y=i, col sep=comma]
+ {3.csv};
+\end_layout
+
+\begin_layout Plain Layout
+
+%
+\backslash
+addlegendentry{vzporedno}
+\end_layout
+
+\begin_layout Plain Layout
+
+%
+\backslash
+addplot[blue] (x, {x*5.38536});
+\end_layout
+
+\begin_layout Plain Layout
+
+%
+\backslash
+addlegendentry{}
+\end_layout
+
+\begin_layout Plain Layout
+
+
+\backslash
+end{axis}
+\end_layout
+
+\begin_layout Plain Layout
+
+%
+\backslash
+begin{axis}[width=0.75
+\backslash
+textwidth, scale only axis, ylabel=$b^{-1}$, ytick pos=right, samples=256,
+ xlabel=$a^{-1}$, xtick pos=top, %grid=both
+\end_layout
+
+\begin_layout Plain Layout
+
+%, xlabel near ticks, ylabel near ticks, major grid style={dashed,red},
+\end_layout
+
+\begin_layout Plain Layout
+
+%legend style={at={(0.975,0.325)}, anchor=south east}, domain=4:7, xmin=4,
+ xmax=6.6, ymin=13, ymax=15.6
+\end_layout
+
+\begin_layout Plain Layout
+
+%]
+\end_layout
+
+\begin_layout Plain Layout
+
+%
+\backslash
+addplot[mark=triangle*, red, only marks] table [x=1/a, y=1/b, col sep=comma]
+ {podatki.csv};
+\end_layout
+
+\begin_layout Plain Layout
+
+%
+\backslash
+addlegendentry{meritve}
+\end_layout
+
+\begin_layout Plain Layout
+
+%
+\backslash
+addplot[red] (x, {1/0.0511438-x});
+\end_layout
+
+\begin_layout Plain Layout
+
+%
+\backslash
+addlegendentry{$b^{-1}=f^{-1}-a^{-1}$}
+\end_layout
+
+\begin_layout Plain Layout
+
+%
+\backslash
+end{axis}
+\end_layout
+
+\begin_layout Plain Layout
+
+
+\backslash
+end{tikzpicture}
+\end_layout
+
+\end_inset
+
+
+\end_layout
+
+\begin_layout Plain Layout
+\begin_inset Caption Standard
+
+\begin_layout Plain Layout
+\begin_inset CommandInset label
+LatexCommand label
+name "fig:graf-1"
+
+\end_inset
+
+
+\begin_inset Formula $s_{0}\left(\omega\right)$
+\end_inset
+
+
+\end_layout
+
+\end_inset
+
+
+\end_layout
+
+\end_inset
+
+
+\end_layout
+
+\end_inset
+
+
+\end_layout
+
+\begin_layout Standard
+\begin_inset CommandInset include
+LatexCommand input
+filename "graf.tex"
+
+\end_inset
+
+
+\end_layout
+
+\begin_layout Standard
+Iz grafa za harmonično nihanje razberemo 6,819 kot
+\begin_inset Formula $\omega_{0}$
+\end_inset
+
+, kar pomeni, da je resonančna frekvenca matematičnega nihala
+\begin_inset Formula $\SI{1,085}{\per\second}$
+\end_inset
+
+.
+\end_layout
+
+\end_body
+\end_document
diff --git a/fiz/vaje/10/tab.py b/fiz/vaje/10/tab.py
index c5c24db..2b0bbae 100755
--- a/fiz/vaje/10/tab.py
+++ b/fiz/vaje/10/tab.py
@@ -1,7 +1,11 @@
#!/usr/bin/python3
import pandas
-import sys
+from sys import argv, stderr
from math import pi
+from numpy import sqrt, arange, argmax
+from scipy.optimize import curve_fit
+from matplotlib import pyplot
+from tikzplotlib import get_tikz_code
l = 23.5
df = pandas.read_csv("podatki.tsv", sep="\t")
df.index.name = "idx"
@@ -9,6 +13,18 @@ df["x"] = (df["y"]/13*l)
df["omega"] = ((9.81/df["l"])**(1/2))
df["f"] = (df["omega"]*0.5/pi)
df = df.astype(float).round(6);
-data = df.values
+def objective(x, A, B, C):
+ return A/sqrt((B**2-x**2)**2+C**2*x**2)
+popt, _ = curve_fit(objective, df.values[:, 3], df.values[:, 2])
+print(popt, file=stderr)
+pyplot.scatter(df.values[:, 3], df.values[:, 2])
+iksi = arange(min(df.values[:, 3]), max(df.values[:, 3]), 0.01)
+ipsiloni = objective(iksi, popt[0], popt[1], popt[2])
+print(f"omega nič je {iksi[argmax(ipsiloni)]}, kar je {iksi[argmax(ipsiloni)]/2/pi} Hz", file=stderr)
+pyplot.plot(iksi, ipsiloni, "--", color="red")
+pyplot.xlabel('$s_0 \\left[\\si{\\meter}\\right]$')
+pyplot.ylabel('$\\omega=2\\pi\\nu$')
+pyplot.title("$s_0\\left(\\omega\\right)$")
if __name__ == "__main__":
- df.to_csv("/dev/stdout", sep=",");
+ # df.to_csv("/dev/stdout", sep=argv[1][0]);
+ print(get_tikz_code(axis_width="0.75\\textwidth"))