#executiontime
Explore tagged Tumblr posts
homotexas · 1 year ago
Text
like this
drop : ∀ {ℓ} ⁺→ {A : Type ℓ} ⁼→ A ⁼→ ⊤ drop _ = tt -- ∑ with implicit first projection record Total {ℓ₁}⁻ {ℓ₂}⁺ {A : Type ℓ₁}⁻ (B : A ⁺→ Type ℓ₂)⁺ : Type (ℓ₁ ⊔ ℓ₂) where field {bundle} : A sub : B bundle -- propositional truncation (a.k.a. Squash) data ∥_∥ {ℓ} (A : Type ℓ) : Type ℓ where inc : A ⁺→ ∥ A ∥ squash : (x y : A) ⁼→ x ≡ y postulate path : ∀ {ℓ} ⁺→ {A : Type ℓ}⁺ → {x : A} ⁻→ {y : A} ⁺→ (x ↝ y) → 𝕀 → A record ExecutionTime : Type where field iexe : 𝕀 open ExecutionTime ⦃ … ⦄ public -- value erased at runtime Comptime : ∀ {ℓ} ⁺→ Type ℓ ⁺→ ⦃ ExecutionTime ⦄ ⁺→ Type ℓ Comptime A = path (drop {A=A}) iexe -- value irrelevant at runtime Irrelevant : ∀ {ℓ} ⁺→ Type ℓ ⁺→ ⦃ ExecutionTime ⦄ ⁺→ Type ℓ Irrelevant A = path (inc {A=A}) iexe -- A at comptime and B at runtime transported by some (unspecified) path Exec : ∀ {ℓ₁ ℓ₂} ⁺→ Type ℓ₁ ⁻→ Type ℓ₂ ⁺→ ⦃ ExecutionTime ⦄ ⁺→ Type (ℓ₁ ⊔ ℓ₂) Exec A B = Total λ (p : Type [ _ ↦ AtoB ]) → outS p where AtoB : Partial ((∼ iexe) ∧ iexe) (Type (ℓ₁ ⊔ ℓ₂)) AtoB = λ { (iexe = i0) → A ; (iexe = i1) → B } main : ⦃ ExecutionTime ⦄ ⁺→ Exec ⊤ (IO ⊤)
directed cubical language where main takes an interval parameter representing execution at compile time vs runtime. main i0 is precomputed and then the runtime behavior of the program arises from transporting to i1
2 notes · View notes
mrhackerco · 5 years ago
Photo
Tumblr media
Python’s Execution Time Is Close To C++ And Go Language: Study | MrHacker.Co #c #executiontime #go #n-queen #programming #hacker #hacking #cybersecurity #hackers #linux #ethicalhacking #programming #security #mrhacker
0 notes
jstnlowe · 6 years ago
Text
Verifying Exported SSRS Report Contents
When it comes to the generation, export, and/or printing of reports, there are times when it is useful to be able to quickly determine the contemporaneity and integrity of a report. This is useful in situations where you need to determine at a glance if the contents of the report are recent and or if any changes have been made to them.
There are much more powerful and comprehensive ways of ensuring report/data integrity, however the following applies to situations where "casual" inspection of a report is sufficient. What I’ll cover here is the use of a timestamp and the generation and use of a hash value.
Time Generated
Including a timestamp of report generation is a very common approach and, depending on how often that report is generated or the content is updated, displaying just the date may be sufficient. This can be accomplished through the use of SSRS global parameter ExecutionTime. I almost always include this in the footer of the reports I design, typically in a smaller font so that it does not distract the user from the contents of the report.
Content Hash
When it comes to validating the contents of the report, the approach that I tend to use is to call SQL's HASHBYTES() function, passing it values from the report. While in many cases you may be able to pass the full contents of the report into the function, the input is limited to 8000 bytes so you may end up having to choose a subset of values. An added bonus of using a subset is that, as long as you do not indicate which values were used, it makes attempts to falsify a hash all that more difficult (not that this is a practical concern for most applications).
The output of the function is a value that is (in practice) unique to the input which allows for the verification of the contents of the report: the hash on a previously-generated copy could be used to very quickly determine if the contents of the copy had been modified externally after generation or if the values in the database had been changed since its generation.
As of SQL 2016, the weaker hash algorithms have been deprecated, leaving us with SHA2_256 and SHA2_512 both of which have output that is not human-readable and not suitable for displaying on a report. To address this, it's perfectly acceptable to truncate the hash to a more reasonable length for our purposes.
Implementation
Let’s say that we have a report that displays the contents of a single personnel record. The dataset query looks like this:
SELECT [Id],[FirstName],[LastName],[Username],[HireDate],[AccessLevel],[Notes]` FROM [Employees] WHERE [Id] = @userid
Now, let's say that our primary concern is the integrity of the [AccessLevel] and [Notes]. We'll include the following line in the SELECT statement to generate the hash using SHA256, convert it to varchar, and truncate it to the first sixteen characters:
LEFT(CONVERT(VARCHAR(64),HASHBYTES('SHA2_256',[AccessLevel]+[Notes]),2),16) AS [ReportHash]
The output could then be displayed in the footer of the report alongside the generation timestamp and would look something like this:
3A250D547F4A209A 06/03/2019 19:01:35
0 notes
mathematicianadda · 4 years ago
Text
Why do engineers use derivatives in discontinuous functions? Is it correct? https://ift.tt/eA8V8J
I am a Software Engineering student and this year I learned about how CPUs work, it turns out that electronic engineers and I also see it a lot in my field, we do use derivatives with discontinuous functions. For instance in order to calculate the optimal amount of ripple adders so as to minimise the execution time of the addition process:
$$\text{ExecutionTime}(n, k) = \Delta(4k+\frac{2n}{k}-4)$$ $$\frac{d\,\text{ExecutionTime}(n, k)}{dk}=4\Delta-\frac{2n\Delta}{k^2}=0$$ $$k= \sqrt{\frac{n}{2}}$$
where $n$ is the number of bits in the numbers to add, $k$ is the amount of adders in ripple and $\Delta$ is the "delta gate" (the time that takes to a gate to operate).
Clearly you can see that the execution time function is not continuous at all because $k$ is a natural number and so is $n$. This is driving me crazy because on the one hand I understand that I can analyse the function as a continuous one and get results in that way, and indeed I think that's what we do ("I think", that's why I am asking), but my intuition and knowledge about mathematical analysis tells me that this is completely wrong, because the truth is that the function is not continuous and will never be and because of that, the derivative with respect to $k$ or $n$ does not exist because there is no rate of change.
If someone could explain me if my first guess is correct or not and why, I'd appreciate it a lot, thanks for reading and helping!
from Hot Weekly Questions - Mathematics Stack Exchange Santiago Pardal from Blogger https://ift.tt/2QS7gix
0 notes
lth604 · 10 years ago
Photo
Tumblr media
#Repost @bmikerob ・・・ @bmikerob will be giving knowledge out tonight tune in. by @laronpierce "Tonight... We Have @stayreadyradio's own @bmikerob and @misshelendesiree as special guests of The Hip-Hop Show -Episode 6: The Invasion Part 1. So guys please tune in on every Tuesdays at 9:30pm-11pm on rmconair.com and please call in 323-965-1600 so show support or talk to The Hip-Hop Squad (@laronpierce, @dhanediesil @seanauguste and @rachar_90302), or @stayreadyradio). Make sure you check out the Hip-Hop Show's Episode 5: Paying & Praying is up on youtube and its in the link description. I GOT THE HEART OF A EXECUTIONER!!!!! #JudgeJuryExecutioner #theprinceofla #roscoesmediacenter #generationuradio #generationu #heartofawarrior #heartofaexecutioner #idontgetcold #working #rapping #engineering #execute #ExecutionTime #laron #pierce #laronpierce #happynewyear #2015 #laronsprogression #theonlyhiphopshow #hiphop #thehiphopshow #planesandpalmtrees #payingandpraying #90302photos #stayreadyradio #yougottostayreadywhenyoudonthavetogetready #thehiphopshow
0 notes
planesandpalmtrees · 10 years ago
Photo
Tumblr media
Tonight... We Have @stayreadyradio's own @bmikerob and @misshelendesiree as special guest of The Hip-Hop Show. Stay tune for the 3rd and final guest of the Episode 6: The Invasion Part 1. So guys please tune in on every Tuesdays at 9:30pm-11:30pm on rmconair.com and please call in 323-965-1600 so show support or talk to Laron, The Hip-Hop Squad, @stayreadyradio or The 3rd and final guest will announce this Saturday. Make sure you check out the Hip-Hop Show's Episode 5: Paying & Praying is up on youtube and its in the link description. I GOT THE HEART OF A EXECUTIONER!!!!! #JudgeJuryExecutioner #theprinceofla #roscoesmediacenter #generationuradio #generationu #heartofawarrior #heartofaexecutioner #idontgetcold #working #rapping #engineering #execute #ExecutionTime #laron #pierce #laronpierce #happynewyear #2015 #laronsprogression #theonlyhiphopshow #hiphop #thehiphopshow #planesandpalmtrees #payingandpraying #90302photos #stayreadyradio #yougottostayreadywhenyoudonthavetogetready #thehiphopshow
0 notes
lth604 · 10 years ago
Photo
Tumblr media
#Repost @bmikerob ・・・ @bmikerob will be giving knowledge out tonight tune in. by @laronpierce "Tonight... We Have @stayreadyradio's own @bmikerob and @misshelendesiree as special guests of The Hip-Hop Show -Episode 6: The Invasion Part 1. So guys please tune in on every Tuesdays at 9:30pm-11pm on rmconair.com and please call in 323-965-1600 so show support or talk to The Hip-Hop Squad (@laronpierce, @dhanediesil @seanauguste and @rachar_90302), or @stayreadyradio). Make sure you check out the Hip-Hop Show's Episode 5: Paying & Praying is up on youtube and its in the link description. I GOT THE HEART OF A EXECUTIONER!!!!! #JudgeJuryExecutioner #theprinceofla #roscoesmediacenter #generationuradio #generationu #heartofawarrior #heartofaexecutioner #idontgetcold #working #rapping #engineering #execute #ExecutionTime #laron #pierce #laronpierce #happynewyear #2015 #laronsprogression #theonlyhiphopshow #hiphop #thehiphopshow #planesandpalmtrees #payingandpraying #90302photos #stayreadyradio #yougottostayreadywhenyoudonthavetogetready #thehiphopshow
0 notes
planesandpalmtrees · 10 years ago
Photo
Tumblr media
Starting Next Tuesday... We Have @stayreadyradio's own @bmikerob and @misshelendesiree as special guest of The Hip-Hop Show. Stay tune for the 3rd and final guest of the Episode 6: The Invasion Part 1. So guys please tune in on every Tuesdays at 9:30pm-11:30pm on rmconair.com and please call in 323-965-1600 so show support or talk to Laron, The Hip-Hop Squad, @stayreadyradio or The 3rd and final guest will announce this Saturday. Make sure you check out the Hip-Hop Show's Episode 5: Paying & Praying is up on youtube and its in the link description. I GOT THE HEART OF A EXECUTIONER!!!!! #JudgeJuryExecutioner #theprinceofla #roscoesmediacenter #generationuradio #generationu #heartofawarrior #heartofaexecutioner #idontgetcold #working #rapping #engineering #execute #ExecutionTime #laron #pierce #laronpierce #happynewyear #2015 #laronsprogression #theonlyhiphopshow #hiphop #thehiphopshow #planesandpalmtrees #payingandpraying #90302photos #stayreadyradio #yougottostayreadywhenyoudonthavetogetready #thehiphopshow
0 notes